-
-
Notifications
You must be signed in to change notification settings - Fork 1.5k
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
Fix TypeError when use Blueprint.group() to group blueprint with defa… #1334
Conversation
…ult url_prefix, Use os.path.normpath to avoid invalid url_prefix like api//v1
sanic/blueprints.py
Outdated
bp.url_prefix = url_prefix + bp.url_prefix | ||
bp.url_prefix = os.path.normpath(bp.url_prefix) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think it should call normpath here.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@yunstanford there's a discussion regarding this on #1325, @chenjr0719 just needs to update the PR afaik.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@vltr @yunstanford I just remove normpath
to make this PR simple and focus on the original issue about default value of url_prefix
.
Codecov Report
@@ Coverage Diff @@
## master #1334 +/- ##
=========================================
Coverage ? 81.43%
=========================================
Files ? 17
Lines ? 1675
Branches ? 319
=========================================
Hits ? 1364
Misses ? 244
Partials ? 67 Continue to review full report at Codecov.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
what is the css file for?
@ahopkins Oops, my bad. The css file is created by |
…ult url_prefix, Use os.path.normpath to avoid invalid url_prefix like api//v1