Changelog
### 5.1.1
```
=====
:release-date: 2022-03-06 12:45 P.M. UTC+6:00
:release-by: Asif Saif Uddin
- Use AF_UNSPEC for name resolution (389).
.. _version-5.1.0:
```
### 5.1.0
```
=====
:release-date: 2022-03-06 10:05 A.M. UTC+6:00
:release-by: Asif Saif Uddin
- Improve performance of _get_free_channel_id, fix channel max bug (385).
- Document memoryview usage, minor frame_writer.write_frame refactor (384).
- Start dropping python 3.6 (387).
- Added experimental __slots__ to some classes (368)
- Relaxed vine version for upcoming release.
- Upgraded topytest 7 (388).
.. _version-5.0.9:
```
### 5.0.9
```
=====
:release-date: 2021-12-20 11:00 A.M. UTC+6:00
:release-by: Asif Saif Uddin
- Append to _used_channel_ids in _used_channel_ids
.. _version-5.0.8:
```
### 5.0.8
```
=====
:release-date: 2021-12-19 11:15 A.M. UTC+6:00
:release-by: Asif Saif Uddin
- Reduce memory usage of Connection (377)
- Add additional error handling around code where an OSError
may be raised on failed connections. Fixes (378)
.. _version-5.0.7:
```
### 5.0.7
```
=====
:release-date: 2021-12-13 15:45 P.M. UTC+6:00
:release-by: Asif Saif Uddin
- Remove dependency to case
- Bugfix: not closing socket after server disconnect
.. _version-5.0.6:
```
### 5.0.6
```
=====
:release-date: 2021-04-01 10:45 A.M. UTC+6:00
:release-by: Asif Saif Uddin
- Change the order in which context.check_hostname and context.verify_mode get set
in SSLTransport._wrap_socket_sni. Fixes bug introduced in 5.0.3 where setting
context.verify_mode = ssl.CERT_NONE would raise
"ValueError: Cannot set verify_mode to CERT_NONE when check_hostname is enabled."
Setting context.check_hostname prior to setting context.verify_mode resolves the
issue.
- Remove TCP_USER_TIMEOUT option for Solaris (355)
- Pass long_description to setup() (353)
- Fix for tox-docker 2.0
- Moved to GitHub actions CI (359)
.. _version-5.0.5:
```
### 5.0.5
```
=====
:release-date: 2021-01-28 4:30 P.M UTC+6:00
:release-by: Asif Saif Uddin
- Removed mistakenly introduced code which was causing import errors
.. _version-5.0.4:
```
### 5.0.4
```
=====
:release-date: 2021-01-28 2:30 P.M UTC+6:00
:release-by: Asif Saif Uddin
- Add missing load_default_certs() call to fix a regression in v5.0.3 release. (350)
.. _version-5.0.3:
```
### 5.0.3
```
=====
:release-date: 2021-01-19 9:00 P.M UTC+6:00
:release-by: Asif Saif Uddin
- Change the default value of ssl_version to None. When not set, the
proper value between ssl.PROTOCOL_TLS_CLIENT and ssl.PROTOCOL_TLS_SERVER
will be selected based on the param server_side in order to create
a TLS Context object with better defaults that fit the desired
connection side.
- Change the default value of cert_reqs to None. The default value
of ctx.verify_mode is ssl.CERT_NONE, but when ssl.PROTOCOL_TLS_CLIENT
is used, ctx.verify_mode defaults to ssl.CERT_REQUIRED.
- Fix context.check_hostname logic. Checking the hostname depends on
having support of the SNI TLS extension and being provided with a
server_hostname value. Another important thing to mention is that
enabling hostname checking automatically sets verify_mode from
ssl.CERT_NONE to ssl.CERT_REQUIRED in the stdlib ssl and it cannot
be set back to ssl.CERT_NONE as long as hostname checking is enabled.
- Refactor the SNI tests to test one thing at a time and removing some
tests that were being repeated over and over.
.. _version-5.0.2:
```
### 5.0.2
```
=====
:release-date: 2020-11-08 6:50 P.M UTC+3:00
:release-by: Omer Katz
- Whhels are no longer universal.
Contributed by **Omer Katz**
- Added debug representation to Connection and *Transport classes
Contributed by **Matus Valo**
- Reintroduce ca_certs and ciphers parameters of SSLTransport._wrap_socket_sni()
This fixes issue introduced in commit: 53d6777
Contributed by **Matus Valo**
- Fix infinite wait when using confirm_publish
Contributed by **Omer Katz** & **RezaSi**
.. _version-5.0.1:
```
### 5.0.1
```
=====
:release-date: 2020-09-06 6:10 P.M UTC+3:00
:release-by: Omer Katz
- Require vine 5.0.0.
Contributed by **Omer Katz**
.. _version-5.0.0:
```
### 5.0.0
```
=====
:release-date: 2020-09-03 3:20 P.M UTC+3:00
:release-by: Omer Katz
- Stop to use deprecated method ssl.wrap_socket.
Contributed by **Hervé Beraud**
.. _version-5.0.0b1:
```
### 5.0.0b1
```
=======
:release-date: 2020-09-01 6:20 P.M UTC+3:00
:release-by: Omer Katz
- Dropped Python 3.5 support.
Contributed by **Omer Katz**
- Removed additional compatibility code.
Contributed by **Omer Katz**
.. _version-5.0.0a1:
```
### 5.0.0a1
```
=======
:release-date: 2019-04-01 4:30 P.M UTC+3:00
:release-by: Omer Katz
- Dropped Python 2.x support.
Contributed by **Omer Katz**
- Dropped Python 3.4 support.
Contributed by **Omer Katz**
- Depend on :pypi:`vine` 5.0.0a1.
Contributed by **Omer Katz**
Code Cleanups & Improvements:
- **Omer Katz**
.. _version-2.6.0:
```
### 2.6.1
```
=====
:release-date: 2020-07-31 10.30 P.M UTC+6:00
:release-by: Asif Saif Uddin
- Fix buffer overflow in frame_writer after frame_max is increased. `frame_writer`
allocates a `bytearray` on initialization with a length based on the `connection.frame_max`
value. If `connection.frame_max` is changed to a larger value, this causes an
error like `pack_into requires a buffer of at least 408736 bytes`.
.. _version-2.6.0:
```
### 2.6.0
```
=====
:release-date: 20-06-01 12.00 P.M UTC+6:00
:release-by: Asif Saif Uddin
- Implement speedups in cython (311)
- Updated some tests & code improvements
- Separate logger for Connection.heartbeat_tick method
- Cython generic content (315)
- Improve documentation a_global parameter of basic_qos() method.
- Fix saving partial read buffer on windows during socket timeout. (321)
- Fix deserialization of long string field values that are not utf-8.
- Added simple cythonization of abstract_channel.py
- Speedups of serialization.py are more restrictive
.. _version-2.5.2:
```
Links
- PyPI: https://pypi.org/project/amqp
- Changelog: https://pyup.io/changelogs/amqp/
- Repo: http://github.com/celery/py-amqp
Changelog
### 3.9.1
```
* Removed a leftover check for pytz ``localize()`` and ``normalize()`` methods
```
### 3.9.0
```
- Added support for PySide6 to the Qt scheduler
- No longer enforce pytz time zones (support for others is experimental in the 3.x series)
- Fixed compatibility with PyMongo 4
- Fixed pytz deprecation warnings
- Fixed RuntimeError when shutting down the scheduler from a scheduled job
```
### 3.8.1
```
- Allowed the use of tzlocal v4.0+ in addition to v2.*
```
### 3.8.0
```
- Allowed passing through keyword arguments to the underlying stdlib executors in the
thread/process pool executors (PR by Albert Xu)
```
### 3.7.0
```
- Dropped support for Python 3.4
- Added PySide2 support (PR by Abdulla Ibrahim)
- Pinned ``tzlocal`` to a version compatible with pytz
- Ensured that jitter is always non-negative to prevent triggers from firing more often than
intended
- Changed ``AsyncIOScheduler`` to obtain the event loop in ``start()`` instead of ``__init__()``,
to prevent situations where the scheduler won't run because it's using a different event loop
than then one currently running
- Made it possible to create weak references to ``Job`` instances
- Made the schedulers explicitly raise a descriptive ``TypeError`` when serialization is attempted
- Fixed Zookeeper job store using backslashes instead of forward slashes for paths
on Windows (PR by Laurel-rao)
- Fixed deprecation warnings on the MongoDB job store and increased the minimum PyMongo
version to 3.0
- Fixed ``BlockingScheduler`` and ``BackgroundScheduler`` shutdown hanging after the user has
erroneously tried to start it twice
- Fixed memory leak when coroutine jobs raise exceptions (due to reference cycles in tracebacks)
- Fixed inability to schedule wrapped functions with extra arguments when the wrapped function
cannot accept them but the wrapper can (original PR by Egor Malykh)
- Fixed potential ``where`` clause error in the SQLAlchemy job store when a subclass uses more than
one search condition
- Fixed a problem where bound methods added as jobs via textual references were called with an
unwanted extra ``self`` argument (PR by Pengjie Song)
- Fixed ``BrokenPoolError`` in ``ProcessPoolExecutor`` so that it will automatically replace the
broken pool with a fresh instance
```
Links
- PyPI: https://pypi.org/project/apscheduler
- Changelog: https://pyup.io/changelogs/apscheduler/
- Repo: https://github.com/agronholm/apscheduler
- Docs: https://pythonhosted.org/APScheduler/
Changelog
### 2.12.1
```
--------------
Fixes
~~~~~
* Version 2.12.0 was missing the ``py.typed`` marker file. Thanks to Alex Waygood for the fix! :gh:`975`
* The copyright year in all files was bumped to 2023.
```
### 2.12.0
```
--------------
Deprecations & breaking changes
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
* Python 3.6 is no longer supported (:gh:`919`) - Aarni Koskela
* The `get_next_timezone_transition` function is no more (:gh:`958`) - Aarni Koskela
New features
~~~~~~~~~~~~
* CLDR: Babel now uses CLDR 42 (:gh:`951`) - Aarni Koskela
* Dates: `pytz` is now optional; Babel will prefer it but will use `zoneinfo` when available. (:gh:`940`) - ds-cbo
* General: Babel now ships type annotations, thanks to Jonah Lawrence's work in multiple PRs.
* Locales: modifiers are now retained when parsing locales (:gh:`947`) - martin f. krafft
* Messages: JavaScript template string expression extraction is now smarter. (:gh:`939`) - Johannes Wilm
* Numbers: NaN and Infinity are now better supported (:gh:`955`) - Jonah Lawrence
* Numbers: Short compact currency formats are now supported (:gh:`926`) - Jonah Lawrence
* Numbers: There's now a `Format.compact_decimal` utility function. (:gh:`921`) - Jonah Lawrence
Bugfixes
~~~~~~~~
* Dates: The cache for parsed datetime patterns is now bounded (:gh:`967`) - Aarni Koskela
* Messages: Fuzzy candidate matching accuracy is improved (:gh:`970`) - Jean Abou Samra
* Numbers: Compact singular formats and patterns with no numbers work correctly (:gh:`930`, :gh:`932`) - Jonah Lawrence, Jun Omae
Improvements & cleanup
~~~~~~~~~~~~~~~~~~~~~~
* Dates: `babel.dates.UTC` is now an alias for `datetime.timezone.utc` (:gh:`957`) - Aarni Koskela
* Dates: `babel.localtime` was slightly cleaned up. (:gh:`952`) - Aarni Koskela
* Documentation: Documentation was improved by Maciej Olko, Jonah Lawrence, lilinjie, and Aarni Koskela.
* Infrastructure: Babel is now being linted with pre-commit and ruff. - Aarni Koskela
```
### 2.11.0
```
--------------
Upcoming deprecation
~~~~~~~~~~~~~~~~~~~~
* This version, Babel 2.11, is the last version of Babel to support Python 3.6.
Babel 2.12 will require Python 3.7 or newer.
Improvements
~~~~~~~~~~~~
* Support for hex escapes in JavaScript string literals :gh:`877` - Przemyslaw Wegrzyn
* Add support for formatting decimals in compact form :gh:`909` - Jonah Lawrence
* Adapt parse_date to handle ISO dates in ASCII format :gh:`842` - Eric L.
* Use `ast` instead of `eval` for Python string extraction :gh:`915` - Aarni Koskela
* This also enables extraction from static f-strings.
F-strings with expressions are silently ignored (but won't raise an error as they used to).
Infrastructure
~~~~~~~~~~~~~~
* Tests: Use regular asserts and ``pytest.raises()`` :gh:`875` – Aarni Koskela
* Wheels are now built in GitHub Actions :gh:`888` – Aarni Koskela
* Small improvements to the CLDR downloader script :gh:`894` – Aarni Koskela
* Remove antiquated `__nonzero__` methods :gh:`896` - Nikita Sobolev
* Remove superfluous `__unicode__` declarations :gh:`905` - Lukas Juhrich
* Mark package compatible with Python 3.11 :gh:`913` - Aarni Koskela
* Quiesce pytest warnings :gh:`916` - Aarni Koskela
Bugfixes
~~~~~~~~
* Use email.Message for pofile header parsing instead of the deprecated ``cgi.parse_header`` function. :gh:`876` – Aarni Koskela
* Remove determining time zone via systemsetup on macOS :gh:`914` - Aarni Koskela
Documentation
~~~~~~~~~~~~~
* Update Python versions in documentation :gh:`898` - Raphael Nestler
* Align BSD-3 license with OSI template :gh:`912` - Lukas Kahwe Smith
```
### 2.10.3
```
--------------
This is a bugfix release for Babel 2.10.2, which was mistakenly packaged with outdated locale data.
Thanks to Michał Górny for pointing this out and Jun Omae for verifying.
This and future Babel PyPI packages will be built by a more automated process,
which should make problems like this less likely to occur.
```
### 2.10.2
```
--------------
This is a bugfix release for Babel 2.10.1.
* Fallback count="other" format in format_currency() (:gh:`872`) - Jun Omae
* Fix get_period_id() with ``dayPeriodRule`` across 0:00 (:gh:`871`) - Jun Omae
* Add support for ``b`` and ``B`` period symbols in time format (:gh:`869`) - Jun Omae
* chore(docs/typo): Fixes a minor typo in a function comment (:gh:`864`) - Frank Harrison
```
### 2.10.1
```
--------------
This is a bugfix release for Babel 2.10.0.
* Messages: Fix ``distutils`` import. Regressed in :gh:`843`. (:gh:`852`) - Nehal J Wani
* The wheel file is no longer marked as universal, since Babel only supports Python 3.
```
### 2.10.0
```
--------------
Upcoming deprecation
~~~~~~~~~~~~~~~~~~~~
* The ``get_next_timezone_transition()`` function is marked deprecated in this version and will be removed
likely as soon as Babel 2.11. No replacement for this function is planned; based on discussion in
:gh:`716`, it's likely the function is not used in any real code. (:gh:`852`) - Aarni Koskela, Paul Ganssle
Improvements
~~~~~~~~~~~~
* CLDR: Upgrade to CLDR 41.0. (:gh:`853`) - Aarni Koskela
* The ``c`` and ``e`` plural form operands introduced in CLDR 40 are parsed, but otherwise unsupported. (:gh:`826`)
* Non-nominative forms of units are currently ignored.
* Messages: Implement ``--init-missing`` option for ``pybabel update`` (:gh:`785`) - ruro
* Messages: For ``extract``, you can now replace the built-in ``.*`` / ``_*`` ignored directory patterns
with ones of your own. (:gh:`832`) - Aarni Koskela, Kinshuk Dua
* Messages: Add ``--check`` to verify if catalogs are up-to-date (:gh:`831`) - Krzysztof Jagiełło
* Messages: Add ``--header-comment`` to override default header comment (:gh:`720`) - Mohamed Hafez Morsy, Aarni Koskela
* Dates: ``parse_time`` now supports 12-hour clock, and is better at parsing partial times.
(:gh:`834`) - Aarni Koskela, David Bauer, Arthur Jovart
* Dates: ``parse_date`` and ``parse_time`` now raise ``ParseError``, a subclass of ``ValueError``, in certain cases.
(:gh:`834`) - Aarni Koskela
* Dates: ``parse_date`` and ``parse_time`` now accept the ``format`` parameter.
(:gh:`834`) - Juliette Monsel, Aarni Koskela
Infrastructure
~~~~~~~~~~~~~~
* The internal ``babel/_compat.py`` module is no more (:gh:`808`) - Hugo van Kemenade
* Python 3.10 is officially supported (:gh:`809`) - Hugo van Kemenade
* There's now a friendly GitHub issue template. (:gh:`800`) – Álvaro Mondéjar Rubio
* Don't use the deprecated format_number function internally or in tests - Aarni Koskela
* Add GitHub URL for PyPi (:gh:`846`) - Andrii Oriekhov
* Python 3.12 compatibility: Prefer setuptools imports to distutils imports (:gh:`843`) - Aarni Koskela
* Python 3.11 compatibility: Add deprecations to l*gettext variants (:gh:`835`) - Aarni Koskela
* CI: Babel is now tested with PyPy 3.7. (:gh:`851`) - Aarni Koskela
Bugfixes
~~~~~~~~
* Date formatting: Allow using ``other`` as fallback form (:gh:`827`) - Aarni Koskela
* Locales: ``Locale.parse()`` normalizes variant tags to upper case (:gh:`829`) - Aarni Koskela
* A typo in the plural format for Maltese is fixed. (:gh:`796`) - Lukas Winkler
* Messages: Catalog date parsing is now timezone independent. (:gh:`701`) - rachele-collin
* Messages: Fix duplicate locations when writing without lineno (:gh:`837`) - Sigurd Ljødal
* Messages: Fix missing trailing semicolon in plural form headers (:gh:`848`) - farhan5900
* CLI: Fix output of ``--list-locales`` to not be a bytes repr (:gh:`845`) - Morgan Wahl
Documentation
~~~~~~~~~~~~~
* Documentation is now correctly built again, and up to date (:gh:`830`) - Aarni Koskela
```
### 2.9.1
```
-------------
Bugfixes
~~~~~~~~
* The internal locale-data loading functions now validate the name of the locale file to be loaded and only
allow files within Babel's data directory. Thank you to Chris Lyne of Tenable, Inc. for discovering the issue!
```
### 2.9.0
```
-------------
Upcoming version support changes
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
* This version, Babel 2.9, is the last version of Babel to support Python 2.7, Python 3.4, and Python 3.5.
Improvements
~~~~~~~~~~~~
* CLDR: Use CLDR 37 – Aarni Koskela (:gh:`734`)
* Dates: Handle ZoneInfo objects in get_timezone_location, get_timezone_name - Alessio Bogon (:gh:`741`)
* Numbers: Add group_separator feature in number formatting - Abdullah Javed Nesar (:gh:`726`)
Bugfixes
~~~~~~~~
* Dates: Correct default Format().timedelta format to 'long' to mute deprecation warnings – Aarni Koskela
* Import: Simplify iteration code in "import_cldr.py" – Felix Schwarz
* Import: Stop using deprecated ElementTree methods "getchildren()" and "getiterator()" – Felix Schwarz
* Messages: Fix unicode printing error on Python 2 without TTY. – Niklas Hambüchen
* Messages: Introduce invariant that _invalid_pofile() takes unicode line. – Niklas Hambüchen
* Tests: fix tests when using Python 3.9 – Felix Schwarz
* Tests: Remove deprecated 'sudo: false' from Travis configuration – Jon Dufresne
* Tests: Support Py.test 6.x – Aarni Koskela
* Utilities: LazyProxy: Handle AttributeError in specified func – Nikiforov Konstantin (:gh:`724`)
* Utilities: Replace usage of parser.suite with ast.parse – Miro Hrončok
Documentation
~~~~~~~~~~~~~
* Update parse_number comments – Brad Martin (:gh:`708`)
* Add __iter__ to Catalog documentation – CyanNani123
```
### 2.8.1
```
-------------
This is solely a patch release to make running tests on Py.test 6+ possible.
Bugfixes
~~~~~~~~
* Support Py.test 6 - Aarni Koskela (:gh:`747`, :gh:`750`, :gh:`752`)
```
Links
- PyPI: https://pypi.org/project/babel
- Changelog: https://pyup.io/changelogs/babel/
- Homepage: https://babel.pocoo.org/
- Docs: https://pythonhosted.org/Babel/
Changelog
### 4.11.1
```
This release was done to ensure that the unit tests are packaged along
with the released source. There are no functionality changes in this
release, but there are a few other packaging changes:
* The Japanese and Korean translations of the documentation are included.
* The changelog is now packaged as CHANGELOG, and the license file is
packaged as LICENSE. NEWS.txt and COPYING.txt are still present,
but may be removed in the future.
* TODO.txt is no longer packaged, since a TODO is not relevant for released
code.
```
### 4.11.0
```
* Ported unit tests to use pytest.
* Added special string classes, RubyParenthesisString and RubyTextString,
to make it possible to treat ruby text specially in get_text() calls.
[bug=1941980]
* It's now possible to customize the way output is indented by
providing a value for the 'indent' argument to the Formatter
constructor. The 'indent' argument works very similarly to the
argument of the same name in the Python standard library's
json.dump() function. [bug=1955497]
* If the charset-normalizer Python module
(https://pypi.org/project/charset-normalizer/) is installed, Beautiful
Soup will use it to detect the character sets of incoming documents.
This is also the module used by newer versions of the Requests library.
For the sake of backwards compatibility, chardet and cchardet both take
precedence if installed. [bug=1955346]
* Added a workaround for an lxml bug
(https://bugs.launchpad.net/lxml/+bug/1948551) that causes
problems when parsing a Unicode string beginning with BYTE ORDER MARK.
[bug=1947768]
* Issue a warning when an HTML parser is used to parse a document that
looks like XML but not XHTML. [bug=1939121]
* Do a better job of keeping track of namespaces as an XML document is
parsed, so that CSS selectors that use namespaces will do the right
thing more often. [bug=1946243]
* Some time ago, the misleadingly named "text" argument to find-type
methods was renamed to the more accurate "string." But this supposed
"renaming" didn't make it into important places like the method
signatures or the docstrings. That's corrected in this
version. "text" still works, but will give a DeprecationWarning.
[bug=1947038]
* Fixed a crash when pickling a BeautifulSoup object that has no
tree builder. [bug=1934003]
* Fixed a crash when overriding multi_valued_attributes and using the
html5lib parser. [bug=1948488]
* Standardized the wording of the MarkupResemblesLocatorWarning
warnings to omit untrusted input and make the warnings less
judgmental about what you ought to be doing. [bug=1955450]
* Removed support for the iconv_codec library, which doesn't seem
to exist anymore and was never put up on PyPI. (The closest
replacement on PyPI, iconv_codecs, is GPL-licensed, so we can't use
it--it's also quite old.)
```
### 4.10.0
```
* This is the first release of Beautiful Soup to only support Python
3. I dropped Python 2 support to maintain support for newer versions
(58 and up) of setuptools. See:
https://github.com/pypa/setuptools/issues/2769 [bug=1942919]
* The behavior of methods like .get_text() and .strings now differs
depending on the type of tag. The change is visible with HTML tags
like <script>, <style>, and <template>. Starting in 4.9.0, methods
like get_text() returned no results on such tags, because the
contents of those tags are not considered 'text' within the document
as a whole.
But a user who calls script.get_text() is working from a different
definition of 'text' than a user who calls div.get_text()--otherwise
there would be no need to call script.get_text() at all. In 4.10.0,
the contents of (e.g.) a <script> tag are considered 'text' during a
get_text() call on the tag itself, but not considered 'text' during
a get_text() call on the tag's parent.
Because of this change, calling get_text() on each child of a tag
may now return a different result than calling get_text() on the tag
itself. That's because different tags now have different
understandings of what counts as 'text'. [bug=1906226] [bug=1868861]
* NavigableString and its subclasses now implement the get_text()
method, as well as the properties .strings and
.stripped_strings. These methods will either return the string
itself, or nothing, so the only reason to use this is when iterating
over a list of mixed Tag and NavigableString objects. [bug=1904309]
* The 'html5' formatter now treats attributes whose values are the
empty string as HTML boolean attributes. Previously (and in other
formatters), an attribute value must be set as None to be treated as
a boolean attribute. In a future release, I plan to also give this
behavior to the 'html' formatter. Patch by Isaac Muse. [bug=1915424]
* The 'replace_with()' method now takes a variable number of arguments,
and can be used to replace a single element with a sequence of elements.
Patch by Bill Chandos. [rev=605]
* Corrected output when the namespace prefix associated with a
namespaced attribute is the empty string, as opposed to
None. [bug=1915583]
* Performance improvement when processing tags that speeds up overall
tree construction by 2%. Patch by Morotti. [bug=1899358]
* Corrected the use of special string container classes in cases when a
single tag may contain strings with different containers; such as
the <template> tag, which may contain both TemplateString objects
and Comment objects. [bug=1913406]
* The html.parser tree builder can now handle named entities
found in the HTML5 spec in much the same way that the html5lib
tree builder does. Note that the lxml HTML tree builder doesn't handle
named entities this way. [bug=1924908]
* Added a second way to pass specify encodings to UnicodeDammit and
EncodingDetector, based on the order of precedence defined in the
HTML5 spec, starting at:
https://html.spec.whatwg.org/multipage/parsing.html#parsing-with-a-known-character-encoding
Encodings in 'known_definite_encodings' are tried first, then
byte-order-mark sniffing is run, then encodings in 'user_encodings'
are tried. The old argument, 'override_encodings', is now a
deprecated alias for 'known_definite_encodings'.
This changes the default behavior of the html.parser and lxml tree
builders, in a way that may slightly improve encoding
detection but will probably have no effect. [bug=1889014]
* Improve the warning issued when a directory name (as opposed to
the name of a regular file) is passed as markup into the BeautifulSoup
constructor. [bug=1913628]
```
### 4.9.3
```
* Implemented a significant performance optimization to the process of
searching the parse tree. Patch by Morotti. [bug=1898212]
```
### 4.9.2
```
* Fixed a bug that caused too many tags to be popped from the tag
stack during tree building, when encountering a closing tag that had
no matching opening tag. [bug=1880420]
* Fixed a bug that inconsistently moved elements over when passing
a Tag, rather than a list, into Tag.extend(). [bug=1885710]
* Specify the soupsieve dependency in a way that complies with
PEP 508. Patch by Mike Nerone. [bug=1893696]
* Change the signatures for BeautifulSoup.insert_before and insert_after
(which are not implemented) to match PageElement.insert_before and
insert_after, quieting warnings in some IDEs. [bug=1897120]
```
### 4.9.1
```
* Added a keyword argument 'on_duplicate_attribute' to the
BeautifulSoupHTMLParser constructor (used by the html.parser tree
builder) which lets you customize the handling of markup that
contains the same attribute more than once, as in:
<a href="url1" href="url2"> [bug=1878209]
* Added a distinct subclass, GuessedAtParserWarning, for the warning
issued when BeautifulSoup is instantiated without a parser being
specified. [bug=1873787]
* Added a distinct subclass, MarkupResemblesLocatorWarning, for the
warning issued when BeautifulSoup is instantiated with 'markup' that
actually seems to be a URL or the path to a file on
disk. [bug=1873787]
* The new NavigableString subclasses (Stylesheet, Script, and
TemplateString) can now be imported directly from the bs4 package.
* If you encode a document with a Python-specific encoding like
'unicode_escape', that encoding is no longer mentioned in the final
XML or HTML document. Instead, encoding information is omitted or
left blank. [bug=1874955]
* Fixed test failures when run against soupselect 2.0. Patch by Tomáš
Chvátal. [bug=1872279]
```
Links
- PyPI: https://pypi.org/project/beautifulsoup4
- Changelog: https://pyup.io/changelogs/beautifulsoup4/
Changelog
### 5.0.1
```
-------------------------------
**Bugs**
* Add missing comma to tinycss2 require. Thank you, shadchin!
* Add url parse tests based on wpt url tests. (688)
* Support scheme-less urls if "https" is in allow list. (662)
* Handle escaping ``<`` in edge cases where it doesn't start a tag. (544)
* Fix reference warnings in docs. (660)
* Correctly urlencode email address parts. Thank you, larseggert! (659)
```
### 5.0.0
```
-------------------------------
**Backwards incompatible changes**
* ``clean`` and ``linkify`` now preserve the order of HTML attributes. Thank
you, askoretskly! (566)
* Drop support for Python 3.6. Thank you, hugovk! (629)
* CSS sanitization in style tags is completely different now. If you're using
Bleach ``clean`` to sanitize css in style tags, you'll need to update your
code and you'll need to install the ``css`` extras::
pip install 'bleach[css]'
See `the documentation on sanitizing CSS for how to do it
<https://bleach.readthedocs.io/en/latest/clean.html#sanitizing-css>`_. (633)
**Bug fixes**
* Rework dev dependencies. We no longer have
``requirements-dev.in``/``requirements-dev.txt``. Instead, we're using
``dev`` extras.
See `development docs <https://bleach.readthedocs.io/en/latest/dev.html>`_
for more details. (620)
* Add newline when dropping block-level tags. Thank you, jvanasco! (369)
```
### 4.1.0
```
---------------------------------
**Features**
* Python 3.9 support
**Bug fixes**
* Update sanitizer clean to use vendored 3.6.14 stdlib urllib.parse to
fix test failures on Python 3.9. (536)
```
### 4.0.0
```
--------------------------------
**Backwards incompatible changes**
* Drop support for unsupported Python versions <3.6. (520)
**Security fixes**
None
**Features**
* fix attribute name in the linkify docs (thanks CheesyFeet!)
```
### 3.3.1
```
-------------------------------
**Security fixes**
None
**Features**
* add more tests for CVE-2021-23980 / GHSA-vv2x-vrpj-qqpq
* bump python version to 3.8 for tox doc, vendorverify, and lint targets
* update bug report template tag
* update vendorverify script to detect and fail when extra files are vendored
* update release process docs to check vendorverify passes locally
**Bug fixes**
* remove extra vendored django present in the v3.3.0 whl (595)
* duplicate h1 header doc fix (thanks Nguyễn Gia Phong / McSinyx!)
```
Links
- PyPI: https://pypi.org/project/bleach
- Changelog: https://pyup.io/changelogs/bleach/
- Repo: https://github.com/mozilla/bleach
- Docs: https://pythonhosted.org/bleach/
Changelog
### 1.6.2
```
-------------
Released 2023-04-12
- Type annotations are not evaluated at runtime. typing-extensions is not a runtime
dependency. :pr:`94`
```
### 1.6.1
```
-------------
Released 2023-04-09
- Ensure that py.typed is present in the distributions (to enable other
projects to use blinker's typing).
- Require typing-extensions > 4.2 to ensure it includes
ParamSpec. :issue:`90`
```
### 1.6
```
-----------
Released 2023-04-02
- Add a muted context manager to temporarily turn off a
signal. :pr:`84`
- Allow int senders (alongside existing string senders). :pr:`83`
- Add a send_async method to the Signal to allow signals to send to
coroutine receivers. :pr:`76`
- Update and modernise the project structure to match that used by the
pallets projects. :pr:`77`
- Add an intial set of type hints for the project.
```
### 1.5
```
-----------
Released 2022-07-17
- Support Python >= 3.7 and PyPy. Python 2, Python < 3.7, and Jython
may continue to work, but the next release will make incompatible
changes.
```
Links
- PyPI: https://pypi.org/project/blinker
- Changelog: https://pyup.io/changelogs/blinker/
Changelog
### 5.2.1
```
===================
- Add support for Python 3.11.
- Correct version information in RTD documentation.
- ``badges/shields``: Change to GitHub workflow badge routes.
```
### 5.2.0
```
===================
- Add ``cachetools.keys.methodkey()``.
- Add ``cache_clear()`` function to decorators.
- Add ``src`` directory to ``sys.path`` for Sphinx autodoc.
- Modernize ``func`` wrappers.
```
### 5.1.0
```
===================
- Add cache decorator parameters as wrapper function attributes.
```
### 5.0.0
```
===================
- Require Python 3.7 or later (breaking change).
- Remove deprecated submodules (breaking change).
The ``cache``, ``fifo``, ``lfu``, ``lru``, ``mru``, ``rr`` and
``ttl`` submodules have been deleted. Therefore, statements like
``from cachetools.ttl import TTLCache``
will no longer work. Use
``from cachetools import TTLCache``
instead.
- Pass ``self`` to ``cachedmethod`` key function (breaking change).
The ``key`` function passed to the ``cachedmethod`` decorator is
now called as ``key(self, *args, **kwargs)``.
The default key function has been changed to ignore its first
argument, so this should only affect applications using custom key
functions with the ``cachedmethod`` decorator.
- Change exact time of expiration in ``TTLCache`` (breaking change).
``TTLCache`` items now get expired if their expiration time is less
than *or equal to* ``timer()``. For applications using the default
``timer()``, this should be barely noticable, but it may affect the
use of custom timers with larger tick intervals. Note that this
also implies that a ``TTLCache`` with ``ttl=0`` can no longer hold
any items, since they will expire immediately.
- Change ``Cache.__repr__()`` format (breaking change).
String representations of cache instances now use a more compact and
efficient format, e.g.
``LRUCache({1: 1, 2: 2}, maxsize=10, currsize=2)``
- Add TLRU cache implementation.
- Documentation improvements.
```
### 4.2.4
```
===================
- Add submodule shims for backward compatibility.
```
### 4.2.3
```
===================
- Add documentation and tests for using ``TTLCache`` with
``datetime``.
- Link to typeshed typing stubs.
- Flatten package file hierarchy.
```
### 4.2.2
```
===================
- Update build environment.
- Remove Python 2 remnants.
- Format code with Black.
```
### 4.2.1
```
===================
- Handle ``__missing__()`` not storing cache items.
- Clean up ``__missing__()`` example.
```
### 4.2.0
```
===================
- Add FIFO cache implementation.
- Add MRU cache implementation.
- Improve behavior of decorators in case of race conditions.
- Improve documentation regarding mutability of caches values and use
of key functions with decorators.
- Officially support Python 3.9.
```
### 4.1.1
```
===================
- Improve ``popitem()`` exception context handling.
- Replace ``float('inf')`` with ``math.inf``.
- Improve "envkey" documentation example.
```
Links
- PyPI: https://pypi.org/project/cachetools
- Changelog: https://pyup.io/changelogs/cachetools/
- Repo: https://github.com/tkem/cachetools/
Changelog
### 8.1.3
```
-------------
Released 2022-04-28
- Use verbose form of ``typing.Callable`` for ``command`` and
``group``. :issue:`2255`
- Show error when attempting to create an option with
``multiple=True, is_flag=True``. Use ``count`` instead.
:issue:`2246`
```
### 8.1.2
```
-------------
Released 2022-03-31
- Fix error message for readable path check that was mixed up with the
executable check. :pr:`2236`
- Restore parameter order for ``Path``, placing the ``executable``
parameter at the end. It is recommended to use keyword arguments
instead of positional arguments. :issue:`2235`
```
### 8.1.1
```
-------------
Released 2022-03-30
- Fix an issue with decorator typing that caused type checking to
report that a command was not callable. :issue:`2227`
```
### 8.1.0
```
-------------
Released 2022-03-28
- Drop support for Python 3.6. :pr:`2129`
- Remove previously deprecated code. :pr:`2130`
- ``Group.resultcallback`` is renamed to ``result_callback``.
- ``autocompletion`` parameter to ``Command`` is renamed to
``shell_complete``.
- ``get_terminal_size`` is removed, use
``shutil.get_terminal_size`` instead.
- ``get_os_args`` is removed, use ``sys.argv[1:]`` instead.
- Rely on :pep:`538` and :pep:`540` to handle selecting UTF-8 encoding
instead of ASCII. Click's locale encoding detection is removed.
:issue:`2198`
- Single options boolean flags with ``show_default=True`` only show
the default if it is ``True``. :issue:`1971`
- The ``command`` and ``group`` decorators can be applied with or
without parentheses. :issue:`1359`
- The ``Path`` type can check whether the target is executable.
:issue:`1961`
- ``Command.show_default`` overrides ``Context.show_default``, instead
of the other way around. :issue:`1963`
- Parameter decorators and ``group`` handles ``cls=None`` the same as
not passing ``cls``. ``option`` handles ``help=None`` the same as
not passing ``help``. :issue:`1959`
- A flag option with ``required=True`` requires that the flag is
passed instead of choosing the implicit default value. :issue:`1978`
- Indentation in help text passed to ``Option`` and ``Command`` is
cleaned the same as using the ``option`` and ``command``
decorators does. A command's ``epilog`` and ``short_help`` are also
processed. :issue:`1985`
- Store unprocessed ``Command.help``, ``epilog`` and ``short_help``
strings. Processing is only done when formatting help text for
output. :issue:`2149`
- Allow empty str input for ``prompt()`` when
``confirmation_prompt=True`` and ``default=""``. :issue:`2157`
- Windows glob pattern expansion doesn't fail if a value is an invalid
pattern. :issue:`2195`
- It's possible to pass a list of ``params`` to ``command``. Any
params defined with decorators are appended to the passed params.
:issue:`2131`.
- ``command`` decorator is annotated as returning the correct type if
a ``cls`` argument is used. :issue:`2211`
- A ``Group`` with ``invoke_without_command=True`` and ``chain=False``
will invoke its result callback with the group function's return
value. :issue:`2124`
- ``to_info_dict`` will not fail if a ``ParamType`` doesn't define a
``name``. :issue:`2168`
- Shell completion prioritizes option values with option prefixes over
new options. :issue:`2040`
- Options that get an environment variable value using
``autoenvvar_prefix`` treat an empty value as ``None``, consistent
with a direct ``envvar``. :issue:`2146`
```
### 8.0.4
```
-------------
Released 2022-02-18
- ``open_file`` recognizes ``Path("-")`` as a standard stream, the
same as the string ``"-"``. :issue:`2106`
- The ``option`` and ``argument`` decorators preserve the type
annotation of the decorated function. :pr:`2155`
- A callable default value can customize its help text by overriding
``__str__`` instead of always showing ``(dynamic)``. :issue:`2099`
- Fix a typo in the Bash completion script that affected file and
directory completion. If this script was generated by a previous
version, it should be regenerated. :issue:`2163`
- Fix typing for ``echo`` and ``secho`` file argument.
:issue:`2174, 2185`
```
### 8.0.3
```
-------------
Released 2021-10-10
- Fix issue with ``Path(resolve_path=True)`` type creating invalid
paths. :issue:`2088`
- Importing ``readline`` does not cause the ``confirm()`` prompt to
disappear when pressing backspace. :issue:`2092`
- Any default values injected by ``invoke()`` are cast to the
corresponding parameter's type. :issue:`2089, 2090`
```
### 8.0.2
```
-------------
Released 2021-10-08
- ``is_bool_flag`` is not set to ``True`` if ``is_flag`` is ``False``.
:issue:`1925`
- Bash version detection is locale independent. :issue:`1940`
- Empty ``default`` value is not shown for ``multiple=True``.
:issue:`1969`
- Fix shell completion for arguments that start with a forward slash
such as absolute file paths. :issue:`1929`
- ``Path`` type with ``resolve_path=True`` resolves relative symlinks
to be relative to the containing directory. :issue:`1921`
- Completion does not skip Python's resource cleanup when exiting,
avoiding some unexpected warning output. :issue:`1738, 2017`
- Fix type annotation for ``type`` argument in ``prompt`` function.
:issue:`2062`
- Fix overline and italic styles, which were incorrectly added when
adding underline. :pr:`2058`
- An option with ``count=True`` will not show "[x>=0]" in help text.
:issue:`2072`
- Default values are not cast to the parameter type twice during
processing. :issue:`2085`
- Options with ``multiple`` and ``flag_value`` use the flag value
instead of leaving an internal placeholder. :issue:`2001`
```
### 8.0.1
```
-------------
Released 2021-05-19
- Mark top-level names as exported so type checking understand imports
in user projects. :issue:`1879`
- Annotate ``Context.obj`` as ``Any`` so type checking allows all
operations on the arbitrary object. :issue:`1885`
- Fix some types that weren't available in Python 3.6.0. :issue:`1882`
- Fix type checking for iterating over ``ProgressBar`` object.
:issue:`1892`
- The ``importlib_metadata`` backport package is installed on Python <
3.8. :issue:`1889`
- Arguments with ``nargs=-1`` only use env var value if no command
line values are given. :issue:`1903`
- Flag options guess their type from ``flag_value`` if given, like
regular options do from ``default``. :issue:`1886`
- Added documentation that custom parameter types may be passed
already valid values in addition to strings. :issue:`1898`
- Resolving commands returns the name that was given, not
``command.name``, fixing an unintended change to help text and
``default_map`` lookups. When using patterns like ``AliasedGroup``,
override ``resolve_command`` to change the name that is returned if
needed. :issue:`1895`
- If a default value is invalid, it does not prevent showing help
text. :issue:`1889`
- Pass ``windows_expand_args=False`` when calling the main command to
disable pattern expansion on Windows. There is no way to escape
patterns in CMD, so if the program needs to pass them on as-is then
expansion must be disabled. :issue:`1901`
```
### 8.0.0
```
-------------
Released 2021-05-11
- Drop support for Python 2 and 3.5.
- Colorama is always installed on Windows in order to provide style
and color support. :pr:`1784`
- Adds a repr to Command, showing the command name for friendlier
debugging. :issue:`1267`, :pr:`1295`
- Add support for distinguishing the source of a command line
parameter. :issue:`1264`, :pr:`1329`
- Add an optional parameter to ``ProgressBar.update`` to set the
``current_item``. :issue:`1226`, :pr:`1332`
- ``version_option`` uses ``importlib.metadata`` (or the
``importlib_metadata`` backport) instead of ``pkg_resources``. The
version is detected based on the package name, not the entry point
name. The Python package name must match the installed package
name, or be passed with ``package_name=``. :issue:`1582`
- If validation fails for a prompt with ``hide_input=True``, the value
is not shown in the error message. :issue:`1460`
- An ``IntRange`` or ``FloatRange`` option shows the accepted range in
its help text. :issue:`1525`, :pr:`1303`
- ``IntRange`` and ``FloatRange`` bounds can be open (``<``) instead
of closed (``<=``) by setting ``min_open`` and ``max_open``. Error
messages have changed to reflect this. :issue:`1100`
- An option defined with duplicate flag names (``"--foo/--foo"``)
raises a ``ValueError``. :issue:`1465`
- ``echo()`` will not fail when using pytest's ``capsys`` fixture on
Windows. :issue:`1590`
- Resolving commands returns the canonical command name instead of the
matched name. This makes behavior such as help text and
``Context.invoked_subcommand`` consistent when using patterns like
``AliasedGroup``. :issue:`1422`
- The ``BOOL`` type accepts the values "on" and "off". :issue:`1629`
- A ``Group`` with ``invoke_without_command=True`` will always invoke
its result callback. :issue:`1178`
- ``nargs == -1`` and ``nargs > 1`` is parsed and validated for
values from environment variables and defaults. :issue:`729`
- Detect the program name when executing a module or package with
``python -m name``. :issue:`1603`
- Include required parent arguments in help synopsis of subcommands.
:issue:`1475`
- Help for boolean flags with ``show_default=True`` shows the flag
name instead of ``True`` or ``False``. :issue:`1538`
- Non-string objects passed to ``style()`` and ``secho()`` will be
converted to string. :pr:`1146`
- ``edit(require_save=True)`` will detect saves for editors that exit
very fast on filesystems with 1 second resolution. :pr:`1050`
- New class attributes make it easier to use custom core objects
throughout an entire application. :pr:`938`
- ``Command.context_class`` controls the context created when
running the command.
- ``Context.invoke`` creates new contexts of the same type, so a
custom type will persist to invoked subcommands.
- ``Context.formatter_class`` controls the formatter used to
generate help and usage.
- ``Group.command_class`` changes the default type for
subcommands with ``group.command()``.
- ``Group.group_class`` changes the default type for subgroups
with ``group.group()``. Setting it to ``type`` will create
subgroups of the same type as the group itself.
- Core objects use ``super()`` consistently for better support of
subclassing.
- Use ``Context.with_resource()`` to manage resources that would
normally be used in a ``with`` statement, allowing them to be used
across subcommands and callbacks, then cleaned up when the context
ends. :pr:`1191`
- The result object returned by the test runner's ``invoke()`` method
has a ``return_value`` attribute with the value returned by the
invoked command. :pr:`1312`
- Required arguments with the ``Choice`` type show the choices in
curly braces to indicate that one is required (``{a|b|c}``).
:issue:`1272`
- If only a name is passed to ``option()``, Click suggests renaming it
to ``--name``. :pr:`1355`
- A context's ``show_default`` parameter defaults to the value from
the parent context. :issue:`1565`
- ``click.style()`` can output 256 and RGB color codes. Most modern
terminals support these codes. :pr:`1429`
- When using ``CliRunner.invoke()``, the replaced ``stdin`` file has
``name`` and ``mode`` attributes. This lets ``File`` options with
the ``-`` value match non-testing behavior. :issue:`1064`
- When creating a ``Group``, allow passing a list of commands instead
of a dict. :issue:`1339`
- When a long option name isn't valid, use ``difflib`` to make better
suggestions for possible corrections. :issue:`1446`
- Core objects have a ``to_info_dict()`` method. This gathers
information about the object's structure that could be useful for a
tool generating user-facing documentation. To get the structure of
an entire CLI, use ``Context(cli).to_info_dict()``. :issue:`461`
- Redesign the shell completion system. :issue:`1484`, :pr:`1622`
- Support Bash >= 4.4, Zsh, and Fish, with the ability for
extensions to add support for other shells.
- Allow commands, groups, parameters, and types to override their
completions suggestions.
- Groups complete the names commands were registered with, which
can differ from the name they were created with.
- The ``autocompletion`` parameter for options and arguments is
renamed to ``shell_complete``. The function must take
``ctx, param, incomplete``, must do matching rather than return
all values, and must return a list of strings or a list of
``CompletionItem``. The old name and behavior is deprecated and
will be removed in 8.1.
- The env var values used to start completion have changed order.
The shell now comes first, such as ``{shell}_source`` rather
than ``source_{shell}``, and is always required.
- Completion correctly parses command line strings with incomplete
quoting or escape sequences. :issue:`1708`
- Extra context settings (``obj=...``, etc.) are passed on to the
completion system. :issue:`942`
- Include ``--help`` option in completion. :pr:`1504`
- ``ParameterSource`` is an ``enum.Enum`` subclass. :issue:`1530`
- Boolean and UUID types strip surrounding space before converting.
:issue:`1605`
- Adjusted error message from parameter type validation to be more
consistent. Quotes are used to distinguish the invalid value.
:issue:`1605`
- The default value for a parameter with ``nargs`` > 1 and
``multiple=True`` must be a list of tuples. :issue:`1649`
- When getting the value for a parameter, the default is tried in the
same section as other sources to ensure consistent processing.
:issue:`1649`
- All parameter types accept a value that is already the correct type.
:issue:`1649`
- For shell completion, an argument is considered incomplete if its
value did not come from the command line args. :issue:`1649`
- Added ``ParameterSource.PROMPT`` to track parameter values that were
prompted for. :issue:`1649`
- Options with ``nargs`` > 1 no longer raise an error if a default is
not given. Parameters with ``nargs`` > 1 default to ``None``, and
parameters with ``multiple=True`` or ``nargs=-1`` default to an
empty tuple. :issue:`472`
- Handle empty env vars as though the option were not passed. This
extends the change introduced in 7.1 to be consistent in more cases.
:issue:`1285`
- ``Parameter.get_default()`` checks ``Context.default_map`` to
handle overrides consistently in help text, ``invoke()``, and
prompts. :issue:`1548`
- Add ``prompt_required`` param to ``Option``. When set to ``False``,
the user will only be prompted for an input if no value was passed.
:issue:`736`
- Providing the value to an option can be made optional through
``is_flag=False``, and the value can instead be prompted for or
passed in as a default value.
:issue:`549, 736, 764, 921, 1015, 1618`
- Fix formatting when ``Command.options_metavar`` is empty. :pr:`1551`
- Revert adding space between option help text that wraps.
:issue:`1831`
- The default value passed to ``prompt`` will be cast to the correct
type like an input value would be. :pr:`1517`
- Automatically generated short help messages will stop at the first
ending of a phrase or double linebreak. :issue:`1082`
- Skip progress bar render steps for efficiency with very fast
iterators by setting ``update_min_steps``. :issue:`676`
- Respect ``case_sensitive=False`` when doing shell completion for
``Choice`` :issue:`1692`
- Use ``mkstemp()`` instead of ``mktemp()`` in pager implementation.
:issue:`1752`
- If ``Option.show_default`` is a string, it is displayed even if
``default`` is ``None``. :issue:`1732`
- ``click.get_terminal_size()`` is deprecated and will be removed in
8.1. Use :func:`shutil.get_terminal_size` instead. :issue:`1736`
- Control the location of the temporary directory created by
``CLIRunner.isolated_filesystem`` by passing ``temp_dir``. A custom
directory will not be removed automatically. :issue:`395`
- ``click.confirm()`` will prompt until input is given if called with
``default=None``. :issue:`1381`
- Option prompts validate the value with the option's callback in
addition to its type. :issue:`457`
- ``confirmation_prompt`` can be set to a custom string. :issue:`723`
- Allow styled output in Jupyter on Windows. :issue:`1271`
- ``style()`` supports the ``strikethrough``, ``italic``, and
``overline`` styles. :issue:`805, 1821`
- Multiline marker is removed from short help text. :issue:`1597`
- Restore progress bar behavior of echoing only the label if the file
is not a TTY. :issue:`1138`
- Progress bar output is shown even if execution time is less than 0.5
seconds. :issue:`1648`
- Progress bar ``item_show_func`` shows the current item, not the
previous item. :issue:`1353`
- The ``Path`` param type can be passed ``path_type=pathlib.Path`` to
return a path object instead of a string. :issue:`405`
- ``TypeError`` is raised when parameter with ``multiple=True`` or
``nargs > 1`` has non-iterable default. :issue:`1749`
- Add a ``pass_meta_key`` decorator for passing a key from
``Context.meta``. This is useful for extensions using ``meta`` to
store information. :issue:`1739`
- ``Path`` ``resolve_path`` resolves symlinks on Windows Python < 3.8.
:issue:`1813`
- Command deprecation notice appears at the start of the help text, as
well as in the short help. The notice is not in all caps.
:issue:`1791`
- When taking arguments from ``sys.argv`` on Windows, glob patterns,
user dir, and env vars are expanded. :issue:`1096`
- Marked messages shown by the CLI with ``gettext()`` to allow
applications to translate Click's built-in strings. :issue:`303`
- Writing invalid characters to ``stderr`` when using the test runner
does not raise a ``UnicodeEncodeError``. :issue:`848`
- Fix an issue where ``readline`` would clear the entire ``prompt()``
line instead of only the input when pressing backspace. :issue:`665`
- Add all kwargs passed to ``Context.invoke()`` to ``ctx.params``.
Fixes an inconsistency when nesting ``Context.forward()`` calls.
:issue:`1568`
- The ``MultiCommand.resultcallback`` decorator is renamed to
``result_callback``. The old name is deprecated. :issue:`1160`
- Fix issues with ``CliRunner`` output when using ``echo_stdin=True``.
:issue:`1101`
- Fix a bug of ``click.utils.make_default_short_help`` for which the
returned string could be as long as ``max_width + 3``. :issue:`1849`
- When defining a parameter, ``default`` is validated with
``multiple`` and ``nargs``. More validation is done for values being
processed as well. :issue:`1806`
- ``HelpFormatter.write_text`` uses the full line width when wrapping
text. :issue:`1871`
```
Links
- PyPI: https://pypi.org/project/click
- Changelog: https://pyup.io/changelogs/click/
- Homepage: https://palletsprojects.com/p/click/
Changelog
### 0.4.6
```
* https://github.com/tartley/colorama/pull/139 Add alternative to 'init()',
called 'just_fix_windows_console'. This fixes many longstanding problems
with 'init', such as working incorrectly on modern Windows terminals, and
wonkiness when init gets called multiple times. The intention is that it
just makes all Windows terminals treat ANSI the same way as other terminals
do. Many thanks the njsmith for fixing our messes.
* https://github.com/tartley/colorama/pull/352 Support Windows 10's ANSI/VT
console. This didn't exist when Colorama was created, and avoiding us
causing havok there is long overdue. Thanks to segeviner for the initial
approach, and to njsmith for getting it merged.
* https://github.com/tartley/colorama/pull/338 Internal overhaul of package
metadata declaration, which abolishes our use of the now heavily
discouraged setuptools (and hence setup.py, setup.cfg and MANIFEST.in), in
favor of hatchling (and hence pyproject.toml), generously contributed by
ofek (author of hatchling). This includes dropping support Python3.5 and
3.6, which are EOL, and were already dropped from setuptools, so this
should not affect our users.
* https://github.com/tartley/colorama/pull/353 Attention to detail award to
LqdBcnAtWork for a spelling fix in demo06
```
### 0.4.5
```
* Catch a racy ValueError that could occur on exit.
* Create README-hacking.md, for Colorama contributors.
* Tweak some README unicode characters that don't render correctly on PyPI.
* Fix some tests that were failing on some operating systems.
* Add support for Python 3.9.
* Add support for PyPy3.
* Add support for pickling with the ``dill`` module.
```
### 0.4.4
```
* Re-org of README, to put the most insteresting parts near the top.
* Added Linux makefile targets and Windows powershell scripts to automate
bootstrapping a development environment, and automate the process of
testing wheels before they are uploaded to PyPI.
* Use stdlib unittest.mock where available
* Travis CI now also builds on arm64
* Demo06 demonstrates existing cursor positioning feature
* Fix OSC regex & handling to prevent hang or crash
* Document enterprise support by Tidelift
```
Links
- PyPI: https://pypi.org/project/colorama
- Changelog: https://pyup.io/changelogs/colorama/
Changelog
### 7.2.5
```
--------------------------
- Fix: ``html_report()`` could fail with an AttributeError on ``isatty`` if run
in an unusual environment where sys.stdout had been replaced. This is now
fixed.
.. _changes_7-2-4:
```
### 7.2.4
```
--------------------------
PyCon 2023 sprint fixes!
- Fix: with ``relative_files = true``, specifying a specific file to include or
omit wouldn't work correctly (`issue 1604`_). This is now fixed, with
testing help by `Marc Gibbons <pull 1608_>`_.
- Fix: the XML report would have an incorrect ``<source>`` element when using
relative files and the source option ended with a slash (`issue 1541`_).
This is now fixed, thanks to `Kevin Brown-Silva <pull 1608_>`_.
- When the HTML report location is printed to the terminal, it's now a
terminal-compatible URL, so that you can click the location to open the HTML
file in your browser. Finishes `issue 1523`_ thanks to `Ricardo Newbery
<pull 1613_>`_.
- Docs: a new :ref:`Migrating page <migrating>` with details about how to
migrate between major versions of coverage.py. It currently covers the
wildcard changes in 7.x. Thanks, `Brian Grohe <pull 1610_>`_.
.. _issue 1523: https://github.com/nedbat/coveragepy/issues/1523
.. _issue 1541: https://github.com/nedbat/coveragepy/issues/1541
.. _issue 1604: https://github.com/nedbat/coveragepy/issues/1604
.. _pull 1608: https://github.com/nedbat/coveragepy/pull/1608
.. _pull 1609: https://github.com/nedbat/coveragepy/pull/1609
.. _pull 1610: https://github.com/nedbat/coveragepy/pull/1610
.. _pull 1613: https://github.com/nedbat/coveragepy/pull/1613
.. _changes_7-2-3:
```
### 7.2.3
```
--------------------------
- Fix: the :ref:`config_run_sigterm` setting was meant to capture data if a
process was terminated with a SIGTERM signal, but it didn't always. This was
fixed thanks to `Lewis Gaul <pull 1600_>`_, closing `issue 1599`_.
- Performance: HTML reports with context information are now much more compact.
File sizes are typically as small as one-third the previous size, but can be
dramatically smaller. This closes `issue 1584`_ thanks to `Oleh Krehel
<pull 1587_>`_.
- Development dependencies no longer use hashed pins, closing `issue 1592`_.
.. _issue 1584: https://github.com/nedbat/coveragepy/issues/1584
.. _pull 1587: https://github.com/nedbat/coveragepy/pull/1587
.. _issue 1592: https://github.com/nedbat/coveragepy/issues/1592
.. _issue 1599: https://github.com/nedbat/coveragepy/issues/1599
.. _pull 1600: https://github.com/nedbat/coveragepy/pull/1600
.. _changes_7-2-2:
```
### 7.2.2
```
--------------------------
- Fix: if a virtualenv was created inside a source directory, and a sourced
package was installed inside the virtualenv, then all of the third-party
packages inside the virtualenv would be measured. This was incorrect, but
has now been fixed: only the specified packages will be measured, thanks to
`Manuel Jacob <pull 1560_>`_.
- Fix: the ``coverage lcov`` command could create a .lcov file with incorrect
LF (lines found) and LH (lines hit) totals. This is now fixed, thanks to
`Ian Moore <pull 1583_>`_.
- Fix: the ``coverage xml`` command on Windows could create a .xml file with
duplicate ``<package>`` elements. This is now fixed, thanks to `Benjamin
Parzella <pull 1574_>`_, closing `issue 1573`_.
.. _pull 1560: https://github.com/nedbat/coveragepy/pull/1560
.. _issue 1573: https://github.com/nedbat/coveragepy/issues/1573
.. _pull 1574: https://github.com/nedbat/coveragepy/pull/1574
.. _pull 1583: https://github.com/nedbat/coveragepy/pull/1583
.. _changes_7-2-1:
```
### 7.2.1
```
--------------------------
- Fix: the PyPI page had broken links to documentation pages, but no longer
does, closing `issue 1566`_.
- Fix: public members of the coverage module are now properly indicated so that
mypy will find them, fixing `issue 1564`_.
.. _issue 1564: https://github.com/nedbat/coveragepy/issues/1564
.. _issue 1566: https://github.com/nedbat/coveragepy/issues/1566
.. _changes_7-2-0:
```
### 7.2.0
```
--------------------------
- Added a new setting ``[report] exclude_also`` to let you add more exclusions
without overwriting the defaults. Thanks, `Alpha Chen <pull 1557_>`_,
closing `issue 1391`_.
- Added
Update alembic from 1.4.2 to 1.10.4.
The bot wasn't able to find a changelog for this release. Got an idea?
Links
- PyPI: https://pypi.org/project/alembic - Homepage: https://alembic.sqlalchemy.org - Docs: https://pythonhosted.org/alembic/Update amqp from 2.5.2 to 5.1.1.
Changelog
### 5.1.1 ``` ===== :release-date: 2022-03-06 12:45 P.M. UTC+6:00 :release-by: Asif Saif Uddin - Use AF_UNSPEC for name resolution (389). .. _version-5.1.0: ``` ### 5.1.0 ``` ===== :release-date: 2022-03-06 10:05 A.M. UTC+6:00 :release-by: Asif Saif Uddin - Improve performance of _get_free_channel_id, fix channel max bug (385). - Document memoryview usage, minor frame_writer.write_frame refactor (384). - Start dropping python 3.6 (387). - Added experimental __slots__ to some classes (368) - Relaxed vine version for upcoming release. - Upgraded topytest 7 (388). .. _version-5.0.9: ``` ### 5.0.9 ``` ===== :release-date: 2021-12-20 11:00 A.M. UTC+6:00 :release-by: Asif Saif Uddin - Append to _used_channel_ids in _used_channel_ids .. _version-5.0.8: ``` ### 5.0.8 ``` ===== :release-date: 2021-12-19 11:15 A.M. UTC+6:00 :release-by: Asif Saif Uddin - Reduce memory usage of Connection (377) - Add additional error handling around code where an OSError may be raised on failed connections. Fixes (378) .. _version-5.0.7: ``` ### 5.0.7 ``` ===== :release-date: 2021-12-13 15:45 P.M. UTC+6:00 :release-by: Asif Saif Uddin - Remove dependency to case - Bugfix: not closing socket after server disconnect .. _version-5.0.6: ``` ### 5.0.6 ``` ===== :release-date: 2021-04-01 10:45 A.M. UTC+6:00 :release-by: Asif Saif Uddin - Change the order in which context.check_hostname and context.verify_mode get set in SSLTransport._wrap_socket_sni. Fixes bug introduced in 5.0.3 where setting context.verify_mode = ssl.CERT_NONE would raise "ValueError: Cannot set verify_mode to CERT_NONE when check_hostname is enabled." Setting context.check_hostname prior to setting context.verify_mode resolves the issue. - Remove TCP_USER_TIMEOUT option for Solaris (355) - Pass long_description to setup() (353) - Fix for tox-docker 2.0 - Moved to GitHub actions CI (359) .. _version-5.0.5: ``` ### 5.0.5 ``` ===== :release-date: 2021-01-28 4:30 P.M UTC+6:00 :release-by: Asif Saif Uddin - Removed mistakenly introduced code which was causing import errors .. _version-5.0.4: ``` ### 5.0.4 ``` ===== :release-date: 2021-01-28 2:30 P.M UTC+6:00 :release-by: Asif Saif Uddin - Add missing load_default_certs() call to fix a regression in v5.0.3 release. (350) .. _version-5.0.3: ``` ### 5.0.3 ``` ===== :release-date: 2021-01-19 9:00 P.M UTC+6:00 :release-by: Asif Saif Uddin - Change the default value of ssl_version to None. When not set, the proper value between ssl.PROTOCOL_TLS_CLIENT and ssl.PROTOCOL_TLS_SERVER will be selected based on the param server_side in order to create a TLS Context object with better defaults that fit the desired connection side. - Change the default value of cert_reqs to None. The default value of ctx.verify_mode is ssl.CERT_NONE, but when ssl.PROTOCOL_TLS_CLIENT is used, ctx.verify_mode defaults to ssl.CERT_REQUIRED. - Fix context.check_hostname logic. Checking the hostname depends on having support of the SNI TLS extension and being provided with a server_hostname value. Another important thing to mention is that enabling hostname checking automatically sets verify_mode from ssl.CERT_NONE to ssl.CERT_REQUIRED in the stdlib ssl and it cannot be set back to ssl.CERT_NONE as long as hostname checking is enabled. - Refactor the SNI tests to test one thing at a time and removing some tests that were being repeated over and over. .. _version-5.0.2: ``` ### 5.0.2 ``` ===== :release-date: 2020-11-08 6:50 P.M UTC+3:00 :release-by: Omer Katz - Whhels are no longer universal. Contributed by **Omer Katz** - Added debug representation to Connection and *Transport classes Contributed by **Matus Valo** - Reintroduce ca_certs and ciphers parameters of SSLTransport._wrap_socket_sni() This fixes issue introduced in commit: 53d6777 Contributed by **Matus Valo** - Fix infinite wait when using confirm_publish Contributed by **Omer Katz** & **RezaSi** .. _version-5.0.1: ``` ### 5.0.1 ``` ===== :release-date: 2020-09-06 6:10 P.M UTC+3:00 :release-by: Omer Katz - Require vine 5.0.0. Contributed by **Omer Katz** .. _version-5.0.0: ``` ### 5.0.0 ``` ===== :release-date: 2020-09-03 3:20 P.M UTC+3:00 :release-by: Omer Katz - Stop to use deprecated method ssl.wrap_socket. Contributed by **Hervé Beraud** .. _version-5.0.0b1: ``` ### 5.0.0b1 ``` ======= :release-date: 2020-09-01 6:20 P.M UTC+3:00 :release-by: Omer Katz - Dropped Python 3.5 support. Contributed by **Omer Katz** - Removed additional compatibility code. Contributed by **Omer Katz** .. _version-5.0.0a1: ``` ### 5.0.0a1 ``` ======= :release-date: 2019-04-01 4:30 P.M UTC+3:00 :release-by: Omer Katz - Dropped Python 2.x support. Contributed by **Omer Katz** - Dropped Python 3.4 support. Contributed by **Omer Katz** - Depend on :pypi:`vine` 5.0.0a1. Contributed by **Omer Katz** Code Cleanups & Improvements: - **Omer Katz** .. _version-2.6.0: ``` ### 2.6.1 ``` ===== :release-date: 2020-07-31 10.30 P.M UTC+6:00 :release-by: Asif Saif Uddin - Fix buffer overflow in frame_writer after frame_max is increased. `frame_writer` allocates a `bytearray` on initialization with a length based on the `connection.frame_max` value. If `connection.frame_max` is changed to a larger value, this causes an error like `pack_into requires a buffer of at least 408736 bytes`. .. _version-2.6.0: ``` ### 2.6.0 ``` ===== :release-date: 20-06-01 12.00 P.M UTC+6:00 :release-by: Asif Saif Uddin - Implement speedups in cython (311) - Updated some tests & code improvements - Separate logger for Connection.heartbeat_tick method - Cython generic content (315) - Improve documentation a_global parameter of basic_qos() method. - Fix saving partial read buffer on windows during socket timeout. (321) - Fix deserialization of long string field values that are not utf-8. - Added simple cythonization of abstract_channel.py - Speedups of serialization.py are more restrictive .. _version-2.5.2: ```Links
- PyPI: https://pypi.org/project/amqp - Changelog: https://pyup.io/changelogs/amqp/ - Repo: http://github.com/celery/py-amqpUpdate APScheduler from 3.6.3 to 3.10.1.
Changelog
### 3.9.1 ``` * Removed a leftover check for pytz ``localize()`` and ``normalize()`` methods ``` ### 3.9.0 ``` - Added support for PySide6 to the Qt scheduler - No longer enforce pytz time zones (support for others is experimental in the 3.x series) - Fixed compatibility with PyMongo 4 - Fixed pytz deprecation warnings - Fixed RuntimeError when shutting down the scheduler from a scheduled job ``` ### 3.8.1 ``` - Allowed the use of tzlocal v4.0+ in addition to v2.* ``` ### 3.8.0 ``` - Allowed passing through keyword arguments to the underlying stdlib executors in the thread/process pool executors (PR by Albert Xu) ``` ### 3.7.0 ``` - Dropped support for Python 3.4 - Added PySide2 support (PR by Abdulla Ibrahim) - Pinned ``tzlocal`` to a version compatible with pytz - Ensured that jitter is always non-negative to prevent triggers from firing more often than intended - Changed ``AsyncIOScheduler`` to obtain the event loop in ``start()`` instead of ``__init__()``, to prevent situations where the scheduler won't run because it's using a different event loop than then one currently running - Made it possible to create weak references to ``Job`` instances - Made the schedulers explicitly raise a descriptive ``TypeError`` when serialization is attempted - Fixed Zookeeper job store using backslashes instead of forward slashes for paths on Windows (PR by Laurel-rao) - Fixed deprecation warnings on the MongoDB job store and increased the minimum PyMongo version to 3.0 - Fixed ``BlockingScheduler`` and ``BackgroundScheduler`` shutdown hanging after the user has erroneously tried to start it twice - Fixed memory leak when coroutine jobs raise exceptions (due to reference cycles in tracebacks) - Fixed inability to schedule wrapped functions with extra arguments when the wrapped function cannot accept them but the wrapper can (original PR by Egor Malykh) - Fixed potential ``where`` clause error in the SQLAlchemy job store when a subclass uses more than one search condition - Fixed a problem where bound methods added as jobs via textual references were called with an unwanted extra ``self`` argument (PR by Pengjie Song) - Fixed ``BrokenPoolError`` in ``ProcessPoolExecutor`` so that it will automatically replace the broken pool with a fresh instance ```Links
- PyPI: https://pypi.org/project/apscheduler - Changelog: https://pyup.io/changelogs/apscheduler/ - Repo: https://github.com/agronholm/apscheduler - Docs: https://pythonhosted.org/APScheduler/Update Babel from 2.8.0 to 2.12.1.
Changelog
### 2.12.1 ``` -------------- Fixes ~~~~~ * Version 2.12.0 was missing the ``py.typed`` marker file. Thanks to Alex Waygood for the fix! :gh:`975` * The copyright year in all files was bumped to 2023. ``` ### 2.12.0 ``` -------------- Deprecations & breaking changes ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * Python 3.6 is no longer supported (:gh:`919`) - Aarni Koskela * The `get_next_timezone_transition` function is no more (:gh:`958`) - Aarni Koskela New features ~~~~~~~~~~~~ * CLDR: Babel now uses CLDR 42 (:gh:`951`) - Aarni Koskela * Dates: `pytz` is now optional; Babel will prefer it but will use `zoneinfo` when available. (:gh:`940`) - ds-cbo * General: Babel now ships type annotations, thanks to Jonah Lawrence's work in multiple PRs. * Locales: modifiers are now retained when parsing locales (:gh:`947`) - martin f. krafft * Messages: JavaScript template string expression extraction is now smarter. (:gh:`939`) - Johannes Wilm * Numbers: NaN and Infinity are now better supported (:gh:`955`) - Jonah Lawrence * Numbers: Short compact currency formats are now supported (:gh:`926`) - Jonah Lawrence * Numbers: There's now a `Format.compact_decimal` utility function. (:gh:`921`) - Jonah Lawrence Bugfixes ~~~~~~~~ * Dates: The cache for parsed datetime patterns is now bounded (:gh:`967`) - Aarni Koskela * Messages: Fuzzy candidate matching accuracy is improved (:gh:`970`) - Jean Abou Samra * Numbers: Compact singular formats and patterns with no numbers work correctly (:gh:`930`, :gh:`932`) - Jonah Lawrence, Jun Omae Improvements & cleanup ~~~~~~~~~~~~~~~~~~~~~~ * Dates: `babel.dates.UTC` is now an alias for `datetime.timezone.utc` (:gh:`957`) - Aarni Koskela * Dates: `babel.localtime` was slightly cleaned up. (:gh:`952`) - Aarni Koskela * Documentation: Documentation was improved by Maciej Olko, Jonah Lawrence, lilinjie, and Aarni Koskela. * Infrastructure: Babel is now being linted with pre-commit and ruff. - Aarni Koskela ``` ### 2.11.0 ``` -------------- Upcoming deprecation ~~~~~~~~~~~~~~~~~~~~ * This version, Babel 2.11, is the last version of Babel to support Python 3.6. Babel 2.12 will require Python 3.7 or newer. Improvements ~~~~~~~~~~~~ * Support for hex escapes in JavaScript string literals :gh:`877` - Przemyslaw Wegrzyn * Add support for formatting decimals in compact form :gh:`909` - Jonah Lawrence * Adapt parse_date to handle ISO dates in ASCII format :gh:`842` - Eric L. * Use `ast` instead of `eval` for Python string extraction :gh:`915` - Aarni Koskela * This also enables extraction from static f-strings. F-strings with expressions are silently ignored (but won't raise an error as they used to). Infrastructure ~~~~~~~~~~~~~~ * Tests: Use regular asserts and ``pytest.raises()`` :gh:`875` – Aarni Koskela * Wheels are now built in GitHub Actions :gh:`888` – Aarni Koskela * Small improvements to the CLDR downloader script :gh:`894` – Aarni Koskela * Remove antiquated `__nonzero__` methods :gh:`896` - Nikita Sobolev * Remove superfluous `__unicode__` declarations :gh:`905` - Lukas Juhrich * Mark package compatible with Python 3.11 :gh:`913` - Aarni Koskela * Quiesce pytest warnings :gh:`916` - Aarni Koskela Bugfixes ~~~~~~~~ * Use email.Message for pofile header parsing instead of the deprecated ``cgi.parse_header`` function. :gh:`876` – Aarni Koskela * Remove determining time zone via systemsetup on macOS :gh:`914` - Aarni Koskela Documentation ~~~~~~~~~~~~~ * Update Python versions in documentation :gh:`898` - Raphael Nestler * Align BSD-3 license with OSI template :gh:`912` - Lukas Kahwe Smith ``` ### 2.10.3 ``` -------------- This is a bugfix release for Babel 2.10.2, which was mistakenly packaged with outdated locale data. Thanks to Michał Górny for pointing this out and Jun Omae for verifying. This and future Babel PyPI packages will be built by a more automated process, which should make problems like this less likely to occur. ``` ### 2.10.2 ``` -------------- This is a bugfix release for Babel 2.10.1. * Fallback count="other" format in format_currency() (:gh:`872`) - Jun Omae * Fix get_period_id() with ``dayPeriodRule`` across 0:00 (:gh:`871`) - Jun Omae * Add support for ``b`` and ``B`` period symbols in time format (:gh:`869`) - Jun Omae * chore(docs/typo): Fixes a minor typo in a function comment (:gh:`864`) - Frank Harrison ``` ### 2.10.1 ``` -------------- This is a bugfix release for Babel 2.10.0. * Messages: Fix ``distutils`` import. Regressed in :gh:`843`. (:gh:`852`) - Nehal J Wani * The wheel file is no longer marked as universal, since Babel only supports Python 3. ``` ### 2.10.0 ``` -------------- Upcoming deprecation ~~~~~~~~~~~~~~~~~~~~ * The ``get_next_timezone_transition()`` function is marked deprecated in this version and will be removed likely as soon as Babel 2.11. No replacement for this function is planned; based on discussion in :gh:`716`, it's likely the function is not used in any real code. (:gh:`852`) - Aarni Koskela, Paul Ganssle Improvements ~~~~~~~~~~~~ * CLDR: Upgrade to CLDR 41.0. (:gh:`853`) - Aarni Koskela * The ``c`` and ``e`` plural form operands introduced in CLDR 40 are parsed, but otherwise unsupported. (:gh:`826`) * Non-nominative forms of units are currently ignored. * Messages: Implement ``--init-missing`` option for ``pybabel update`` (:gh:`785`) - ruro * Messages: For ``extract``, you can now replace the built-in ``.*`` / ``_*`` ignored directory patterns with ones of your own. (:gh:`832`) - Aarni Koskela, Kinshuk Dua * Messages: Add ``--check`` to verify if catalogs are up-to-date (:gh:`831`) - Krzysztof Jagiełło * Messages: Add ``--header-comment`` to override default header comment (:gh:`720`) - Mohamed Hafez Morsy, Aarni Koskela * Dates: ``parse_time`` now supports 12-hour clock, and is better at parsing partial times. (:gh:`834`) - Aarni Koskela, David Bauer, Arthur Jovart * Dates: ``parse_date`` and ``parse_time`` now raise ``ParseError``, a subclass of ``ValueError``, in certain cases. (:gh:`834`) - Aarni Koskela * Dates: ``parse_date`` and ``parse_time`` now accept the ``format`` parameter. (:gh:`834`) - Juliette Monsel, Aarni Koskela Infrastructure ~~~~~~~~~~~~~~ * The internal ``babel/_compat.py`` module is no more (:gh:`808`) - Hugo van Kemenade * Python 3.10 is officially supported (:gh:`809`) - Hugo van Kemenade * There's now a friendly GitHub issue template. (:gh:`800`) – Álvaro Mondéjar Rubio * Don't use the deprecated format_number function internally or in tests - Aarni Koskela * Add GitHub URL for PyPi (:gh:`846`) - Andrii Oriekhov * Python 3.12 compatibility: Prefer setuptools imports to distutils imports (:gh:`843`) - Aarni Koskela * Python 3.11 compatibility: Add deprecations to l*gettext variants (:gh:`835`) - Aarni Koskela * CI: Babel is now tested with PyPy 3.7. (:gh:`851`) - Aarni Koskela Bugfixes ~~~~~~~~ * Date formatting: Allow using ``other`` as fallback form (:gh:`827`) - Aarni Koskela * Locales: ``Locale.parse()`` normalizes variant tags to upper case (:gh:`829`) - Aarni Koskela * A typo in the plural format for Maltese is fixed. (:gh:`796`) - Lukas Winkler * Messages: Catalog date parsing is now timezone independent. (:gh:`701`) - rachele-collin * Messages: Fix duplicate locations when writing without lineno (:gh:`837`) - Sigurd Ljødal * Messages: Fix missing trailing semicolon in plural form headers (:gh:`848`) - farhan5900 * CLI: Fix output of ``--list-locales`` to not be a bytes repr (:gh:`845`) - Morgan Wahl Documentation ~~~~~~~~~~~~~ * Documentation is now correctly built again, and up to date (:gh:`830`) - Aarni Koskela ``` ### 2.9.1 ``` ------------- Bugfixes ~~~~~~~~ * The internal locale-data loading functions now validate the name of the locale file to be loaded and only allow files within Babel's data directory. Thank you to Chris Lyne of Tenable, Inc. for discovering the issue! ``` ### 2.9.0 ``` ------------- Upcoming version support changes ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * This version, Babel 2.9, is the last version of Babel to support Python 2.7, Python 3.4, and Python 3.5. Improvements ~~~~~~~~~~~~ * CLDR: Use CLDR 37 – Aarni Koskela (:gh:`734`) * Dates: Handle ZoneInfo objects in get_timezone_location, get_timezone_name - Alessio Bogon (:gh:`741`) * Numbers: Add group_separator feature in number formatting - Abdullah Javed Nesar (:gh:`726`) Bugfixes ~~~~~~~~ * Dates: Correct default Format().timedelta format to 'long' to mute deprecation warnings – Aarni Koskela * Import: Simplify iteration code in "import_cldr.py" – Felix Schwarz * Import: Stop using deprecated ElementTree methods "getchildren()" and "getiterator()" – Felix Schwarz * Messages: Fix unicode printing error on Python 2 without TTY. – Niklas Hambüchen * Messages: Introduce invariant that _invalid_pofile() takes unicode line. – Niklas Hambüchen * Tests: fix tests when using Python 3.9 – Felix Schwarz * Tests: Remove deprecated 'sudo: false' from Travis configuration – Jon Dufresne * Tests: Support Py.test 6.x – Aarni Koskela * Utilities: LazyProxy: Handle AttributeError in specified func – Nikiforov Konstantin (:gh:`724`) * Utilities: Replace usage of parser.suite with ast.parse – Miro Hrončok Documentation ~~~~~~~~~~~~~ * Update parse_number comments – Brad Martin (:gh:`708`) * Add __iter__ to Catalog documentation – CyanNani123 ``` ### 2.8.1 ``` ------------- This is solely a patch release to make running tests on Py.test 6+ possible. Bugfixes ~~~~~~~~ * Support Py.test 6 - Aarni Koskela (:gh:`747`, :gh:`750`, :gh:`752`) ```Links
- PyPI: https://pypi.org/project/babel - Changelog: https://pyup.io/changelogs/babel/ - Homepage: https://babel.pocoo.org/ - Docs: https://pythonhosted.org/Babel/Update beautifulsoup4 from 4.9.0 to 4.12.2.
Changelog
### 4.11.1 ``` This release was done to ensure that the unit tests are packaged along with the released source. There are no functionality changes in this release, but there are a few other packaging changes: * The Japanese and Korean translations of the documentation are included. * The changelog is now packaged as CHANGELOG, and the license file is packaged as LICENSE. NEWS.txt and COPYING.txt are still present, but may be removed in the future. * TODO.txt is no longer packaged, since a TODO is not relevant for released code. ``` ### 4.11.0 ``` * Ported unit tests to use pytest. * Added special string classes, RubyParenthesisString and RubyTextString, to make it possible to treat ruby text specially in get_text() calls. [bug=1941980] * It's now possible to customize the way output is indented by providing a value for the 'indent' argument to the Formatter constructor. The 'indent' argument works very similarly to the argument of the same name in the Python standard library's json.dump() function. [bug=1955497] * If the charset-normalizer Python module (https://pypi.org/project/charset-normalizer/) is installed, Beautiful Soup will use it to detect the character sets of incoming documents. This is also the module used by newer versions of the Requests library. For the sake of backwards compatibility, chardet and cchardet both take precedence if installed. [bug=1955346] * Added a workaround for an lxml bug (https://bugs.launchpad.net/lxml/+bug/1948551) that causes problems when parsing a Unicode string beginning with BYTE ORDER MARK. [bug=1947768] * Issue a warning when an HTML parser is used to parse a document that looks like XML but not XHTML. [bug=1939121] * Do a better job of keeping track of namespaces as an XML document is parsed, so that CSS selectors that use namespaces will do the right thing more often. [bug=1946243] * Some time ago, the misleadingly named "text" argument to find-type methods was renamed to the more accurate "string." But this supposed "renaming" didn't make it into important places like the method signatures or the docstrings. That's corrected in this version. "text" still works, but will give a DeprecationWarning. [bug=1947038] * Fixed a crash when pickling a BeautifulSoup object that has no tree builder. [bug=1934003] * Fixed a crash when overriding multi_valued_attributes and using the html5lib parser. [bug=1948488] * Standardized the wording of the MarkupResemblesLocatorWarning warnings to omit untrusted input and make the warnings less judgmental about what you ought to be doing. [bug=1955450] * Removed support for the iconv_codec library, which doesn't seem to exist anymore and was never put up on PyPI. (The closest replacement on PyPI, iconv_codecs, is GPL-licensed, so we can't use it--it's also quite old.) ``` ### 4.10.0 ``` * This is the first release of Beautiful Soup to only support Python 3. I dropped Python 2 support to maintain support for newer versions (58 and up) of setuptools. See: https://github.com/pypa/setuptools/issues/2769 [bug=1942919] * The behavior of methods like .get_text() and .strings now differs depending on the type of tag. The change is visible with HTML tags like <script>, <style>, and <template>. Starting in 4.9.0, methods like get_text() returned no results on such tags, because the contents of those tags are not considered 'text' within the document as a whole. But a user who calls script.get_text() is working from a different definition of 'text' than a user who calls div.get_text()--otherwise there would be no need to call script.get_text() at all. In 4.10.0, the contents of (e.g.) a <script> tag are considered 'text' during a get_text() call on the tag itself, but not considered 'text' during a get_text() call on the tag's parent. Because of this change, calling get_text() on each child of a tag may now return a different result than calling get_text() on the tag itself. That's because different tags now have different understandings of what counts as 'text'. [bug=1906226] [bug=1868861] * NavigableString and its subclasses now implement the get_text() method, as well as the properties .strings and .stripped_strings. These methods will either return the string itself, or nothing, so the only reason to use this is when iterating over a list of mixed Tag and NavigableString objects. [bug=1904309] * The 'html5' formatter now treats attributes whose values are the empty string as HTML boolean attributes. Previously (and in other formatters), an attribute value must be set as None to be treated as a boolean attribute. In a future release, I plan to also give this behavior to the 'html' formatter. Patch by Isaac Muse. [bug=1915424] * The 'replace_with()' method now takes a variable number of arguments, and can be used to replace a single element with a sequence of elements. Patch by Bill Chandos. [rev=605] * Corrected output when the namespace prefix associated with a namespaced attribute is the empty string, as opposed to None. [bug=1915583] * Performance improvement when processing tags that speeds up overall tree construction by 2%. Patch by Morotti. [bug=1899358] * Corrected the use of special string container classes in cases when a single tag may contain strings with different containers; such as the <template> tag, which may contain both TemplateString objects and Comment objects. [bug=1913406] * The html.parser tree builder can now handle named entities found in the HTML5 spec in much the same way that the html5lib tree builder does. Note that the lxml HTML tree builder doesn't handle named entities this way. [bug=1924908] * Added a second way to pass specify encodings to UnicodeDammit and EncodingDetector, based on the order of precedence defined in the HTML5 spec, starting at: https://html.spec.whatwg.org/multipage/parsing.html#parsing-with-a-known-character-encoding Encodings in 'known_definite_encodings' are tried first, then byte-order-mark sniffing is run, then encodings in 'user_encodings' are tried. The old argument, 'override_encodings', is now a deprecated alias for 'known_definite_encodings'. This changes the default behavior of the html.parser and lxml tree builders, in a way that may slightly improve encoding detection but will probably have no effect. [bug=1889014] * Improve the warning issued when a directory name (as opposed to the name of a regular file) is passed as markup into the BeautifulSoup constructor. [bug=1913628] ``` ### 4.9.3 ``` * Implemented a significant performance optimization to the process of searching the parse tree. Patch by Morotti. [bug=1898212] ``` ### 4.9.2 ``` * Fixed a bug that caused too many tags to be popped from the tag stack during tree building, when encountering a closing tag that had no matching opening tag. [bug=1880420] * Fixed a bug that inconsistently moved elements over when passing a Tag, rather than a list, into Tag.extend(). [bug=1885710] * Specify the soupsieve dependency in a way that complies with PEP 508. Patch by Mike Nerone. [bug=1893696] * Change the signatures for BeautifulSoup.insert_before and insert_after (which are not implemented) to match PageElement.insert_before and insert_after, quieting warnings in some IDEs. [bug=1897120] ``` ### 4.9.1 ``` * Added a keyword argument 'on_duplicate_attribute' to the BeautifulSoupHTMLParser constructor (used by the html.parser tree builder) which lets you customize the handling of markup that contains the same attribute more than once, as in: <a href="url1" href="url2"> [bug=1878209] * Added a distinct subclass, GuessedAtParserWarning, for the warning issued when BeautifulSoup is instantiated without a parser being specified. [bug=1873787] * Added a distinct subclass, MarkupResemblesLocatorWarning, for the warning issued when BeautifulSoup is instantiated with 'markup' that actually seems to be a URL or the path to a file on disk. [bug=1873787] * The new NavigableString subclasses (Stylesheet, Script, and TemplateString) can now be imported directly from the bs4 package. * If you encode a document with a Python-specific encoding like 'unicode_escape', that encoding is no longer mentioned in the final XML or HTML document. Instead, encoding information is omitted or left blank. [bug=1874955] * Fixed test failures when run against soupselect 2.0. Patch by Tomáš Chvátal. [bug=1872279] ```Links
- PyPI: https://pypi.org/project/beautifulsoup4 - Changelog: https://pyup.io/changelogs/beautifulsoup4/Update bleach from 3.3.0 to 6.0.0.
Changelog
### 5.0.1 ``` ------------------------------- **Bugs** * Add missing comma to tinycss2 require. Thank you, shadchin! * Add url parse tests based on wpt url tests. (688) * Support scheme-less urls if "https" is in allow list. (662) * Handle escaping ``<`` in edge cases where it doesn't start a tag. (544) * Fix reference warnings in docs. (660) * Correctly urlencode email address parts. Thank you, larseggert! (659) ``` ### 5.0.0 ``` ------------------------------- **Backwards incompatible changes** * ``clean`` and ``linkify`` now preserve the order of HTML attributes. Thank you, askoretskly! (566) * Drop support for Python 3.6. Thank you, hugovk! (629) * CSS sanitization in style tags is completely different now. If you're using Bleach ``clean`` to sanitize css in style tags, you'll need to update your code and you'll need to install the ``css`` extras:: pip install 'bleach[css]' See `the documentation on sanitizing CSS for how to do it <https://bleach.readthedocs.io/en/latest/clean.html#sanitizing-css>`_. (633) **Bug fixes** * Rework dev dependencies. We no longer have ``requirements-dev.in``/``requirements-dev.txt``. Instead, we're using ``dev`` extras. See `development docs <https://bleach.readthedocs.io/en/latest/dev.html>`_ for more details. (620) * Add newline when dropping block-level tags. Thank you, jvanasco! (369) ``` ### 4.1.0 ``` --------------------------------- **Features** * Python 3.9 support **Bug fixes** * Update sanitizer clean to use vendored 3.6.14 stdlib urllib.parse to fix test failures on Python 3.9. (536) ``` ### 4.0.0 ``` -------------------------------- **Backwards incompatible changes** * Drop support for unsupported Python versions <3.6. (520) **Security fixes** None **Features** * fix attribute name in the linkify docs (thanks CheesyFeet!) ``` ### 3.3.1 ``` ------------------------------- **Security fixes** None **Features** * add more tests for CVE-2021-23980 / GHSA-vv2x-vrpj-qqpq * bump python version to 3.8 for tox doc, vendorverify, and lint targets * update bug report template tag * update vendorverify script to detect and fail when extra files are vendored * update release process docs to check vendorverify passes locally **Bug fixes** * remove extra vendored django present in the v3.3.0 whl (595) * duplicate h1 header doc fix (thanks Nguyễn Gia Phong / McSinyx!) ```Links
- PyPI: https://pypi.org/project/bleach - Changelog: https://pyup.io/changelogs/bleach/ - Repo: https://github.com/mozilla/bleach - Docs: https://pythonhosted.org/bleach/Update blinker from 1.4 to 1.6.2.
Changelog
### 1.6.2 ``` ------------- Released 2023-04-12 - Type annotations are not evaluated at runtime. typing-extensions is not a runtime dependency. :pr:`94` ``` ### 1.6.1 ``` ------------- Released 2023-04-09 - Ensure that py.typed is present in the distributions (to enable other projects to use blinker's typing). - Require typing-extensions > 4.2 to ensure it includes ParamSpec. :issue:`90` ``` ### 1.6 ``` ----------- Released 2023-04-02 - Add a muted context manager to temporarily turn off a signal. :pr:`84` - Allow int senders (alongside existing string senders). :pr:`83` - Add a send_async method to the Signal to allow signals to send to coroutine receivers. :pr:`76` - Update and modernise the project structure to match that used by the pallets projects. :pr:`77` - Add an intial set of type hints for the project. ``` ### 1.5 ``` ----------- Released 2022-07-17 - Support Python >= 3.7 and PyPy. Python 2, Python < 3.7, and Jython may continue to work, but the next release will make incompatible changes. ```Links
- PyPI: https://pypi.org/project/blinker - Changelog: https://pyup.io/changelogs/blinker/Update cffi from 1.14.0 to 1.15.1.
The bot wasn't able to find a changelog for this release. Got an idea?
Links
- PyPI: https://pypi.org/project/cffi - Docs: http://cffi.readthedocs.orgUpdate cachetools from 4.1.0 to 5.3.0.
Changelog
### 5.2.1 ``` =================== - Add support for Python 3.11. - Correct version information in RTD documentation. - ``badges/shields``: Change to GitHub workflow badge routes. ``` ### 5.2.0 ``` =================== - Add ``cachetools.keys.methodkey()``. - Add ``cache_clear()`` function to decorators. - Add ``src`` directory to ``sys.path`` for Sphinx autodoc. - Modernize ``func`` wrappers. ``` ### 5.1.0 ``` =================== - Add cache decorator parameters as wrapper function attributes. ``` ### 5.0.0 ``` =================== - Require Python 3.7 or later (breaking change). - Remove deprecated submodules (breaking change). The ``cache``, ``fifo``, ``lfu``, ``lru``, ``mru``, ``rr`` and ``ttl`` submodules have been deleted. Therefore, statements like ``from cachetools.ttl import TTLCache`` will no longer work. Use ``from cachetools import TTLCache`` instead. - Pass ``self`` to ``cachedmethod`` key function (breaking change). The ``key`` function passed to the ``cachedmethod`` decorator is now called as ``key(self, *args, **kwargs)``. The default key function has been changed to ignore its first argument, so this should only affect applications using custom key functions with the ``cachedmethod`` decorator. - Change exact time of expiration in ``TTLCache`` (breaking change). ``TTLCache`` items now get expired if their expiration time is less than *or equal to* ``timer()``. For applications using the default ``timer()``, this should be barely noticable, but it may affect the use of custom timers with larger tick intervals. Note that this also implies that a ``TTLCache`` with ``ttl=0`` can no longer hold any items, since they will expire immediately. - Change ``Cache.__repr__()`` format (breaking change). String representations of cache instances now use a more compact and efficient format, e.g. ``LRUCache({1: 1, 2: 2}, maxsize=10, currsize=2)`` - Add TLRU cache implementation. - Documentation improvements. ``` ### 4.2.4 ``` =================== - Add submodule shims for backward compatibility. ``` ### 4.2.3 ``` =================== - Add documentation and tests for using ``TTLCache`` with ``datetime``. - Link to typeshed typing stubs. - Flatten package file hierarchy. ``` ### 4.2.2 ``` =================== - Update build environment. - Remove Python 2 remnants. - Format code with Black. ``` ### 4.2.1 ``` =================== - Handle ``__missing__()`` not storing cache items. - Clean up ``__missing__()`` example. ``` ### 4.2.0 ``` =================== - Add FIFO cache implementation. - Add MRU cache implementation. - Improve behavior of decorators in case of race conditions. - Improve documentation regarding mutability of caches values and use of key functions with decorators. - Officially support Python 3.9. ``` ### 4.1.1 ``` =================== - Improve ``popitem()`` exception context handling. - Replace ``float('inf')`` with ``math.inf``. - Improve "envkey" documentation example. ```Links
- PyPI: https://pypi.org/project/cachetools - Changelog: https://pyup.io/changelogs/cachetools/ - Repo: https://github.com/tkem/cachetools/Update click from 7.1.2 to 8.1.3.
Changelog
### 8.1.3 ``` ------------- Released 2022-04-28 - Use verbose form of ``typing.Callable`` for ``command`` and ``group``. :issue:`2255` - Show error when attempting to create an option with ``multiple=True, is_flag=True``. Use ``count`` instead. :issue:`2246` ``` ### 8.1.2 ``` ------------- Released 2022-03-31 - Fix error message for readable path check that was mixed up with the executable check. :pr:`2236` - Restore parameter order for ``Path``, placing the ``executable`` parameter at the end. It is recommended to use keyword arguments instead of positional arguments. :issue:`2235` ``` ### 8.1.1 ``` ------------- Released 2022-03-30 - Fix an issue with decorator typing that caused type checking to report that a command was not callable. :issue:`2227` ``` ### 8.1.0 ``` ------------- Released 2022-03-28 - Drop support for Python 3.6. :pr:`2129` - Remove previously deprecated code. :pr:`2130` - ``Group.resultcallback`` is renamed to ``result_callback``. - ``autocompletion`` parameter to ``Command`` is renamed to ``shell_complete``. - ``get_terminal_size`` is removed, use ``shutil.get_terminal_size`` instead. - ``get_os_args`` is removed, use ``sys.argv[1:]`` instead. - Rely on :pep:`538` and :pep:`540` to handle selecting UTF-8 encoding instead of ASCII. Click's locale encoding detection is removed. :issue:`2198` - Single options boolean flags with ``show_default=True`` only show the default if it is ``True``. :issue:`1971` - The ``command`` and ``group`` decorators can be applied with or without parentheses. :issue:`1359` - The ``Path`` type can check whether the target is executable. :issue:`1961` - ``Command.show_default`` overrides ``Context.show_default``, instead of the other way around. :issue:`1963` - Parameter decorators and ``group`` handles ``cls=None`` the same as not passing ``cls``. ``option`` handles ``help=None`` the same as not passing ``help``. :issue:`1959` - A flag option with ``required=True`` requires that the flag is passed instead of choosing the implicit default value. :issue:`1978` - Indentation in help text passed to ``Option`` and ``Command`` is cleaned the same as using the ``option`` and ``command`` decorators does. A command's ``epilog`` and ``short_help`` are also processed. :issue:`1985` - Store unprocessed ``Command.help``, ``epilog`` and ``short_help`` strings. Processing is only done when formatting help text for output. :issue:`2149` - Allow empty str input for ``prompt()`` when ``confirmation_prompt=True`` and ``default=""``. :issue:`2157` - Windows glob pattern expansion doesn't fail if a value is an invalid pattern. :issue:`2195` - It's possible to pass a list of ``params`` to ``command``. Any params defined with decorators are appended to the passed params. :issue:`2131`. - ``command`` decorator is annotated as returning the correct type if a ``cls`` argument is used. :issue:`2211` - A ``Group`` with ``invoke_without_command=True`` and ``chain=False`` will invoke its result callback with the group function's return value. :issue:`2124` - ``to_info_dict`` will not fail if a ``ParamType`` doesn't define a ``name``. :issue:`2168` - Shell completion prioritizes option values with option prefixes over new options. :issue:`2040` - Options that get an environment variable value using ``autoenvvar_prefix`` treat an empty value as ``None``, consistent with a direct ``envvar``. :issue:`2146` ``` ### 8.0.4 ``` ------------- Released 2022-02-18 - ``open_file`` recognizes ``Path("-")`` as a standard stream, the same as the string ``"-"``. :issue:`2106` - The ``option`` and ``argument`` decorators preserve the type annotation of the decorated function. :pr:`2155` - A callable default value can customize its help text by overriding ``__str__`` instead of always showing ``(dynamic)``. :issue:`2099` - Fix a typo in the Bash completion script that affected file and directory completion. If this script was generated by a previous version, it should be regenerated. :issue:`2163` - Fix typing for ``echo`` and ``secho`` file argument. :issue:`2174, 2185` ``` ### 8.0.3 ``` ------------- Released 2021-10-10 - Fix issue with ``Path(resolve_path=True)`` type creating invalid paths. :issue:`2088` - Importing ``readline`` does not cause the ``confirm()`` prompt to disappear when pressing backspace. :issue:`2092` - Any default values injected by ``invoke()`` are cast to the corresponding parameter's type. :issue:`2089, 2090` ``` ### 8.0.2 ``` ------------- Released 2021-10-08 - ``is_bool_flag`` is not set to ``True`` if ``is_flag`` is ``False``. :issue:`1925` - Bash version detection is locale independent. :issue:`1940` - Empty ``default`` value is not shown for ``multiple=True``. :issue:`1969` - Fix shell completion for arguments that start with a forward slash such as absolute file paths. :issue:`1929` - ``Path`` type with ``resolve_path=True`` resolves relative symlinks to be relative to the containing directory. :issue:`1921` - Completion does not skip Python's resource cleanup when exiting, avoiding some unexpected warning output. :issue:`1738, 2017` - Fix type annotation for ``type`` argument in ``prompt`` function. :issue:`2062` - Fix overline and italic styles, which were incorrectly added when adding underline. :pr:`2058` - An option with ``count=True`` will not show "[x>=0]" in help text. :issue:`2072` - Default values are not cast to the parameter type twice during processing. :issue:`2085` - Options with ``multiple`` and ``flag_value`` use the flag value instead of leaving an internal placeholder. :issue:`2001` ``` ### 8.0.1 ``` ------------- Released 2021-05-19 - Mark top-level names as exported so type checking understand imports in user projects. :issue:`1879` - Annotate ``Context.obj`` as ``Any`` so type checking allows all operations on the arbitrary object. :issue:`1885` - Fix some types that weren't available in Python 3.6.0. :issue:`1882` - Fix type checking for iterating over ``ProgressBar`` object. :issue:`1892` - The ``importlib_metadata`` backport package is installed on Python < 3.8. :issue:`1889` - Arguments with ``nargs=-1`` only use env var value if no command line values are given. :issue:`1903` - Flag options guess their type from ``flag_value`` if given, like regular options do from ``default``. :issue:`1886` - Added documentation that custom parameter types may be passed already valid values in addition to strings. :issue:`1898` - Resolving commands returns the name that was given, not ``command.name``, fixing an unintended change to help text and ``default_map`` lookups. When using patterns like ``AliasedGroup``, override ``resolve_command`` to change the name that is returned if needed. :issue:`1895` - If a default value is invalid, it does not prevent showing help text. :issue:`1889` - Pass ``windows_expand_args=False`` when calling the main command to disable pattern expansion on Windows. There is no way to escape patterns in CMD, so if the program needs to pass them on as-is then expansion must be disabled. :issue:`1901` ``` ### 8.0.0 ``` ------------- Released 2021-05-11 - Drop support for Python 2 and 3.5. - Colorama is always installed on Windows in order to provide style and color support. :pr:`1784` - Adds a repr to Command, showing the command name for friendlier debugging. :issue:`1267`, :pr:`1295` - Add support for distinguishing the source of a command line parameter. :issue:`1264`, :pr:`1329` - Add an optional parameter to ``ProgressBar.update`` to set the ``current_item``. :issue:`1226`, :pr:`1332` - ``version_option`` uses ``importlib.metadata`` (or the ``importlib_metadata`` backport) instead of ``pkg_resources``. The version is detected based on the package name, not the entry point name. The Python package name must match the installed package name, or be passed with ``package_name=``. :issue:`1582` - If validation fails for a prompt with ``hide_input=True``, the value is not shown in the error message. :issue:`1460` - An ``IntRange`` or ``FloatRange`` option shows the accepted range in its help text. :issue:`1525`, :pr:`1303` - ``IntRange`` and ``FloatRange`` bounds can be open (``<``) instead of closed (``<=``) by setting ``min_open`` and ``max_open``. Error messages have changed to reflect this. :issue:`1100` - An option defined with duplicate flag names (``"--foo/--foo"``) raises a ``ValueError``. :issue:`1465` - ``echo()`` will not fail when using pytest's ``capsys`` fixture on Windows. :issue:`1590` - Resolving commands returns the canonical command name instead of the matched name. This makes behavior such as help text and ``Context.invoked_subcommand`` consistent when using patterns like ``AliasedGroup``. :issue:`1422` - The ``BOOL`` type accepts the values "on" and "off". :issue:`1629` - A ``Group`` with ``invoke_without_command=True`` will always invoke its result callback. :issue:`1178` - ``nargs == -1`` and ``nargs > 1`` is parsed and validated for values from environment variables and defaults. :issue:`729` - Detect the program name when executing a module or package with ``python -m name``. :issue:`1603` - Include required parent arguments in help synopsis of subcommands. :issue:`1475` - Help for boolean flags with ``show_default=True`` shows the flag name instead of ``True`` or ``False``. :issue:`1538` - Non-string objects passed to ``style()`` and ``secho()`` will be converted to string. :pr:`1146` - ``edit(require_save=True)`` will detect saves for editors that exit very fast on filesystems with 1 second resolution. :pr:`1050` - New class attributes make it easier to use custom core objects throughout an entire application. :pr:`938` - ``Command.context_class`` controls the context created when running the command. - ``Context.invoke`` creates new contexts of the same type, so a custom type will persist to invoked subcommands. - ``Context.formatter_class`` controls the formatter used to generate help and usage. - ``Group.command_class`` changes the default type for subcommands with ``group.command()``. - ``Group.group_class`` changes the default type for subgroups with ``group.group()``. Setting it to ``type`` will create subgroups of the same type as the group itself. - Core objects use ``super()`` consistently for better support of subclassing. - Use ``Context.with_resource()`` to manage resources that would normally be used in a ``with`` statement, allowing them to be used across subcommands and callbacks, then cleaned up when the context ends. :pr:`1191` - The result object returned by the test runner's ``invoke()`` method has a ``return_value`` attribute with the value returned by the invoked command. :pr:`1312` - Required arguments with the ``Choice`` type show the choices in curly braces to indicate that one is required (``{a|b|c}``). :issue:`1272` - If only a name is passed to ``option()``, Click suggests renaming it to ``--name``. :pr:`1355` - A context's ``show_default`` parameter defaults to the value from the parent context. :issue:`1565` - ``click.style()`` can output 256 and RGB color codes. Most modern terminals support these codes. :pr:`1429` - When using ``CliRunner.invoke()``, the replaced ``stdin`` file has ``name`` and ``mode`` attributes. This lets ``File`` options with the ``-`` value match non-testing behavior. :issue:`1064` - When creating a ``Group``, allow passing a list of commands instead of a dict. :issue:`1339` - When a long option name isn't valid, use ``difflib`` to make better suggestions for possible corrections. :issue:`1446` - Core objects have a ``to_info_dict()`` method. This gathers information about the object's structure that could be useful for a tool generating user-facing documentation. To get the structure of an entire CLI, use ``Context(cli).to_info_dict()``. :issue:`461` - Redesign the shell completion system. :issue:`1484`, :pr:`1622` - Support Bash >= 4.4, Zsh, and Fish, with the ability for extensions to add support for other shells. - Allow commands, groups, parameters, and types to override their completions suggestions. - Groups complete the names commands were registered with, which can differ from the name they were created with. - The ``autocompletion`` parameter for options and arguments is renamed to ``shell_complete``. The function must take ``ctx, param, incomplete``, must do matching rather than return all values, and must return a list of strings or a list of ``CompletionItem``. The old name and behavior is deprecated and will be removed in 8.1. - The env var values used to start completion have changed order. The shell now comes first, such as ``{shell}_source`` rather than ``source_{shell}``, and is always required. - Completion correctly parses command line strings with incomplete quoting or escape sequences. :issue:`1708` - Extra context settings (``obj=...``, etc.) are passed on to the completion system. :issue:`942` - Include ``--help`` option in completion. :pr:`1504` - ``ParameterSource`` is an ``enum.Enum`` subclass. :issue:`1530` - Boolean and UUID types strip surrounding space before converting. :issue:`1605` - Adjusted error message from parameter type validation to be more consistent. Quotes are used to distinguish the invalid value. :issue:`1605` - The default value for a parameter with ``nargs`` > 1 and ``multiple=True`` must be a list of tuples. :issue:`1649` - When getting the value for a parameter, the default is tried in the same section as other sources to ensure consistent processing. :issue:`1649` - All parameter types accept a value that is already the correct type. :issue:`1649` - For shell completion, an argument is considered incomplete if its value did not come from the command line args. :issue:`1649` - Added ``ParameterSource.PROMPT`` to track parameter values that were prompted for. :issue:`1649` - Options with ``nargs`` > 1 no longer raise an error if a default is not given. Parameters with ``nargs`` > 1 default to ``None``, and parameters with ``multiple=True`` or ``nargs=-1`` default to an empty tuple. :issue:`472` - Handle empty env vars as though the option were not passed. This extends the change introduced in 7.1 to be consistent in more cases. :issue:`1285` - ``Parameter.get_default()`` checks ``Context.default_map`` to handle overrides consistently in help text, ``invoke()``, and prompts. :issue:`1548` - Add ``prompt_required`` param to ``Option``. When set to ``False``, the user will only be prompted for an input if no value was passed. :issue:`736` - Providing the value to an option can be made optional through ``is_flag=False``, and the value can instead be prompted for or passed in as a default value. :issue:`549, 736, 764, 921, 1015, 1618` - Fix formatting when ``Command.options_metavar`` is empty. :pr:`1551` - Revert adding space between option help text that wraps. :issue:`1831` - The default value passed to ``prompt`` will be cast to the correct type like an input value would be. :pr:`1517` - Automatically generated short help messages will stop at the first ending of a phrase or double linebreak. :issue:`1082` - Skip progress bar render steps for efficiency with very fast iterators by setting ``update_min_steps``. :issue:`676` - Respect ``case_sensitive=False`` when doing shell completion for ``Choice`` :issue:`1692` - Use ``mkstemp()`` instead of ``mktemp()`` in pager implementation. :issue:`1752` - If ``Option.show_default`` is a string, it is displayed even if ``default`` is ``None``. :issue:`1732` - ``click.get_terminal_size()`` is deprecated and will be removed in 8.1. Use :func:`shutil.get_terminal_size` instead. :issue:`1736` - Control the location of the temporary directory created by ``CLIRunner.isolated_filesystem`` by passing ``temp_dir``. A custom directory will not be removed automatically. :issue:`395` - ``click.confirm()`` will prompt until input is given if called with ``default=None``. :issue:`1381` - Option prompts validate the value with the option's callback in addition to its type. :issue:`457` - ``confirmation_prompt`` can be set to a custom string. :issue:`723` - Allow styled output in Jupyter on Windows. :issue:`1271` - ``style()`` supports the ``strikethrough``, ``italic``, and ``overline`` styles. :issue:`805, 1821` - Multiline marker is removed from short help text. :issue:`1597` - Restore progress bar behavior of echoing only the label if the file is not a TTY. :issue:`1138` - Progress bar output is shown even if execution time is less than 0.5 seconds. :issue:`1648` - Progress bar ``item_show_func`` shows the current item, not the previous item. :issue:`1353` - The ``Path`` param type can be passed ``path_type=pathlib.Path`` to return a path object instead of a string. :issue:`405` - ``TypeError`` is raised when parameter with ``multiple=True`` or ``nargs > 1`` has non-iterable default. :issue:`1749` - Add a ``pass_meta_key`` decorator for passing a key from ``Context.meta``. This is useful for extensions using ``meta`` to store information. :issue:`1739` - ``Path`` ``resolve_path`` resolves symlinks on Windows Python < 3.8. :issue:`1813` - Command deprecation notice appears at the start of the help text, as well as in the short help. The notice is not in all caps. :issue:`1791` - When taking arguments from ``sys.argv`` on Windows, glob patterns, user dir, and env vars are expanded. :issue:`1096` - Marked messages shown by the CLI with ``gettext()`` to allow applications to translate Click's built-in strings. :issue:`303` - Writing invalid characters to ``stderr`` when using the test runner does not raise a ``UnicodeEncodeError``. :issue:`848` - Fix an issue where ``readline`` would clear the entire ``prompt()`` line instead of only the input when pressing backspace. :issue:`665` - Add all kwargs passed to ``Context.invoke()`` to ``ctx.params``. Fixes an inconsistency when nesting ``Context.forward()`` calls. :issue:`1568` - The ``MultiCommand.resultcallback`` decorator is renamed to ``result_callback``. The old name is deprecated. :issue:`1160` - Fix issues with ``CliRunner`` output when using ``echo_stdin=True``. :issue:`1101` - Fix a bug of ``click.utils.make_default_short_help`` for which the returned string could be as long as ``max_width + 3``. :issue:`1849` - When defining a parameter, ``default`` is validated with ``multiple`` and ``nargs``. More validation is done for values being processed as well. :issue:`1806` - ``HelpFormatter.write_text`` uses the full line width when wrapping text. :issue:`1871` ```Links
- PyPI: https://pypi.org/project/click - Changelog: https://pyup.io/changelogs/click/ - Homepage: https://palletsprojects.com/p/click/Update colorama from 0.4.3 to 0.4.6.
Changelog
### 0.4.6 ``` * https://github.com/tartley/colorama/pull/139 Add alternative to 'init()', called 'just_fix_windows_console'. This fixes many longstanding problems with 'init', such as working incorrectly on modern Windows terminals, and wonkiness when init gets called multiple times. The intention is that it just makes all Windows terminals treat ANSI the same way as other terminals do. Many thanks the njsmith for fixing our messes. * https://github.com/tartley/colorama/pull/352 Support Windows 10's ANSI/VT console. This didn't exist when Colorama was created, and avoiding us causing havok there is long overdue. Thanks to segeviner for the initial approach, and to njsmith for getting it merged. * https://github.com/tartley/colorama/pull/338 Internal overhaul of package metadata declaration, which abolishes our use of the now heavily discouraged setuptools (and hence setup.py, setup.cfg and MANIFEST.in), in favor of hatchling (and hence pyproject.toml), generously contributed by ofek (author of hatchling). This includes dropping support Python3.5 and 3.6, which are EOL, and were already dropped from setuptools, so this should not affect our users. * https://github.com/tartley/colorama/pull/353 Attention to detail award to LqdBcnAtWork for a spelling fix in demo06 ``` ### 0.4.5 ``` * Catch a racy ValueError that could occur on exit. * Create README-hacking.md, for Colorama contributors. * Tweak some README unicode characters that don't render correctly on PyPI. * Fix some tests that were failing on some operating systems. * Add support for Python 3.9. * Add support for PyPy3. * Add support for pickling with the ``dill`` module. ``` ### 0.4.4 ``` * Re-org of README, to put the most insteresting parts near the top. * Added Linux makefile targets and Windows powershell scripts to automate bootstrapping a development environment, and automate the process of testing wheels before they are uploaded to PyPI. * Use stdlib unittest.mock where available * Travis CI now also builds on arm64 * Demo06 demonstrates existing cursor positioning feature * Fix OSC regex & handling to prevent hang or crash * Document enterprise support by Tidelift ```Links
- PyPI: https://pypi.org/project/colorama - Changelog: https://pyup.io/changelogs/colorama/Update coverage from 5.1 to 7.2.5.
Changelog
### 7.2.5 ``` -------------------------- - Fix: ``html_report()`` could fail with an AttributeError on ``isatty`` if run in an unusual environment where sys.stdout had been replaced. This is now fixed. .. _changes_7-2-4: ``` ### 7.2.4 ``` -------------------------- PyCon 2023 sprint fixes! - Fix: with ``relative_files = true``, specifying a specific file to include or omit wouldn't work correctly (`issue 1604`_). This is now fixed, with testing help by `Marc Gibbons <pull 1608_>`_. - Fix: the XML report would have an incorrect ``<source>`` element when using relative files and the source option ended with a slash (`issue 1541`_). This is now fixed, thanks to `Kevin Brown-Silva <pull 1608_>`_. - When the HTML report location is printed to the terminal, it's now a terminal-compatible URL, so that you can click the location to open the HTML file in your browser. Finishes `issue 1523`_ thanks to `Ricardo Newbery <pull 1613_>`_. - Docs: a new :ref:`Migrating page <migrating>` with details about how to migrate between major versions of coverage.py. It currently covers the wildcard changes in 7.x. Thanks, `Brian Grohe <pull 1610_>`_. .. _issue 1523: https://github.com/nedbat/coveragepy/issues/1523 .. _issue 1541: https://github.com/nedbat/coveragepy/issues/1541 .. _issue 1604: https://github.com/nedbat/coveragepy/issues/1604 .. _pull 1608: https://github.com/nedbat/coveragepy/pull/1608 .. _pull 1609: https://github.com/nedbat/coveragepy/pull/1609 .. _pull 1610: https://github.com/nedbat/coveragepy/pull/1610 .. _pull 1613: https://github.com/nedbat/coveragepy/pull/1613 .. _changes_7-2-3: ``` ### 7.2.3 ``` -------------------------- - Fix: the :ref:`config_run_sigterm` setting was meant to capture data if a process was terminated with a SIGTERM signal, but it didn't always. This was fixed thanks to `Lewis Gaul <pull 1600_>`_, closing `issue 1599`_. - Performance: HTML reports with context information are now much more compact. File sizes are typically as small as one-third the previous size, but can be dramatically smaller. This closes `issue 1584`_ thanks to `Oleh Krehel <pull 1587_>`_. - Development dependencies no longer use hashed pins, closing `issue 1592`_. .. _issue 1584: https://github.com/nedbat/coveragepy/issues/1584 .. _pull 1587: https://github.com/nedbat/coveragepy/pull/1587 .. _issue 1592: https://github.com/nedbat/coveragepy/issues/1592 .. _issue 1599: https://github.com/nedbat/coveragepy/issues/1599 .. _pull 1600: https://github.com/nedbat/coveragepy/pull/1600 .. _changes_7-2-2: ``` ### 7.2.2 ``` -------------------------- - Fix: if a virtualenv was created inside a source directory, and a sourced package was installed inside the virtualenv, then all of the third-party packages inside the virtualenv would be measured. This was incorrect, but has now been fixed: only the specified packages will be measured, thanks to `Manuel Jacob <pull 1560_>`_. - Fix: the ``coverage lcov`` command could create a .lcov file with incorrect LF (lines found) and LH (lines hit) totals. This is now fixed, thanks to `Ian Moore <pull 1583_>`_. - Fix: the ``coverage xml`` command on Windows could create a .xml file with duplicate ``<package>`` elements. This is now fixed, thanks to `Benjamin Parzella <pull 1574_>`_, closing `issue 1573`_. .. _pull 1560: https://github.com/nedbat/coveragepy/pull/1560 .. _issue 1573: https://github.com/nedbat/coveragepy/issues/1573 .. _pull 1574: https://github.com/nedbat/coveragepy/pull/1574 .. _pull 1583: https://github.com/nedbat/coveragepy/pull/1583 .. _changes_7-2-1: ``` ### 7.2.1 ``` -------------------------- - Fix: the PyPI page had broken links to documentation pages, but no longer does, closing `issue 1566`_. - Fix: public members of the coverage module are now properly indicated so that mypy will find them, fixing `issue 1564`_. .. _issue 1564: https://github.com/nedbat/coveragepy/issues/1564 .. _issue 1566: https://github.com/nedbat/coveragepy/issues/1566 .. _changes_7-2-0: ``` ### 7.2.0 ``` -------------------------- - Added a new setting ``[report] exclude_also`` to let you add more exclusions without overwriting the defaults. Thanks, `Alpha Chen <pull 1557_>`_, closing `issue 1391`_. - Added