[Django] #27282: port cant be integer with oracle backend

4 views
Skip to first unread message

Django

unread,
Sep 27, 2016, 12:31:56 PM9/27/16
to django-...@googlegroups.com
#27282: port cant be integer with oracle backend
----------------------------------------------+--------------------
Reporter: Zapelini | Owner: nobody
Type: Bug | Status: new
Component: Database layer (models, ORM) | Version: 1.10
Severity: Normal | Keywords: port
Triage Stage: Unreviewed | Has patch: 0
Easy pickings: 0 | UI/UX: 0
----------------------------------------------+--------------------
if you set the PORT to be an integer with the oracle backend you will get
an exception because it calls strip on the value:

https://github.com/django/django/blob/master/django/db/backends/oracle/base.py#L194

note that the other backends do not do this, so either an integer or
string value will do just fine.

https://github.com/django/django/blob/master/django/db/backends/postgresql/base.py#L165

The fix ix simple: just remove the .strip() call from line 194

--
Ticket URL: <https://code.djangoproject.com/ticket/27282>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.

Django

unread,
Sep 27, 2016, 12:36:01 PM9/27/16
to django-...@googlegroups.com
#27282: port cant be integer with oracle backend
-------------------------------------+-------------------------------------

Reporter: Zapelini | Owner: nobody
Type: Bug | Status: new
Component: Database layer | Version: 1.10
(models, ORM) |
Severity: Normal | Resolution:

Keywords: port | Triage Stage:
| Unreviewed
Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0

Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
Changes (by Zapelini):

* needs_better_patch: => 0
* needs_tests: => 0
* needs_docs: => 0


Comment:

There is a pull request at: https://github.com/django/django/pull/7302

--
Ticket URL: <https://code.djangoproject.com/ticket/27282#comment:1>

Django

unread,
Sep 27, 2016, 1:53:31 PM9/27/16
to django-...@googlegroups.com
#27282: port cant be integer with oracle backend
-------------------------------------+-------------------------------------

Reporter: Zapelini | Owner: nobody
Type: Bug | Status: new
Component: Database layer | Version: 1.10
(models, ORM) |
Severity: Normal | Resolution:
Keywords: port | Triage Stage: Ready for
| checkin
Has patch: 1 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0

Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
Changes (by Tim Graham):

* has_patch: 0 => 1
* stage: Unreviewed => Ready for checkin


Comment:

The `strip()` is from the
[https://github.com/django/django/commit/cac7675f247da325cb862a312804fe64845d1155
#diff-54b46d05e1da568b3cc987c423e00c50R33 original backend] but I don't
see much need for it either.

--
Ticket URL: <https://code.djangoproject.com/ticket/27282#comment:2>

Django

unread,
Sep 27, 2016, 3:01:39 PM9/27/16
to django-...@googlegroups.com
#27282: port cant be integer with oracle backend
-------------------------------------+-------------------------------------
Reporter: Zapelini | Owner: nobody
Type: Bug | Status: closed

Component: Database layer | Version: 1.10
(models, ORM) |
Severity: Normal | Resolution: fixed

Keywords: port | Triage Stage: Ready for
| checkin
Has patch: 1 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0

Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
Changes (by Tim Graham <timograham@…>):

* status: new => closed
* resolution: => fixed


Comment:

In [changeset:"62543260dd58309902fa73f0984e245fd6c6da2a" 62543260]:
{{{
#!CommitTicketReference repository=""
revision="62543260dd58309902fa73f0984e245fd6c6da2a"
Fixed #27282 -- Allowed using an integer DATABASES['PORT'] for Oracle.
}}}

--
Ticket URL: <https://code.djangoproject.com/ticket/27282#comment:3>

Reply all
Reply to author
Forward
0 new messages