python-flask fails to build with Python 3.11.0a7. =================================== FAILURES =================================== _______________________________ test_flaskgroup ________________________________ runner = <click.testing.CliRunner object at 0x7fc24651f690> def test_flaskgroup(runner): def create_app(): return Flask("flaskgroup") @click.group(cls=FlaskGroup, create_app=create_app) def cli(**params): pass @cli.command() def test(): click.echo(current_app.name) result = runner.invoke(cli, ["test"]) > assert result.exit_code == 0 E assert 1 == 0 E + where 1 = <Result DeprecationWarning("module 'sre_constants' is deprecated")>.exit_code tests/test_cli.py:398: AssertionError _________________________ test_flaskgroup_debug[True] __________________________ runner = <click.testing.CliRunner object at 0x7fc246ce7dd0> set_debug_flag = True @pytest.mark.parametrize("set_debug_flag", (True, False)) def test_flaskgroup_debug(runner, set_debug_flag): def create_app(): app = Flask("flaskgroup") app.debug = True return app @click.group(cls=FlaskGroup, create_app=create_app, set_debug_flag=set_debug_flag) def cli(**params): pass @cli.command() def test(): click.echo(str(current_app.debug)) result = runner.invoke(cli, ["test"]) > assert result.exit_code == 0 E assert 1 == 0 E + where 1 = <Result DeprecationWarning("module 'sre_constants' is deprecated")>.exit_code tests/test_cli.py:418: AssertionError _________________________ test_flaskgroup_debug[False] _________________________ runner = <click.testing.CliRunner object at 0x7fc246cafe50> set_debug_flag = False @pytest.mark.parametrize("set_debug_flag", (True, False)) def test_flaskgroup_debug(runner, set_debug_flag): def create_app(): app = Flask("flaskgroup") app.debug = True return app @click.group(cls=FlaskGroup, create_app=create_app, set_debug_flag=set_debug_flag) def cli(**params): pass @cli.command() def test(): click.echo(str(current_app.debug)) result = runner.invoke(cli, ["test"]) > assert result.exit_code == 0 E assert 1 == 0 E + where 1 = <Result DeprecationWarning("module 'sre_constants' is deprecated")>.exit_code tests/test_cli.py:418: AssertionError ______________________ test_no_command_echo_loading_error ______________________ def test_no_command_echo_loading_error(): from flask.cli import cli runner = CliRunner(mix_stderr=False) result = runner.invoke(cli, ["missing"]) > assert result.exit_code == 2 E assert 1 == 2 E + where 1 = <Result DeprecationWarning("module 'sre_constants' is deprecated")>.exit_code tests/test_cli.py:427: AssertionError _________________________ test_help_echo_loading_error _________________________ def test_help_echo_loading_error(): from flask.cli import cli runner = CliRunner(mix_stderr=False) result = runner.invoke(cli, ["--help"]) > assert result.exit_code == 0 E assert 1 == 0 E + where 1 = <Result DeprecationWarning("module 'sre_constants' is deprecated")>.exit_code tests/test_cli.py:437: AssertionError ___________________________ test_help_echo_exception ___________________________ def test_help_echo_exception(): def create_app(): raise Exception("oh no") cli = FlaskGroup(create_app=create_app) runner = CliRunner(mix_stderr=False) result = runner.invoke(cli, ["--help"]) > assert result.exit_code == 0 E assert 1 == 0 E + where 1 = <Result DeprecationWarning("module 'sre_constants' is deprecated")>.exit_code tests/test_cli.py:449: AssertionError ____________________________ TestRoutes.test_simple ____________________________ self = <test_cli.TestRoutes object at 0x7fc24655a7d0> invoke = functools.partial(<bound method CliRunner.invoke of <click.testing.CliRunner object at 0x7fc2464bfb90>>, <FlaskGroup None>) def test_simple(self, invoke): result = invoke(["routes"]) > assert result.exit_code == 0 E assert 1 == 0 E + where 1 = <Result DeprecationWarning("module 'sre_constants' is deprecated")>.exit_code tests/test_cli.py:493: AssertionError _________________________ TestRoutes.test_all_methods __________________________ self = <test_cli.TestRoutes object at 0x7fc24655aa10> invoke = functools.partial(<bound method CliRunner.invoke of <click.testing.CliRunner object at 0x7fc246713610>>, <FlaskGroup None>) def test_all_methods(self, invoke): output = invoke(["routes"]).output assert "GET, HEAD, OPTIONS, POST" not in output output = invoke(["routes", "--all-methods"]).output > assert "GET, HEAD, OPTIONS, POST" in output E AssertionError: assert 'GET, HEAD, OPTIONS, POST' in '' tests/test_cli.py:517: AssertionError __________________________ TestRoutes.test_no_routes ___________________________ self = <test_cli.TestRoutes object at 0x7fc246445510> invoke_no_routes = functools.partial(<bound method CliRunner.invoke of <click.testing.CliRunner object at 0x7fc247bb0d10>>, <FlaskGroup None>) def test_no_routes(self, invoke_no_routes): result = invoke_no_routes(["routes"]) > assert result.exit_code == 0 E assert 1 == 0 E + where 1 = <Result DeprecationWarning("module 'sre_constants' is deprecated")>.exit_code tests/test_cli.py:521: AssertionError =========================== short test summary info ============================ FAILED tests/test_cli.py::test_flaskgroup - assert 1 == 0 FAILED tests/test_cli.py::test_flaskgroup_debug[True] - assert 1 == 0 FAILED tests/test_cli.py::test_flaskgroup_debug[False] - assert 1 == 0 FAILED tests/test_cli.py::test_no_command_echo_loading_error - assert 1 == 2 FAILED tests/test_cli.py::test_help_echo_loading_error - assert 1 == 0 FAILED tests/test_cli.py::test_help_echo_exception - assert 1 == 0 FAILED tests/test_cli.py::TestRoutes::test_simple - assert 1 == 0 FAILED tests/test_cli.py::TestRoutes::test_all_methods - AssertionError: asse... FAILED tests/test_cli.py::TestRoutes::test_no_routes - assert 1 == 0 ============= 9 failed, 445 passed, 14 skipped, 3 xpassed in 3.91s ============= error: Bad exit status from /var/tmp/rpm-tmp.QxHnVd (%check) Undocumented modules sre_compile, sre_constants and sre_parse are now deprecated. (Contributed by Serhiy Storchaka in bpo-47152.) https://bugs.python.org/issue?@action=redirect&bpo=47152 https://docs.python.org/3.11/whatsnew/3.11.html For the build logs, see: https://copr-be.cloud.fedoraproject.org/results/@python/python3.11/fedora-rawhide-x86_64/04221098-python-flask/ For all our attempts to build python-flask with Python 3.11, see: https://copr.fedorainfracloud.org/coprs/g/python/python3.11/package/python-flask/ Testing and mass rebuild of packages is happening in copr. You can follow these instructions to test locally in mock if your package builds with Python 3.11: https://copr.fedorainfracloud.org/coprs/g/python/python3.11/ Let us know here if you have any questions. Python 3.11 is planned to be included in Fedora 37. To make that update smoother, we're building Fedora packages with all pre-releases of Python 3.11. A build failure prevents us from testing all dependent packages (transitive [Build]Requires), so if this package is required a lot, it's important for us to get it fixed soon. We'd appreciate help from the people who know this package best, but if you don't want to work on this now, let us know so we can try to work around it on our side.
*** This bug has been marked as a duplicate of bug 2075487 ***