Opened 6 months ago
Closed 6 months ago
#35474 closed Bug (invalid)
django use oracledb and enable thick mode,but sometimes Aborted
Reported by: | HeroZ09 | Owned by: | nobody |
---|---|---|---|
Component: | Database layer (models, ORM) | Version: | 5.0 |
Severity: | Normal | Keywords: | django ,oracledb ,thick mode |
Cc: | Triage Stage: | Unreviewed | |
Has patch: | no | Needs documentation: | no |
Needs tests: | no | Patch needs improvement: | no |
Easy pickings: | no | UI/UX: | no |
Description
for more detail:https://github.com/oracle/python-oracledb/discussions/337
1、django 5.0.X, python 3.11.X ,daphne asgi run service
DATABASES in setting.py:
DATABASES = {
"default": {
"ENGINE": "django.db.backends.oracle",
"NAME": XX,
"USER": XX,
"PASSWORD": XX,
"HOST": XX,
"PORT": XX,
}
}
oracledb.init_oracle_client()
2、OS : debian linux
3、oracle: instantclient_21_13
4、python-oracledb : 2.1.1
5、log:
double free or corruption (out)
Fatal Python error: Aborted
Current thread 0x00007f6470cfd6c0 (most recent call first):
File "/opt/conda/envs/cn_venv/lib/python3.11/site-packages/oracledb/connection.py", line 544 in init
File "/opt/conda/envs/cn_venv/lib/python3.11/site-packages/oracledb/connection.py", line 1158 in connect
File "/opt/conda/envs/cn_venv/lib/python3.11/site-packages/django/db/backends/oracle/base.py", line 252 in get_new_connection
File "/opt/conda/envs/cn_venv/lib/python3.11/site-packages/django/utils/asyncio.py", line 26 in inner
File "/opt/conda/envs/cn_venv/lib/python3.11/site-packages/django/db/backends/base/base.py", line 256 in connect
File "/opt/conda/envs/cn_venv/lib/python3.11/site-packages/django/utils/asyncio.py", line 26 in inner
File "/opt/conda/envs/cn_venv/lib/python3.11/site-packages/django/db/backends/base/base.py", line 275 in ensure_connection
File "/opt/conda/envs/cn_venv/lib/python3.11/site-packages/django/utils/asyncio.py", line 26 in inner
File "/opt/conda/envs/cn_venv/lib/python3.11/site-packages/django/db/backends/base/base.py", line 292 in _cursor
File "/opt/conda/envs/cn_venv/lib/python3.11/site-packages/django/db/backends/base/base.py", line 316 in cursor
File "/opt/conda/envs/cn_venv/lib/python3.11/site-packages/django/utils/asyncio.py", line 26 in inner
6、I check the django official with how to config oracle datadb(https://docs.djangoproject.com/zh-hans/5.0/ref/databases/#oracle-notes),and try to settins DATABASES with OPTIONS(threaded = true),but it looks not support ,logs below:
File "D:\SW\Anaconda\anaconda\envs\cn_env\Lib\site-packages\oracledb\connection.py", line 1150, in connect
f(dsn=dsn, pool=pool, conn_class=conn_class, params=params, kwargs)
TypeError: connect() got an unexpected keyword argument 'threaded'
Change History (2)
comment:1 by , 6 months ago
Component: | Uncategorized → Database layer (models, ORM) |
---|---|
Type: | Uncategorized → Bug |
comment:2 by , 6 months ago
Resolution: | → invalid |
---|---|
Status: | new → closed |
Hello,
This report seems better suited to be a support request. The best place to get answers to your issue is using any of the user support channels from this link.
Since the goal of this issue tracker is to track issues about Django itself, and your issue seems, at first, to be located in your custom code, I'll be closing this ticket as invalid following the ticket triaging process. If, after debugging, you find out that this is indeed a bug in Django, please re-open with the specific details and please be sure to include a small Django project to reproduce or a failing test case.
Thank you!