Opened 6 years ago

Closed 6 years ago

Last modified 3 years ago

#11298 closed (invalid)

adding user in contrib.admin while TEMPLATE_STRING_IF_INVALID set corrupts form url

Reported by: falken@… Owned by: nobody
Component: contrib.admin Version: master
Severity: Keywords:
Cc: Triage Stage: Unreviewed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: UI/UX:

Description

When I have TEMPLATE_STRING_IF_INVALID = '¤' in settings.py, trying to add new auth.User using default form throws exception:

ValueError at /admin/auth/user/add/¤
invalid literal for int() with base 10: 'add/\xa4'
Request Method:	POST
Request URL:	http://localhost:8000/admin/auth/user/add/%C2%A4
Exception Type:	ValueError
Exception Value:	
invalid literal for int() with base 10: 'add/\xa4'
Exception Location:	c:\@django\Django-trunk\django\db\models\sql\query.py in add_filter, line 1614

something is rendered at end of url even if it not exists:
ValueError at /admin/auth/user/add/¤

This happens after "Save" button even if I do not enter any username nor passwords in form, simply to issue validation.

Change History (2)

comment:1 Changed 6 years ago by Alex

  • Needs documentation unset
  • Needs tests unset
  • Patch needs improvement unset
  • Resolution set to invalid
  • Status changed from new to closed

The admin relies on having TEMPLATE_STRING_IF_INVALID set to , this is not a bug.

comment:2 Changed 3 years ago by jacob

  • milestone 1.1 deleted

Milestone 1.1 deleted

Note: See TracTickets for help on using tickets.
Back to Top