#5597 closed defect (wontfix)
can't view tickets
Reported by: | Owned by: | Christian Boos | |
---|---|---|---|
Priority: | normal | Milestone: | |
Component: | ticket system | Version: | 0.10.4 |
Severity: | major | Keywords: | |
Cc: | Eli Carter | Branch: | |
Release Notes: | |||
API Changes: | |||
Internal Changes: |
Description (last modified by )
After a downgrade from 0.11.dev to trac 10.4 I can't view tickets. The result is the error message
Python Traceback
Traceback (most recent call last): File "D:\Programme\Python24\Lib\site-packages\trac\web\main.py", line 406, in dispatch_request dispatcher.dispatch(req) File "D:\Programme\Python24\Lib\site-packages\trac\web\main.py", line 237, in dispatch resp = chosen_handler.process_request(req) File "D:\Programme\Python24\Lib\site-packages\trac\ticket\web_ui.py", line 313, in process_request get_reporter_id(req, 'author')) File "D:\Programme\Python24\Lib\site-packages\trac\ticket\web_ui.py", line 669, in _insert_ticket_data actions = TicketSystem(self.env).get_available_actions(ticket, req.perm) File "D:\Programme\Python24\Lib\site-packages\trac\ticket\api.py", line 83, in get_available_actions return [action for action in actions.get(ticket['status'], ['leave']) File "D:\Programme\Python24\Lib\site-packages\trac\ticket\model.py", line 104, in __getitem__ return self.values[name] KeyError: 'status'
Need urgent help
regards
Attachments (0)
Change History (15)
comment:1 by , 17 years ago
Description: | modified (diff) |
---|---|
Severity: | blocker → major |
comment:2 by , 17 years ago
For some reason, you now have tickets with no status. Try the following using the sqlite3 command line tool (assuming you're using PySqlite):
update ticket set status='new' where status='' or status is null;
(untested, so backup your db first!)
comment:4 by , 17 years ago
Yes I use PySqlite.
I did try your recommendation. But there is no effect. It's the same error message.
comment:5 by , 17 years ago
further more:
I asked the database for "
select status, id from ticket;
" There is no field of column status which is empty.
comment:6 by , 17 years ago
Owner: | changed from | to
---|
comment:7 by , 17 years ago
For your information:
In the version 10.4 I changed in file …\ticket\model.py the line 104 from
return self.values[name] in return self.values.get(name)
Now it works.
follow-ups: 10 11 comment:8 by , 17 years ago
Clarification please:
Was this environment created with 0.11dev and then downgraded to 0.10.4
or
Was this environment created with 0.10.*, upgraded to 0.11dev, and then downgraded to 0.10.4
(Just FYI: In 0.11dev, the status implementation changed dramatically, and it no longer uses the entries in the enum table.)
comment:9 by , 17 years ago
Cc: | added |
---|
comment:10 by , 17 years ago
Replying to ecarter:
Clarification please:
Was this environment created with 0.11dev and then downgraded to 0.10.4
or
Was this environment created with 0.10.*, upgraded to 0.11dev, and then downgraded to 0.10.4
(Just FYI: In 0.11dev, the status implementation changed dramatically, and it no longer uses the entries in the enum table.)
I created with 0.11dev and then downgraded to 0.10.4 .
The only reason to downgrade from 0.11dev to 0.10.4 was to use more plugins. Now I give up because there another small things they will not work. Im using 0.11dev again and I'm looking forward for the first 0.11 release.
All in all you all do a great job.
comment:11 by , 17 years ago
Replying to ecarter:
(Just FYI: In 0.11dev, the status implementation changed dramatically, and it no longer uses the entries in the enum table.)
Furthermore, 0.11dev does not populate the status values in the enum table, so downgrading from something created by 0.11dev to 0.10.4 will require creating those entries.
comment:12 by , 17 years ago
Resolution: | → wontfix |
---|---|
Status: | new → closed |
Downgrading an environment has not been supported in the past, and so I don't think this is something care enough about to implement.
follow-up: 14 comment:13 by , 17 years ago
I can understand not wanting to support downgrading but the 0.11 install documentation needs to be updated to reflect that.
No database change is required (for now), so it's currently safe to switch an existing 0.10 environment to 0.11 and back.
comment:14 by , 17 years ago
Replying to anonymous:
I can understand not wanting to support downgrading but the 0.11 install documentation needs to be updated to reflect that.
Ah, good point. Fixed.
Thanks!
comment:15 by , 16 years ago
I had this exact issue and was able to fix it with the following steps:
- enter sqlite3 shell from a terminal
$ sqlite3
- check if the enum table exists (mine did, just no 'status' entries).
sqlite> SELECT * FROM enum;
- if the table does exist, insert the status entries.
sqlite> INSERT INTO "enum" VALUES('status','new','1'); sqlite> INSERT INTO "enum" VALUES('status','assigned','2'); sqlite> INSERT INTO "enum" VALUES('status','reopened','3'); sqlite> INSERT INTO "enum" VALUES('status','closed','4');
- if the table does not exist, dump it from a host that has a good enum table (old install, etc), then copy the dump text and paste into the sqlite3 shell.
- if the table does exist, insert the status entries.
- Ctrl-d to exit the sqlite3 shell
- Test
Although I can understand the frustration, you cannot install the development release of a software and consider having difficulties to revert back to the official release is a blocker issue.