Code

Opened 9 months ago

Closed 9 months ago

Last modified 9 months ago

#21207 closed Bug (fixed)

Test failure on Oracle: test_cursor_contextmanager

Reported by: shai Owned by: nobody
Component: Database layer (models, ORM) Version: master
Severity: Release blocker Keywords: oracle
Cc: Triage Stage: Accepted
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

On Oracle, we get:

======================================================================
ERROR: test_cursor_contextmanager (backends.tests.BackendTestCase)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/django/django/tests/backends/tests.py", line 627, in test_cursor_contextmanager
    cursor.execute("select 1")
  File "/home/django/django/django/db/backends/utils.py", line 61, in execute
    return self.cursor.execute(sql, params)
  File "/home/django/django/django/db/utils.py", line 94, in __exit__
    six.reraise(dj_exc_type, dj_exc_value, traceback)
  File "/home/django/django/django/db/backends/utils.py", line 59, in execute
    return self.cursor.execute(sql)
  File "/home/django/django/django/db/backends/oracle/base.py", line 841, in execute
    self._guess_input_sizes([params])
  File "/home/django/django/django/db/backends/oracle/base.py", line 810, in _guess_input_sizes
    self.setinputsizes(*sizes)
InterfaceError: not open

Attachments (0)

Change History (3)

comment:1 Changed 9 months ago by akaariai

This should be easy to fix - just set Oracle's features.closed_cursor_error_class to InterfaceError and things should work. Could you test that this fixes the issue on Oracle?

comment:2 Changed 9 months ago by Tim Graham <timograham@…>

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

In 0d02c5429970804068520f0dc6f0ae9fb3e08b9c:

Fixed #21207 -- Fixed test failure on Oracle: test_cursor_contextmanager

refs #17671

comment:3 Changed 9 months ago by shai

Thanks, guys.

Add Comment

Modify Ticket

Change Properties
<Author field>
Action
as closed
as The resolution will be set. Next status will be 'closed'
The resolution will be deleted. Next status will be 'new'
Author


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

 
Note: See TracTickets for help on using tickets.