Opened 7 years ago
Last modified 7 years ago
#29938 closed Bug
"int() argument must be a string or a number, not 'list'" error oracle 12.1 python — at Version 2
| Reported by: | kono10 | Owned by: | nobody |
|---|---|---|---|
| Component: | Database layer (models, ORM) | Version: | 1.11 |
| Severity: | Normal | Keywords: | oracle, oracle 12.1, python 2.7 |
| Cc: | Triage Stage: | Unreviewed | |
| Has patch: | no | Needs documentation: | no |
| Needs tests: | no | Patch needs improvement: | no |
| Easy pickings: | no | UI/UX: | no |
Description (last modified by )
When creating an initial migration in a new python project "python manage.py migrate" I get the following error int() argument must be a string or a number, not 'list'. I am using an oracle db version 12.1. I was able to fix the error by chancing line 245 in lib/python2.7/site-packages/django/db/backends/oracle/operations.py
from
def fetch_returned_insert_id(self, cursor):
return int(cursor._insert_id_var.getvalue())
to
def fetch_returned_insert_id(self, cursor):
return int(cursor._insert_id_var.getvalue()[0])
Change History (2)
comment:1 by , 7 years ago
| Description: | modified (diff) |
|---|
comment:2 by , 7 years ago
| Description: | modified (diff) |
|---|
Note:
See TracTickets
for help on using tickets.