Projet

Général

Profil

0001-general-do-not-preload-package-versions-65722.patch

Frédéric Péters, 26 mai 2022 16:47

Télécharger (1,15 ko)

Voir les différences:

Subject: [PATCH 1/2] general: do not preload package versions (#65722)

 combo/wsgi.py | 8 --------
 1 file changed, 8 deletions(-)
combo/wsgi.py
9 9

  
10 10
import os
11 11

  
12
from django.conf import settings
13 12
from django.core.wsgi import get_wsgi_application
14 13

  
15 14
os.environ.setdefault("DJANGO_SETTINGS_MODULE", "combo.settings")
16 15

  
17 16
application = get_wsgi_application()
18
if 'hobo.context_processors.statics_hash' in settings.TEMPLATES[0]['OPTIONS']['context_processors']:
19
    # initialize versions as soon as possible as it may be used in most
20
    # requests via the statics_hash template var and we prefer not to
21
    # load the information during a user request.
22
    from hobo.scrutiny.wsgi.middleware import VersionMiddleware  # pylint: disable=import-error
23

  
24
    VersionMiddleware.get_packages_version()
25
-