Opened 13 months ago

Closed 13 months ago

Last modified 13 months ago

#22744 closed Bug (fixed)

inspectdb test failure on spatialite

Reported by: timo Owned by: claudep
Component: GIS Version: 1.7-beta-2
Severity: Release blocker Keywords:
Cc: claudep Triage Stage: Ready for checkin
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

New in 1.7:

======================================================================
ERROR [0.001s]: test_special_column_name_introspection (inspectdb.tests.InspectDBTestCase)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/var/lib/jenkins/workspace/django-spatialite/database/spatialite/python/python2.7/tests/inspectdb/tests.py", line 177, in test_special_column_name_introspection
    call_command('inspectdb', stdout=out)
  File "/var/lib/jenkins/workspace/django-spatialite/database/spatialite/python/python2.7/django/core/management/__init__.py", line 112, in call_command
    return klass.execute(*args, **defaults)
  File "/var/lib/jenkins/workspace/django-spatialite/database/spatialite/python/python2.7/django/core/management/base.py", line 337, in execute
    output = self.handle(*args, **options)
  File "/var/lib/jenkins/workspace/django-spatialite/database/spatialite/python/python2.7/django/core/management/base.py", line 532, in handle
    return self.handle_noargs(**options)
  File "/var/lib/jenkins/workspace/django-spatialite/database/spatialite/python/python2.7/django/core/management/commands/inspectdb.py", line 27, in handle_noargs
    for line in self.handle_inspection(options):
  File "/var/lib/jenkins/workspace/django-spatialite/database/spatialite/python/python2.7/django/core/management/commands/inspectdb.py", line 63, in handle_inspection
    relations = connection.introspection.get_relations(cursor, table_name)
  File "/var/lib/jenkins/workspace/django-spatialite/database/spatialite/python/python2.7/django/db/backends/sqlite3/introspection.py", line 82, in get_relations
    results = cursor.fetchone()[0].strip()
TypeError: 'NoneType' object has no attribute '__getitem__'

Attachments (1)

22744-1.diff (849 bytes) - added by claudep 13 months ago.

Download all attachments as: .zip

Change History (7)

comment:1 Changed 13 months ago by aaugustin

I never managed to compile spatialite and I assume I'm not the only one :-/

If you had the time to bisect the failure, someone would then feel responsible for fixing it ;-)

comment:2 Changed 13 months ago by timo

  • Cc claudep added

comment:3 Changed 13 months ago by claudep

  • Owner changed from nobody to claudep
  • Status changed from new to assigned

Changed 13 months ago by claudep

comment:4 Changed 13 months ago by charettes

  • Triage Stage changed from Accepted to Ready for checkin

Patch looks good to me, test pass with and without pysqlite on Py27.

comment:5 Changed 13 months ago by Claude Paroz <claude@…>

  • Resolution set to fixed
  • Status changed from assigned to closed

In 5a504a5311b0108586e633128f6ef8be6e05249a:

Fixed #22744 -- Fixed sqlite3 get_relations introspection with views

Thanks Tim Graham for the report and Simon Charette for the review.

comment:6 Changed 13 months ago by Claude Paroz <claude@…>

In a2fb5c9d69b0a7bfbb7f5576eb9e801c159a1f0b:

[1.7.x] Fixed #22744 -- Fixed sqlite3 get_relations introspection with views

Thanks Tim Graham for the report and Simon Charette for the review.
Backport of 5a504a5311 from master.

Note: See TracTickets for help on using tickets.
Back to Top