Skip to content

pytest-django builds incorrect database names with pytest 5.3.3 and pytest-xdist #801

Closed
@rixx

Description

@rixx

pytet 5.3.3 was just released today, and pytest-django performs very slowly and incorrectly when run with pytest-xdist. There is a tracking issue up at pytest-dev/pytest#6492, which includes a git-bisect run and a more detailed description.

The tl;dr is that due to a change in fixture handling, pytest-django plus pytest-xdist build increasingly long database names until you reach errors such as django.core.exceptions.ImproperlyConfigured: The database name 'test_travis_ci_test_gw0_gw0_gw0_gw0_gw0_gw0_gw0_gw0_gw0_gw0_gw0_gw0_gw0' (71 characters) is longer than PostgreSQL's limit of 63 characters. Supply a shorter NAME in settings.DATABASES., while performing very slowly.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions