This site is an archive; learn more about 8 years of OpenHatch.

[Devel] [issue385] Change tracker_name regex in urls.py for the /customs/ URLs to allow anything except /

Jack Grigg bugs at openhatch.org
Fri Apr 15 16:37:56 UTC 2011


New submission from Jack Grigg <me at jackgrigg.com>:

During the migrations from the asynchronous importer code, for some reason South
complained about duplicates. So paulproteus got past it by appending ' (dup)' to
the tracker_name field (which needed to be unique). That was fine, but the
tracker_name regex in urls.py only allowed wordss separated by a space or
hyphen, so /customs/ is now broken. This patch opens up the tracker_url regex to
allow anything except a / (so the regex is '[^/]+'):
http://git.jackgrigg.com/openhatch/patch/?id=95a58427897a045fbc2a78af4b02007480dbfe97

This is not particularly nice. What I would really like to do is limit what
users can enter into this field. Or maybe use an auto-generated slug instead,
and then error back to the user when they try to enter a tracker_name that will
generate a slug that already exists. Actually, we should do both; the slug makes
the URLs nice for copy and paste (no spaces), and the limit on characters makes
auto-generated project names simpler.

----------
assignedto: pythonian4000
messages: 1531
milestone: 0.11.04
nosy: paulproteus, pythonian4000
priority: urgent
status: need-review
title: Change tracker_name regex in urls.py for the /customs/ URLs to allow anything except /

__________________________________________
Roundup issue tracker <bugs at openhatch.org>
<https://openhatch.org/bugs/issue385>
__________________________________________


More information about the Devel mailing list