Bug 2259648 - python-flask-compress FTBFS with python-setuptools 69.0.3 (coming to Fedora Rawhide)
Summary: python-flask-compress FTBFS with python-setuptools 69.0.3 (coming to Fedora R...
Keywords:
Status: CLOSED RAWHIDE
Alias: None
Product: Fedora
Classification: Fedora
Component: python-flask-compress
Version: rawhide
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Iztok Fister Jr.
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks: F40FTBFS 2250718
TreeView+ depends on / blocked
 
Reported: 2024-01-22 14:29 UTC by Karolina Surma
Modified: 2024-02-06 15:02 UTC (History)
4 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2024-02-06 15:02:00 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Fedora Package Sources python-flask-compress pull-request 3 0 None None None 2024-01-26 19:41:35 UTC

Description Karolina Surma 2024-01-22 14:29:36 UTC
python-flask-compress FTBFS with python-setuptools 69.0.3 (coming to Fedora Rawhide).

/usr/lib/python3.12/site-packages/setuptools/config/_apply_pyprojecttoml.py:75: _MissingDynamic: `readme` defined outside of `pyproject.toml` is ignored.
!!

        ********************************************************************************
        The following seems to be defined outside of `pyproject.toml`:

        `readme = '# Flask-Compress\n\n[![Build](https://github.com/colour-science/flask-compress/actions/workflows/ci.yaml/badge.svg)](https://github.com/colour-science/flask-compress/actions/workflows/ci.yaml)\n[![Version](https://img.shields.io/pypi/v/flask-compress.svg)](https://pypi.python.org/pypi/Flask-Compress)\n[![Downloads](https://static.pepy.tech/badge/flask-compress)](https://pypi.python.org/pypi/Flask-Compress)\n\nFlask-Compress allows you to easily compress your [Flask](http://flask.pocoo.org/) application\'s responses with gzip, deflate or brotli. It originally started as a fork of [Flask-gzip](https://github.com/closeio/Flask-gzip).\n\nThe preferred solution is to have a server (like [Nginx](http://wiki.nginx.org/Main)) automatically compress the static files for you. If you don\'t have that option Flask-Compress will solve the problem for you.\n\n\n## How it works\n\nFlask-Compress both adds the various headers required for a compressed response and compresses the response data. \nThis makes serving compressed static files extremely easy.\n\nInternally, every time a request is made the extension will check if it matches one of the compressible MIME types\nand whether the client and the server use some common compression algorithm, and will automatically attach the \nappropriate headers.\n\nTo determine the compression algorithm, the `Accept-Encoding` request header is inspected, respecting the\nquality factor as described in [MDN docs](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Accept-Encoding). \nIf no requested compression algorithm is supported by the server, we don\'t compress the response. If, on the other\nhand, multiple suitable algorithms are found and are requested with the same quality factor, we choose the first one\ndefined in the `COMPRESS_ALGORITHM` option (see below). \n\n\n## Installation\n\nIf you use pip then installation is simply:\n\n```shell\n$ pip install --user flask-compress\n```\n\nor, if you want the latest github version:\n\n```shell\n$ pip install --user git+git://github.com/colour-science/flask-compress.git\n```\n\nYou can also install Flask-Compress via Easy Install:\n\n```shell\n$ easy_install flask-compress\n```\n\n\n## Using Flask-Compress\n\n### Globally\n\nFlask-Compress is incredibly simple to use. In order to start compressing your Flask application\'s assets, the first thing to do is let Flask-Compress know about your [`flask.Flask`](http://flask.pocoo.org/docs/latest/api/#flask.Flask) application object.\n\n```python\nfrom flask import Flask\nfrom flask_compress import Compress\n\napp = Flask(__name__)\nCompress(app)\n```\n\nIn many cases, however, one cannot expect a Flask instance to be ready at import time, and a common pattern is to return a Flask instance from within a function only after other configuration details have been taken care of. In these cases, Flask-Compress provides a simple function, `flask_compress.Compress.init_app`, which takes your application as an argument.\n\n```python\nfrom flask import Flask\nfrom flask_compress import Compress\n\ncompress = Compress()\n\ndef start_app():\n    app = Flask(__name__)\n    compress.init_app(app)\n    return app\n```\n\nIn terms of automatically compressing your assets, passing your [`flask.Flask`](http://flask.pocoo.org/docs/latest/api/#flask.Flask) object to the `flask_compress.Compress` object is all that needs to be done.\n\n### Per-view compression\n\nCompression is possible per view using the `@compress.compressed()` decorator. Make sure to disable global compression first.\n\n```python\nfrom flask import Flask\nfrom flask_compress import Compress\n\napp = Flask(__name__)\napp.config["COMPRESS_REGISTER"] = False  # disable default compression of all eligible requests\ncompress = Compress()\ncompress.init_app(app)\n\n# Compress this view specifically\n("/test")\n()\ndef view():\n   pass\n```\n\n## Options\n\nWithin your Flask application\'s settings you can provide the following settings to control the behavior of Flask-Compress. None of the settings are required.\n\n| Option | Description | Default |\n| ------ | ----------- | ------- |\n| `COMPRESS_MIMETYPES` | Set the list of mimetypes to compress here. | `[`<br>`\'text/html\',`<br>`\'text/css\',`<br>`\'text/xml\',`<br>`\'application/json\',`<br>`\'application/javascript\'`<br>`]` |\n| `COMPRESS_LEVEL` | Specifies the gzip compression level. | `6` |\n| `COMPRESS_BR_LEVEL` | Specifies the Brotli compression level. Ranges from 0 to 11. | `4` |\n| `COMPRESS_BR_MODE` | For Brotli, the compression mode. The options are 0, 1, or 2. These correspond to "generic", "text" (for UTF-8 input), and "font" (for WOFF 2.0). | `0` |\n| `COMPRESS_BR_WINDOW` | For Brotli, this specifies the base-2 logarithm of the sliding window size. Ranges from 10 to 24. | `22` |\n| `COMPRESS_BR_BLOCK` | For Brotli, this provides the base-2 logarithm of the maximum input block size. If zero is provided, value will be determined based on the quality. Ranges from 16 to 24. | `0` |\n| `COMPRESS_DEFLATE_LEVEL` | Specifies the deflate compression level. | `-1` |\n| `COMPRESS_MIN_SIZE` | Specifies the minimum file size threshold for compressing files. | `500` |\n| `COMPRESS_CACHE_KEY` | Specifies the cache key method for lookup/storage of response data. | `None` |\n| `COMPRESS_CACHE_BACKEND` | Specified the backend for storing the cached response data. | `None` |\n| `COMPRESS_REGISTER` | Specifies if compression should be automatically registered. | `True` |\n| `COMPRESS_ALGORITHM` | Supported compression algorithms. | `[\'br\', \'gzip\', \'deflate\']` |\n| `COMPRESS_STREAMS` | Compress content streams. | `True` |\n'`

        According to the spec (see the link below), however, setuptools CANNOT
        consider this value unless `readme` is listed as `dynamic`.

        https://packaging.python.org/en/latest/specifications/pyproject-toml/#declaring-project-metadata-the-project-table

        To prevent this problem, you can list `readme` under `dynamic` or alternatively
        remove the `[project]` table from your file and rely entirely on other means of
        configuration.
        ********************************************************************************

!!
  _handle_missing_dynamic(dist, project_table)
/usr/lib/python3.12/site-packages/setuptools/config/_apply_pyprojecttoml.py:75: _MissingDynamic: `license` defined outside of `pyproject.toml` is ignored.
!!

        ********************************************************************************
        The following seems to be defined outside of `pyproject.toml`:

        `license = 'MIT'`

        According to the spec (see the link below), however, setuptools CANNOT
        consider this value unless `license` is listed as `dynamic`.

        https://packaging.python.org/en/latest/specifications/pyproject-toml/#declaring-project-metadata-the-project-table

        To prevent this problem, you can list `license` under `dynamic` or alternatively
        remove the `[project]` table from your file and rely entirely on other means of
        configuration.
        ********************************************************************************

!!
  _handle_missing_dynamic(dist, project_table)
/usr/lib/python3.12/site-packages/setuptools/config/_apply_pyprojecttoml.py:75: _MissingDynamic: `authors` defined outside of `pyproject.toml` is ignored.
!!

        ********************************************************************************
        The following seems to be defined outside of `pyproject.toml`:

        `authors = 'Thomas Mansencal'`

        According to the spec (see the link below), however, setuptools CANNOT
        consider this value unless `authors` is listed as `dynamic`.

        https://packaging.python.org/en/latest/specifications/pyproject-toml/#declaring-project-metadata-the-project-table

        To prevent this problem, you can list `authors` under `dynamic` or alternatively
        remove the `[project]` table from your file and rely entirely on other means of
        configuration.
        ********************************************************************************

!!
  _handle_missing_dynamic(dist, project_table)
/usr/lib/python3.12/site-packages/setuptools/config/_apply_pyprojecttoml.py:75: _MissingDynamic: `classifiers` defined outside of `pyproject.toml` is ignored.
!!

        ********************************************************************************
        The following seems to be defined outside of `pyproject.toml`:

        `classifiers = ['Environment :: Web Environment', 'Intended Audience :: Developers', 'License :: OSI Approved :: MIT License', 'Operating System :: OS Independent', 'Programming Language :: Python :: 2', 'Programming Language :: Python :: 2.6', 'Programming Language :: Python :: 2.7', 'Programming Language :: Python :: 3', 'Programming Language :: Python :: 3.6', 'Programming Language :: Python :: 3.7', 'Programming Language :: Python :: 3.8', 'Programming Language :: Python :: 3.9', 'Topic :: Internet :: WWW/HTTP :: Dynamic Content', 'Topic :: Software Development :: Libraries :: Python Modules']`

        According to the spec (see the link below), however, setuptools CANNOT
        consider this value unless `classifiers` is listed as `dynamic`.

        https://packaging.python.org/en/latest/specifications/pyproject-toml/#declaring-project-metadata-the-project-table

        To prevent this problem, you can list `classifiers` under `dynamic` or alternatively
        remove the `[project]` table from your file and rely entirely on other means of
        configuration.
        ********************************************************************************

!!
  _handle_missing_dynamic(dist, project_table)
/usr/lib/python3.12/site-packages/setuptools/config/_apply_pyprojecttoml.py:75: _MissingDynamic: `dependencies` defined outside of `pyproject.toml` is ignored.
!!

        ********************************************************************************
        The following seems to be defined outside of `pyproject.toml`:

        `dependencies = ['flask', 'brotli']`

        According to the spec (see the link below), however, setuptools CANNOT
        consider this value unless `dependencies` is listed as `dynamic`.

        https://packaging.python.org/en/latest/specifications/pyproject-toml/#declaring-project-metadata-the-project-table

        To prevent this problem, you can list `dependencies` under `dynamic` or alternatively
        remove the `[project]` table from your file and rely entirely on other means of
        configuration.
        ********************************************************************************

Build logs:
https://download.copr.fedorainfracloud.org/results/ksurma/setuptools-69.0.3:custom:isolated/fedora-rawhide-x86_64/06907345-python-flask-compress/builder-live.log.gz

All build attempts:
https://copr.fedorainfracloud.org/coprs/ksurma/setuptools-69.0.3/package/python-flask-compress/

Comment 3 Sandro 2024-02-06 15:02:00 UTC
https://bodhi.fedoraproject.org/updates/FEDORA-2024-7899561043

This should have been closed by Bodhi.


Note You need to log in before you can comment on or make changes to this bug.