Re: git: 3232af189573 - main - www/py-flask: Update to 3.0.0

From: Jan Beich <jbeich_at_FreeBSD.org>
Date: Mon, 27 Nov 2023 16:01:15 UTC
Wen Heping <wen@FreeBSD.org> writes:

> -PORTNAME=	Flask
> +PORTNAME=	flask

pyproject.toml (USES=pep517) and consumers (see below) still use "Flask".

$ poudriere bulk -j 132amd64 www/flexget
[...]
[00:00:23] Warning: www/flexget dependency on www/py-flask@py39 has wrong PKGNAME of 'py39-Flask' but should be 'py39-flask'; Is the dependency missing a @FLAVOR?
[00:00:24] Warning: www/py-flask-compress dependency on www/py-flask@py39 has wrong PKGNAME of 'py39-Flask' but should be 'py39-flask'; Is the dependency missing a @FLAVOR?
[00:00:24] Warning: www/py-flask-login dependency on www/py-flask@py39 has wrong PKGNAME of 'py39-Flask' but should be 'py39-flask'; Is the dependency missing a @FLAVOR?
[00:00:24] Warning: www/py-flask-restx dependency on www/py-flask@py39 has wrong PKGNAME of 'py39-Flask' but should be 'py39-flask'; Is the dependency missing a @FLAVOR?
[00:00:24] Warning: www/py-flask-cors dependency on www/py-flask@py39 has wrong PKGNAME of 'py39-Flask' but should be 'py39-flask'; Is the dependency missing a @FLAVOR?
[...]
[00:01:15] Failed ports: www/py-flask-cors@py39:run-depends www/py-flask-compress@py39:run-depends www/py-flask-login@py39:run-depends www/py-flask-restx@py39:run-depends
[00:01:15] Skipped ports: www/flexget@py39

> -DISTVERSION=	2.3.2
> +DISTVERSION=	3.0.0

>>> import flask_restx
Traceback (most recent call last):
  File "/usr/local/lib/python3.9/site-packages/flask_restx/api.py", line 18, in <module>
    from flask.helpers import _endpoint_from_view_func
ImportError: cannot import name '_endpoint_from_view_func' from 'flask.helpers' (/usr/local/lib/python3.9/site-packages/flask/helpers.py)

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/usr/local/lib/python3.9/site-packages/flask_restx/__init__.py", line 2, in <module>
    from .api import Api  # noqa
  File "/usr/local/lib/python3.9/site-packages/flask_restx/api.py", line 20, in <module>
    from flask.scaffold import _endpoint_from_view_func
ModuleNotFoundError: No module named 'flask.scaffold'

> -RUN_DEPENDS=	${PYTHON_PKGNAMEPREFIX}werkzeug>=2.3.2:www/py-werkzeug@${PY_FLAVOR} \
> +RUN_DEPENDS=	${PYTHON_PKGNAMEPREFIX}werkzeug>=3.0.0:www/py-werkzeug@${PY_FLAVOR} \

>>> import flask_login
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/usr/local/lib/python3.9/site-packages/flask_login/__init__.py", line 12, in <module>
    from .login_manager import LoginManager
  File "/usr/local/lib/python3.9/site-packages/flask_login/login_manager.py", line 33, in <module>
    from .utils import _create_identifier
  File "/usr/local/lib/python3.9/site-packages/flask_login/utils.py", line 14, in <module>
    from werkzeug.urls import url_decode
ImportError: cannot import name 'url_decode' from 'werkzeug.urls' (/usr/local/lib/python3.9/site-packages/werkzeug/urls.py)