Project

General

Profile

Développement #67950

Publik - Gestion de projet #64274: montée de version django (→ 3.2 LTS)

fonctionner avec django 3.2

Added by A. B. over 2 years ago. Updated almost 2 years ago.

Status:
Fermé
Priority:
Normal
Target version:
-
Start date:
04 August 2022
Due date:
% Done:

0%

Estimated time:
Patch proposed:
Yes
Planning:
No
Tags:


Files


Related issues

Blocked by Hobo - Développement #67760: fonctionner avec django 3.2Fermé28 July 2022

Actions
Blocked by BiJoe - Développement #68312: Tests qui crashent en local en cherchant une base au nom de l'utilisateur linuxFermé22 August 2022

Actions

Associated revisions

Revision e3847091 (diff)
Added by A. B. almost 2 years ago

dj32: enable django 3.2 testing in tox file (#67950)

Revision a4277409 (diff)
Added by Benjamin Dauvergne almost 2 years ago

dj32: adapt dependencies on Django-Select2 (#67950)

Revision 17c566ed (diff)
Added by Benjamin Dauvergne almost 2 years ago

dj32: rename staticfiles templatetags lib to static (#67950)

History

#1

Updated by A. B. over 2 years ago

  • Tags set to django32
  • Assignee deleted (A. B.)

Impossible de lancer les tests en local (ni sur django 2, ni sur django 3):

    @pytest.fixture(scope='module')
    def schema1_db():
>       with load_schema_db('schema1') as d:

tests/conftest.py:126: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
/usr/lib/python3.10/contextlib.py:135: in __enter__
    return next(self.gen)
tests/conftest.py:117: in load_schema_db
    with closing(psycopg2.connect('')) as conn:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

dsn = '', connection_factory = None, cursor_factory = None, kwargs = {}, kwasync = {}

    def connect(dsn=None, connection_factory=None, cursor_factory=None, **kwargs):
        """ 
        Create a new database connection.

        The connection parameters can be specified as a string:

            conn = psycopg2.connect("dbname=test user=postgres password=secret")

        or using a set of keyword arguments:

            conn = psycopg2.connect(database="test", user="postgres", password="secret")

        Or as a mix of both. The basic connection parameters are:

        - *dbname*: the database name
        - *database*: the database name (only as keyword argument)
        - *user*: user name used to authenticate
        - *password*: password used to authenticate
        - *host*: database host address (defaults to UNIX socket if not provided)
        - *port*: connection port number (defaults to 5432 if not provided)

        Using the *connection_factory* parameter a different class or connections
        factory can be specified. It should be a callable object taking a dsn
        argument.

        Using the *cursor_factory* parameter, a new default cursor factory will be
        used by cursor().

        Using *async*=True an asynchronous connection will be created. *async_* is
        a valid alias (for Python versions where ``async`` is a keyword).

        Any other keyword parameter will be passed to the underlying client
        library: the list of supported parameters depends on the library version.

        """ 
        kwasync = {}
        if 'async' in kwargs:
            kwasync['async'] = kwargs.pop('async')
        if 'async_' in kwargs:
            kwasync['async_'] = kwargs.pop('async_')

        if dsn is None and not kwargs:
            raise TypeError('missing dsn and no parameters')

        dsn = _ext.make_dsn(dsn, **kwargs)
>       conn = _connect(dsn, connection_factory=connection_factory, **kwasync)
E       psycopg2.OperationalError: connection to server on socket "/var/run/postgresql/.s.PGSQL.5432" failed: FATAL:  database "agate" does not exist

Visiblement il cherche une base à mon username linux (agate).

#2

Updated by A. B. over 2 years ago

#3

Updated by A. B. over 2 years ago

J'ai quand même poussée ma branche avec le strict minimum pour lancer les tests sous django 3, si quelqu'un veut tester: wip/67950-fonctionner-avec-django-

#4

Updated by A. B. over 2 years ago

#5

Updated by A. B. about 2 years ago

  • Blocked by Développement #68312: Tests qui crashent en local en cherchant une base au nom de l'utilisateur linux added
#6

Updated by Benjamin Dauvergne almost 2 years ago

  • Assignee set to Benjamin Dauvergne
#8

Updated by Thomas Noël (congés → 5 décembre) almost 2 years ago

Peut-être utiliser https://git.entrouvert.org/hobo.git/snapshot/hobo-wip/67760-fonctionner-avec-django-.tar.gz au lieu de hobo-6d4a2108ab5201e5b712f54fd04966b7dcc9fabc.tar.gz ?

#9

Updated by Benjamin Dauvergne almost 2 years ago

J'espère surtout virer cette partie des patchs avant de pousser.

#10

Updated by Emmanuel Cazenave almost 2 years ago

  • Status changed from Solution proposée to Solution validée
#11

Updated by Benjamin Dauvergne almost 2 years ago

  • Status changed from Solution validée to Résolu (à déployer)
commit 17c566ede0c432f38a32dc9028a33ad6945b32cc
Author: Benjamin Dauvergne <bdauvergne@entrouvert.com>
Date:   Tue Jan 10 11:29:27 2023 +0100

    dj32: rename staticfiles templatetags lib to static (#67950)

commit a427740907aae0ef8d355105c11e18f51541f2de
Author: Benjamin Dauvergne <bdauvergne@entrouvert.com>
Date:   Tue Jan 10 11:33:48 2023 +0100

    dj32: adapt dependencies on Django-Select2 (#67950)

commit e384709134eeeabdabc80e9070b8045d831249b3
Author: Agate Berriot <aberriot@entrouvert.com>
Date:   Thu Aug 4 15:24:26 2022 +0200

    dj32: enable django 3.2 testing in tox file (#67950)
#12

Updated by Transition automatique almost 2 years ago

  • Status changed from Résolu (à déployer) to Solution déployée
#13

Updated by Transition automatique over 1 year ago

Automatic expiration

Also available in: Atom PDF