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

Revert "Register Django urls (#8778)" #9254

Merged
merged 1 commit into from
Mar 10, 2024

Conversation

shuuji3
Copy link
Contributor

@shuuji3 shuuji3 commented Feb 12, 2024

Description

Hello, this PR reverts the PR #8778.

When I was doing the Quickstart tutorial, I was a bit confused with the urlpatterns configurations in the URLs section (https://www.django-rest-framework.org/tutorial/quickstart/#urls) because it includes URL routes for REST framework twice.

I think we don't have to append the same routes to make the REST framework routes working properly.

Here are the routes before and after this PR's change:

Before

Screenshot 2024-02-12 at 20 49 33

After
Screenshot 2024-02-12 at 20 49 46

As you can see, urlpatterns += router.urls makes the extra duplicated routes unnecessarily.

@auvipy
Copy link
Member

auvipy commented Feb 19, 2024

thanks for reporting this! /a was intentionally done to show the exceptions right?

@auvipy
Copy link
Member

auvipy commented Feb 19, 2024

I have to manually check this myself

@auvipy auvipy merged commit 09a0c55 into encode:master Mar 10, 2024
@auvipy auvipy added this to the 3.15 milestone Mar 10, 2024
@shuuji3 shuuji3 deleted the fix/remove-redundant-urlpatterns branch March 10, 2024 12:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants