Ticket #2469 (closed defect: fixed)
Python2.4 issue when the uuid package is not installed
| Reported by: | lmacken | Owned by: | |
|---|---|---|---|
| Priority: | normal | Milestone: | 2.1b2 |
| Component: | TurboGears | Version: | trunk |
| Severity: | normal | Keywords: | |
| Cc: |
Description
On python2.4 setups, without the uuid module, we resort to trying to base64 encode the secret cookie, which fails:
Traceback (most recent call last):
File "/home/lmacken/geo/tg2env/bin/paster", line 7, in ?
sys.exit(
File "/home/lmacken/geo/tg2env/lib/python2.4/site-packages/PasteScript-1.7.3-py2.4.egg/paste/script/command.py", line 84, in run
invoke(command, command_name, options, args[1:])
File "/home/lmacken/geo/tg2env/lib/python2.4/site-packages/PasteScript-1.7.3-py2.4.egg/paste/script/command.py", line 123, in invoke
exit_code = runner.run(args)
File "/home/lmacken/geo/tg2env/lib/python2.4/site-packages/PasteScript-1.7.3-py2.4.egg/paste/script/command.py", line 218, in run
result = self.command()
File "/home/lmacken/geo/tgdevtools-dev/devtools/commands/quickstart.py", line 212, in command
self.cookiesecret = base64.b64encode(base64(random.randrange(2**32))).strip()
TypeError: 'module' object is not callable
Change History
Note: See
TracTickets for help on using
tickets.
Since I broke it, it's only fair that I fix it. I've attached that fix to my bitbucket fork at http://bitbucket.org/pedersen/tgdevtools-dev/changeset/0114eaf651b4/
You can simply do a pull request to get this in.