Opened 18 years ago
Closed 18 years ago
#674 closed defect (worksforme)
"Oops" when I try attach a screenshot
Reported by: | clive | Owned by: | Radek Bartoň |
---|---|---|---|
Priority: | normal | Component: | ScreenshotsPlugin |
Severity: | critical | Keywords: | |
Cc: | Trac Release: | 0.9 |
Description
I am running TracTags-0.4 and ScreenShots plugin as from the repository (latest source).
My trac instance is 0.9.6 running on sqlite3.
When I try attach a screenshot, I get the following error:
Trac detected an internal error: SQL logic error or missing database
The python traceback is as follows:
Python traceback Traceback (most recent call last): File "/usr/local/lib/python2.4/site-packages/trac/web/modpython_frontend.py", line 206, in handler dispatch_request(mpr.path_info, mpr, env) File "/usr/local/lib/python2.4/site-packages/trac/web/main.py", line 139, in dispatch_request dispatcher.dispatch(req) File "/usr/local/lib/python2.4/site-packages/trac/web/main.py", line 107, in dispatch resp = chosen_handler.process_request(req) File "build/bdist.freebsd-5.3-RELEASE-i386/egg/tracscreenshots/core.py", line 116, in process_request File "build/bdist.freebsd-5.3-RELEASE-i386/egg/tracscreenshots/core.py", line 222, in _do_actions File "/usr/local/lib/python2.4/site-packages/TracTags-0.4-py2.4.egg/tractags/api.py", line 160, in add_tags File "/usr/local/lib/python2.4/site-packages/trac/db.py", line 219, in execute args or []) File "/usr/local/lib/python2.4/site-packages/trac/db.py", line 211, in _rollback_on_error return function(self, *args, **kwargs) OperationalError: SQL logic error or missing database
The database dump of the list tables in my database is as follows:
attachment report tags auth_cookie revision ticket component screenshot ticket_change enum screenshot_component ticket_custom milestone screenshot_version version node_change session wiki permission system
Attachments (0)
Change History (11)
comment:1 Changed 18 years ago by
Status: | new → assigned |
---|
comment:2 Changed 18 years ago by
I'm sorry. I thought I had the latest source, but I did not. After an svn up a traceback with real line-numbers looks like this:
Python traceback Traceback (most recent call last): File "/usr/local/lib/python2.4/site-packages/trac/web/modpython_frontend.py", line 206, in handler dispatch_request(mpr.path_info, mpr, env) File "/usr/local/lib/python2.4/site-packages/trac/web/main.py", line 139, in dispatch_request dispatcher.dispatch(req) File "/usr/local/lib/python2.4/site-packages/trac/web/main.py", line 107, in dispatch resp = chosen_handler.process_request(req) File "build/bdist.freebsd-5.3-RELEASE-i386/egg/tracscreenshots/core.py", line 124, in process_request File "build/bdist.freebsd-5.3-RELEASE-i386/egg/tracscreenshots/core.py", line 231, in _do_actions File "/usr/local/lib/python2.4/site-packages/TracTags-0.4-py2.4.egg/tractags/api.py", line 160, in add_tags File "/usr/local/lib/python2.4/site-packages/trac/db.py", line 219, in execute args or []) File "/usr/local/lib/python2.4/site-packages/trac/db.py", line 211, in _rollback_on_error return function(self, *args, **kwargs) OperationalError: SQL logic error or missing database
comment:3 Changed 18 years ago by
I think that problem is with database inconsistency caused by previous bugs. I've changed code in chageset 1220 that this inconsistency shoudn't care next time. Please test it if you can.
comment:4 Changed 18 years ago by
I still get the error. New traceback follows.
Python traceback Traceback (most recent call last): File "/usr/local/lib/python2.4/site-packages/trac/web/modpython_frontend.py", line 206, in handler dispatch_request(mpr.path_info, mpr, env) File "/usr/local/lib/python2.4/site-packages/trac/web/main.py", line 139, in dispatch_request dispatcher.dispatch(req) File "/usr/local/lib/python2.4/site-packages/trac/web/main.py", line 107, in dispatch resp = chosen_handler.process_request(req) File "build/bdist.freebsd-5.3-RELEASE-i386/egg/tracscreenshots/core.py", line 126, in process_request File "build/bdist.freebsd-5.3-RELEASE-i386/egg/tracscreenshots/core.py", line 233, in _do_actions File "/usr/local/lib/python2.4/site-packages/TracTags-0.4-py2.4.egg/tractags/api.py", line 101, in replace_tags File "/usr/local/lib/python2.4/site-packages/TracTags-0.4-py2.4.egg/tractags/api.py", line 160, in add_tags File "/usr/local/lib/python2.4/site-packages/trac/db.py", line 219, in execute args or []) File "/usr/local/lib/python2.4/site-packages/trac/db.py", line 211, in _rollback_on_error return function(self, *args, **kwargs) OperationalError: SQL logic error or missing database
comment:5 Changed 18 years ago by
Look at your database file in your trac environment. If there is trac.db-journal file DB operation was broken inside atom. To unlock your DB open sqlite console and perform some SQL statement i. e. SELECT * FROM tags;. If this helps great, if not I'll be continuing to remember what I done when I was that error too :-).
comment:6 Changed 18 years ago by
I do not have any journal files.
Entry as per your request (schema dump included as well):
sqlite> select * from tags; sqlite> .schema tags CREATE TABLE tags ( tagspace text, name text, tag text, UNIQUE (tagspace,name,tag) ); CREATE INDEX tags_tagspace_name_idx ON tags (tagspace,name); CREATE INDEX tags_tagspace_tag_idx ON tags (tagspace,tag); sqlite>
I still get the same error.
comment:7 Changed 18 years ago by
I asked about this problem and it was told me that this error is caused by locked database or two commits as I thought. I can't help you how to unlock database unless you try some SQL statement which changes database i. e. CREATE TABLE tmp; DROP TABLE tmp; in sqlite console. I think that no change in ScreenshotsPlugin could help because it should be inside TracTagsPlugin.
comment:8 Changed 18 years ago by
I understand what you are saying, however, everything else works fine. I am able to use tags outside of the screenshot page. I am able to add pages and do any other work so the database surely cannot be locked.
comment:9 Changed 18 years ago by
I have got this to work (managed to get no error) sometimes if I use very small screenshot upload files. It seems the larger the file, the more chance there is of failure in this manner.
comment:10 Changed 18 years ago by
Interesting... I'll make some tests in this way and I'll see what I can do.
comment:11 Changed 18 years ago by
Resolution: | → worksforme |
---|---|
Status: | assigned → closed |
I tried to upload 75 MB BMPs and nothing happend on 0.10. If this is problem of 0.9 branch only, consider it as unsupported because I don't have working 0.9 installation.
I saw that error before, but I don't remeber what was the cause. I'll take a look at that tomorrow.