Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug] 导入FastAPI失败,是否应该使用redirect? #7

Open
lanbinshijie opened this issue Feb 17, 2024 · 4 comments
Open

[Bug] 导入FastAPI失败,是否应该使用redirect? #7

lanbinshijie opened this issue Feb 17, 2024 · 4 comments
Assignees
Labels
🐛bug Something isn't working

Comments

@lanbinshijie
Copy link
Contributor

在这行代码中,程序从fastapi导入了名为redirect的模块,但是在我的FastAPI版本中,这个导入是失败的,是否是版本冲突问题?

from fastapi import Request, Response, redirect

另外我们必须使用redirect在这里么?@BernieHuang2008 #4

image
@lanbinshijie lanbinshijie added the 🐛bug Something isn't working label Feb 17, 2024
@lanbinshijie
Copy link
Contributor Author

报错具体如下:

image

@BernieHuang2008
Copy link
Contributor

az,copilot给我建议的

@BernieHuang2008
Copy link
Contributor

但是确实啊,用户访问的链接就直接由这个函数处理,当然要在返回的时候redirect到指定页面啦

@AUXStar
Copy link

AUXStar commented Feb 18, 2024

看看starlette的重定向

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🐛bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants