Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bpo-45085: Remove the binhex module #28117

Merged
merged 1 commit into from
Sep 2, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
47 changes: 2 additions & 45 deletions Doc/library/binascii.rst
Original file line number Diff line number Diff line change
Expand Up @@ -8,14 +8,13 @@
.. index::
module: uu
module: base64
module: binhex

--------------

The :mod:`binascii` module contains a number of methods to convert between
binary and various ASCII-encoded binary representations. Normally, you will not
use these functions directly but use wrapper modules like :mod:`uu`,
:mod:`base64`, or :mod:`binhex` instead. The :mod:`binascii` module contains
use these functions directly but use wrapper modules like :mod:`uu` or
:mod:`base64` instead. The :mod:`binascii` module contains
low-level functions written in C for greater speed that are used by the
higher-level modules.

Expand Down Expand Up @@ -98,45 +97,6 @@ The :mod:`binascii` module defines the following functions:
stream.


.. function:: a2b_hqx(string)

Convert binhex4 formatted ASCII data to binary, without doing RLE-decompression.
The string should contain a complete number of binary bytes, or (in case of the
last portion of the binhex4 data) have the remaining bits zero.

.. deprecated:: 3.9


.. function:: rledecode_hqx(data)

Perform RLE-decompression on the data, as per the binhex4 standard. The
algorithm uses ``0x90`` after a byte as a repeat indicator, followed by a count.
A count of ``0`` specifies a byte value of ``0x90``. The routine returns the
decompressed data, unless data input data ends in an orphaned repeat indicator,
in which case the :exc:`Incomplete` exception is raised.

.. versionchanged:: 3.2
Accept only bytestring or bytearray objects as input.

.. deprecated:: 3.9


.. function:: rlecode_hqx(data)

Perform binhex4 style RLE-compression on *data* and return the result.

.. deprecated:: 3.9


.. function:: b2a_hqx(data)

Perform hexbin4 binary-to-ASCII translation and return the resulting string. The
argument should already be RLE-coded, and have a length divisible by 3 (except
possibly the last fragment).

.. deprecated:: 3.9


.. function:: crc_hqx(data, value)

Compute a 16-bit CRC value of *data*, starting with *value* as the
Expand Down Expand Up @@ -222,9 +182,6 @@ The :mod:`binascii` module defines the following functions:
Support for RFC compliant base64-style encoding in base 16, 32, 64,
and 85.

Module :mod:`binhex`
Support for the binhex format used on the Macintosh.

Module :mod:`uu`
Support for UU encoding used on Unix.

Expand Down
59 changes: 0 additions & 59 deletions Doc/library/binhex.rst

This file was deleted.

1 change: 0 additions & 1 deletion Doc/library/netdata.rst
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@ on the internet.
mailbox.rst
mimetypes.rst
base64.rst
binhex.rst
binascii.rst
quopri.rst
uu.rst
12 changes: 12 additions & 0 deletions Doc/whatsnew/3.11.rst
Original file line number Diff line number Diff line change
Expand Up @@ -235,9 +235,21 @@ sqlite3

Removed
=======

* :class:`smtpd.MailmanProxy` is now removed as it is unusable without
an external module, ``mailman``. (Contributed by Dong-hee Na in :issue:`35800`.)

* The ``binhex`` module, deprecated in Python 3.9, is now removed.
The following :mod:`binascii` functions, deprecated in Python 3.9, are now
also removed:

* ``a2b_hqx()``, ``b2a_hqx()``;
* ``rlecode_hqx()``, ``rledecode_hqx()``.

The :func:`binascii.crc_hqx` function remains available.

(Contributed by Victor Stinner in :issue:`45085`.)


Optimizations
=============
Expand Down
Loading