Repository navigation
Remove deprecated Python SDK compatibility shims - #8939
Open
Amaury Chamayou (achamayou) wants to merge 1 commit into
Open
Amaury Chamayou (achamayou) wants to merge 1 commit into
Amaury Chamayou (achamayou) wants to merge 1 commit into
Conversation
Remove the deprecated ccf.cose.verify_receipt function and the deprecated ccf.ledger signature re-export shim ahead of 8.0, update documentation and migration notes, and add unit tests verifying their removal. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Copilot-Session: 1c45d2f3daad42b4a44ec57e571de96c
Contributor
There was a problem hiding this comment.
🟢 Approval recommended
No active review issues block the removal of the deprecated Python SDK compatibility APIs.
No open issues 🎉
What changed in this PR
Removes deprecated Python SDK compatibility APIs for CCF 8.0, directing callers to stricter receipt verification and the dedicated signatures module.
Changes:
- Removes
ccf.cose.verify_receiptand deprecatedccf.ledgersignature re-exports. - Adds regression tests confirming the removed APIs are unavailable.
- Updates API documentation, migration guidance, and release notes.
Custom instructions used
Repository and change-description guidance supplied in the review context; no additional instruction files loaded.
| File | Description |
|---|---|
python/tests/test_receipt.py |
Checks that the legacy receipt verifier is absent. |
python/tests/test_ledger.py |
Checks that deprecated signature re-exports are absent. |
python/src/ccf/ledger.py |
Removes the signature compatibility shim. |
python/src/ccf/cose.py |
Removes the deprecated receipt verifier. |
doc/use_apps/verify_tx.rst |
Removes obsolete legacy-verifier guidance. |
doc/releases/migration_7_x_to_8_x.rst |
Documents removed APIs and replacements. |
doc/audit/python_library.rst |
Removes the deleted API from generated documentation. |
.changes/remove-python-compatibility-shims.removed.md |
Records removals and links migration guidance. |
Review effort: Balanced
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Removes the deprecated Python SDK compatibility shims ahead of the 8.0 major release so callers cannot accidentally rely on legacy entry points that bypass stricter receipt verification or obscure where signature APIs live.
Specifically:
ccf.cose.verify_receiptin favor ofccf.receipt.verify_cose._DEPRECATED_SIGNATURE_REEXPORTSand__getattr__fromccf.ledgerin favor of direct imports fromccf.signatures..changesentry for 8.0.Safety and compatibility
Breaking Python SDK API removal planned for 8.0: callers using
ccf.cose.verify_receiptmust migrate toccf.receipt.verify_cose, and callers importing signature constants, exceptions, orspki_from_certfromccf.ledgermust import them fromccf.signatures.Closes #8861