Opened 5 years ago

Closed 5 years ago

#5193 closed defect (wontfix)

OperationalError: database is locked

Reported by: skyper Owned by: Tom Hughes
Priority: minor Milestone:
Component: admin Version:
Keywords: Cc:

Description

How to Reproduce

While doing a POST operation on /newticket, Trac issued an internal error.

I simply tried to create the ticket.

Request parameters:

{'__FORM_TOKEN': u'09775270bb4fc86c7216a7f9',
 'field_cc': u'',
 'field_component': u'api',
 'field_description': u'Using JOSM with ssl and its notes plugin with plain http connections I got following warning when requesting notes.\r\n\r\nSee [https://josm.openstreetmap.de/ticket/10202 JOSM #10202]\r\n\r\n{{{\r\nWARNING: org.openstreetmap.josm.io.OsmApiException: ResponseCode=500, Error Body=<<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"\r\n   "http://www.w3.org/TR/html4/loose.dtd">\r\n<html>\r\n<body>\r\n  <img src="/assets/osm_logo.png" style="float:left; margin:10px">\r\n  <div style="float:left;">\r\n    <h1>Application error</h1>\r\n    <p>The OpenStreetMap server encountered an unexpected condition that prevented it from fulfilling the request (HTTP 500)</p>\r\n    <p>Feel free to <a href="http://wiki.openstreetmap.org/wiki/Contact" title="Various contact channels explained">contact</a> the OpenStreetMap community if your problem persists. Make a note of the exact URL / post data of your request.</p>\r\n    <p>This may be a problem in our Ruby On Rails code. 500 occurs with exceptions thrown outside of an action (like in Dispatcher setups or broken Ruby code)</p>\r\n  </div>\r\n</body>\r\n</html>>\r\norg.openstreetmap.josm.io.OsmApiException: ResponseCode=500, Error Body=<<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"\r\n   "http://www.w3.org/TR/html4/loose.dtd">\r\n<html>\r\n<body>\r\n  <img src="/assets/osm_logo.png" style="float:left; margin:10px">\r\n  <div style="float:left;">\r\n    <h1>Application error</h1>\r\n    <p>The OpenStreetMap server encountered an unexpected condition that prevented it from fulfilling the request (HTTP 500)</p>\r\n    <p>Feel free to <a href="http://wiki.openstreetmap.org/wiki/Contact" title="Various contact channels explained">contact</a> the OpenStreetMap community if your problem persists. Make a note of the exact URL / post data of your request.</p>\r\n    <p>This may be a problem in our Ruby On Rails code. 500 occurs with exceptions thrown outside of an action (like in Dispatcher setups or broken Ruby code)</p>\r\n  </div>\r\n</body>\r\n</html>>\r\n}}}',
 'field_keywords': u'error 500',
 'field_milestone': u'',
 'field_owner': u'',
 'field_priority': u'minor',
 'field_summary': u'HTTP Error 500',
 'field_type': u'defect',
 'field_version': u'',
 'submit': u'Create ticket'}

User agent: Mozilla/5.0 (X11; Linux x86_64; rv:30.0) Gecko/20100101 Firefox/30.0 Iceweasel/30.0

System Information

System information not available

Enabled Plugins

Plugin information not available

Python Traceback

Traceback (most recent call last):
  File "/usr/lib/python2.7/dist-packages/trac/web/main.py", line 511, in _dispatch_request
    dispatcher.dispatch(req)
  File "/usr/lib/python2.7/dist-packages/trac/web/main.py", line 237, in dispatch
    resp = chosen_handler.process_request(req)
  File "/usr/lib/python2.7/dist-packages/trac/ticket/web_ui.py", line 170, in process_request
    return self._process_newticket_request(req)
  File "/usr/lib/python2.7/dist-packages/trac/ticket/web_ui.py", line 398, in _process_newticket_request
    self._do_create(req, ticket) # (redirected if successful)
  File "/usr/lib/python2.7/dist-packages/trac/ticket/web_ui.py", line 1193, in _do_create
    ticket.insert()
  File "/usr/lib/python2.7/dist-packages/trac/ticket/model.py", line 226, in insert
    @self.env.with_transaction(db)
  File "/usr/lib/python2.7/dist-packages/trac/db/api.py", line 78, in transaction_wrapper
    ldb.commit()
OperationalError: database is locked

Change History (1)

comment:1 Changed 5 years ago by Tom Hughes

Resolution: wontfix
Status: newclosed

Happens sometimes when somebody runs a complicated report/query. It's an upstream trac issue and there's nothing we can do about it.

Note: See TracTickets for help on using tickets.