8000 [3.10] bpo-41180: Replace marshal code.__new__ audit event with marshal.load[s] and marshal.dumps (GH-26961) by zooba · Pull Request #26970 · python/cpython · GitHub
[go: up one dir, main page]

Skip to content

[3.10] bpo-41180: Replace marshal code.__new__ audit event with marshal.load[s] and marshal.dumps (GH-26961) #26970

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

Merged
merged 2 commits into from
Jun 30, 2021
Merged
Changes from 1 commit
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
Prev Previous commit
Fix docs
  • Loading branch information
zooba committed Jun 30, 2021
commit 861c21e972aeb3a807ad7ed0fef3b20a2f34a722
12 changes: 11 additions & 1 deletion Doc/library/marshal.rst
Original file line number Diff line number Diff line change
Expand Up @@ -76,13 +76,18 @@ The module defines these functions:
format), raise :exc:`EOFError`, :exc:`ValueError` or :exc:`TypeError`. The
file must be a readable :term:`binary file`.

.. audit-event:: marshal.loads bytes marshal.load
.. audit-event:: marshal.load "" marshal.load

.. note::

If an object containing an unsupported type was marshalled with :func:`dump`,
:func:`load` will substitute ``None`` for the unmarshallable type.

.. versionchanged:: 3.10

This call used to raise a ``code.__new__`` audit event for each code object. Now
it raises a single ``marshal.load`` event for the entire load operation.


.. function:: dumps(value[, version])

Expand All @@ -104,6 +109,11 @@ The module defines these functions:

.. audit-event:: marshal.loads bytes marshal.load

.. versionchanged:: 3.10

This call used to raise a ``code.__new__`` audit event for each code object. Now
it raises a single ``marshal.loads`` event for the entire load operation.


In addition, the following constants are defined:

Expand Down
0