Edgewall Software
Modify

Opened 13 years ago

Closed 13 years ago

Last modified 10 years ago

#10703 closed defect (cantfix)

ProgrammingError: operator does not exist: text = integerLINE 1: SELECT parent, child FROM subtickets WHERE parent=6 ^HINT: No operator matches the given name and argument type(s). You might need to add explicit type casts.

Reported by: webmaster@… Owned by:
Priority: normal Milestone:
Component: general Version: 0.12.3
Severity: normal Keywords: psycopg2, postgresql, programmingerror, cast
Cc: Branch:
Release Notes:
API Changes:
Internal Changes:

Description

How to Reproduce

While doing a GET operation on /ticket/6, Trac issued an internal error.

Just creating a ticket with the "Summary" only. Postgresql backend. I'm wondering why I could create 5 tickets 2 days ago without any problem…

Request parameters:

{'id': u'6'}

User agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/535.19 (KHTML, like Gecko) Ubuntu/12.04 Chromium/18.0.1025.151 Chrome/18.0.1025.151 Safari/535.19

System Information

Trac 0.12.3
Docutils 0.8.1
Genshi 0.6
GIT 1.7.9.5
mod_wsgi 3.3 (WSGIProcessGroup WSGIApplicationGroup %{GLOBAL})
psycopg2 2.4.5
Pygments 1.4
Python 2.7.3 (default, Apr 20 2012, 23:04:22)
[GCC 4.6.3]
setuptools 0.6
jQuery 1.4.4

Enabled Plugins

TracGit 0.12.0.5dev
TracSubTicketsPlugin 0.1.0

Python Traceback

Traceback (most recent call last):
  File "/usr/local/lib/python2.7/dist-packages/Trac-0.12.3-py2.7.egg/trac/web/main.py", line 522, in _dispatch_request
    dispatcher.dispatch(req)
  File "/usr/local/lib/python2.7/dist-packages/Trac-0.12.3-py2.7.egg/trac/web/main.py", line 254, in dispatch
    self._post_process_request(req, *resp)
  File "/usr/local/lib/python2.7/dist-packages/Trac-0.12.3-py2.7.egg/trac/web/main.py", line 363, in _post_process_request
    resp = f.post_process_request(req, *resp)
  File "/usr/local/lib/python2.7/dist-packages/TracSubTicketsPlugin-0.1.0-py2.7.egg/tracsubtickets/web_ui.py", line 71, in post_process_request
    children = self.get_children(ticket.id)
  File "/usr/local/lib/python2.7/dist-packages/TracSubTicketsPlugin-0.1.0-py2.7.egg/tracsubtickets/web_ui.py", line 102, in get_children
    (parent_id, ))
  File "/usr/local/lib/python2.7/dist-packages/Trac-0.12.3-py2.7.egg/trac/db/util.py", line 65, in execute
    return self.cursor.execute(sql_escape_percent(sql), args)
ProgrammingError: operator does not exist: text = integer
LINE 1: SELECT parent, child FROM subtickets WHERE parent=6
                                                         ^
HINT:  No operator matches the given name and argument type(s). You might need to add explicit type casts.

Attachments (0)

Change History (4)

comment:1 by anonymous, 13 years ago

Looks like a bug of "subtickets" addon.

comment:2 by anonymous, 13 years ago

Is solved by explicit casting:

str(parent)

and

str(parent.id)

in TracSubTicketsPlugin/web_ui.py

comment:3 by Remy Blank, 13 years ago

Resolution: cantfix
Status: newclosed

Yes, it's a PluginIssue (TracSubTicketsPlugin).

comment:4 by Ryan J Ollos, 10 years ago

Keywords: psycopg2 postgresql programmingerror cast → psycopg2, postgresql, programmingerror, cast

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The ticket will remain with no owner.
The resolution will be deleted. Next status will be 'reopened'.
to The owner will be changed from (none) to the specified user.

Add Comment


E-mail address and name can be saved in the Preferences .
 
Note: See TracTickets for help on using tickets.