Edgewall Software
Modify

Opened 12 years ago

Closed 10 years ago

Last modified 10 years ago

#198 closed defect (worksforme)

Viewing an empty list of builds fails

Reported by: David Abrahams <dave@…> Owned by: cmlenz
Priority: major Milestone:
Component: General Version: 0.5.3
Keywords: Cc:
Operating System: BSD

Description

Oops… Trac detected an internal error:

Error: fetchone() failed - cursor does not contain a result.

File "/usr/lib/python2.4/site-packages/Trac-0.11dev_r6060-py2.4.egg/trac/web/main.py", line 381, in dispatch_request
  dispatcher.dispatch(req)
File "/usr/lib/python2.4/site-packages/Trac-0.11dev_r6060-py2.4.egg/trac/web/main.py", line 191, in dispatch
  resp = chosen_handler.process_request(req)
File "/home/dave/trac-test/global/plugins/Bitten-0.6dev_r512-py2.4.egg/bitten/web_ui.py", line 128, in process_request
  self._render_overview(req)
File "/home/dave/trac-test/global/plugins/Bitten-0.6dev_r512-py2.4.egg/bitten/web_ui.py", line 143, in _render_overview
  for idx, config in enumerate(configs):
File "/home/dave/trac-test/global/plugins/Bitten-0.6dev_r512-py2.4.egg/bitten/model.py", line 167, in select
  for name, path, active, recipe, min_rev, max_rev, label, description \
File "/usr/lib/python2.4/site-packages/Trac-0.11dev_r6060-py2.4.egg/trac/db/util.py", line 40, in __iter__
  row = self.cursor.fetchone()
File "/usr/lib/python2.4/site-packages/pyPgSQL/PgSQL.py", line 3158, in fetchone
  raise Error, \

Attachments (0)

Change History (5)

comment:1 Changed 12 years ago by David Abrahams <dave@…>

This doesn't happen with psycopg2, FWIW.

comment:2 follow-up: Changed 12 years ago by mgood

IMO PgSQL is misinterpreting this section of the spec:

An Error (or subclass) exception is raised if the previous call to executeXXX() did not produce any result set or no call was issued yet.

They seem to be assuming that "did not produce any result set" is the same as a call that produced an empty result set. It seems that this statement is meant to cover INSERT/UPDATE/DELETE which don't produce results rather than this case with a SELECT that happens to return no rows.

What version of pyPgSQL are you seeing this on? This may need reported to them as a bug.

comment:3 in reply to: ↑ 2 Changed 12 years ago by David Abrahams <dave@…>

Replying to mgood:

What version of pyPgSQL are you seeing this on? This may need reported to them as a bug.

Package: python-pgsql
Priority: optional
Section: universe/python
Installed-Size: 584
Maintainer: Ubuntu Core Developers <ubuntu-devel@lists.ubuntu.com>
Architecture: i386
Version: 2.5.1-2build1
Replaces: python2.3-pgsql (<< 2.5.1), python2.4-pgsql (<< 2.5.1), python2-pgsql
Provides: python2.5-pgsql, python2.4-pgsql
Depends: libc6 (>= 2.4-1), libpq4 (>= 8.1.4), python-central (>= 0.5), python (<< 2.6), python (>= 2.4), python-egenix-mxdatetime (>= 1.3.0-5)
Conflicts: python2.3-pgsql (<< 2.5.1), python2.4-pgsql (<< 2.5.1), python2-pgsql
Filename: pool/universe/p/python-pgsql/python-pgsql_2.5.1-2build1_i386.deb
Size: 176790
MD5sum: d7b5cd6c1ec1d6c5fa23cae810f3eade
SHA1: 7416eb559b0c8605f2494c9f12d03c3c11510946
SHA256: 537c91767147f770e1137a76b1aa423cfae182b5d31d12b4208ef8ccb8e19d08
Description: A Python DB-API 2.0 interface to PostgreSQL v7.x
 PgSQL is a package of two (2) modules that provide a Python
 DB-API 2.0 compliant interface to PostgreSQL databases. The
 first module, libpq, exports the PostgreSQL C API to Python.
 The second module, PgSQL, provides the DB-API 2.0 compliant
 interface and support for various PostgreSQL data types, such
 as INT8, NUMERIC, MONEY, BOOL, ARRAYS, etc.
 .
 This package contains modules for all supported Python versions.
X-Original-Maintainer: Ben Burton <bab@debian.org>
Python-Version: 2.4, 2.5
Bugs: mailto:ubuntu-users@lists.ubuntu.com
Origin: Ubuntu

comment:4 Changed 12 years ago by David Abrahams <dave@…>

comment:5 Changed 10 years ago by osimons

  • Milestone 0.6 deleted
  • Resolution set to worksforme
  • Status changed from new to closed

See trac:ticket:5096. As the original reporter seems to have solved all issues by using the recommended Postgres driver (psycopg2), I'm closing this ticket - 'worksforme', or rather 'worksforyou' :-)

The underlying issue is a Trac issue anyway, so not much the Bitten project can do to resolve it in any other way.

Add Comment

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain cmlenz.
The resolution will be deleted. Next status will be 'reopened'.
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.