Porządki w publicznym API wyjątków (przed 0.2) z aliasami kompatybilności#4
Merged
Conversation
…ości - Popraw literówkę: SciencistDoesNotExist → ScientistDoesNotExist; stara nazwa pozostaje jako alias (ten sam obiekt klasy). - StatementsResendFailedException: parametr i atrybut publication_pk (semantyka hosta BPP) przemianowany na neutralny correlation_id; publication_pk dostępne dalej jako read-only property. - Eksport obu nazw naukowca z pbn_client.__init__ + aktualizacja __all__. - Nowe testy aliasów kompatybilności (tests/test_exceptions_compat.py). Bez podbicia wersji — 0.1.0 pozostaje kompatybilne. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
mpasternak
force-pushed
the
feat/pbn-api-cleanup
branch
from
July 14, 2026 17:20
ce0646b to
5b1199b
Compare
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.
Co i po co
Czyszczenie publicznego API wyjątków przed wydaniem 0.2 — z pełną kompatybilnością wsteczną z opublikowanym 0.1.0.
1. Literówka:
SciencistDoesNotExist→ScientistDoesNotExistKlasa przemianowana na poprawną pisownię; stara nazwa pozostaje jako alias wskazujący na ten sam obiekt klasy (
SciencistDoesNotExist is ScientistDoesNotExist), więc istniejąceexcept SciencistDoesNotExistdziała bez zmian. Obie nazwy eksportowane zpbn_clientipbn_client.exceptions(__all__zaktualizowane w obu).2.
StatementsResendFailedException:publication_pk→correlation_idParametr
publication_pkprzeciekał semantykę hosta (BPP). Parametr i atrybut przemianowane na neutralnecorrelation_id;publication_pkdostępne dalej jako read-only property zwracająceself.correlation_id. Konstrukcja pozycyjna działa jak dotąd; komunikat błędu przeformułowany neutralnie („o identyfikatorze …").Testy
Nowy
tests/test_exceptions_compat.py: tożsamość aliasu, eksporty z pakietu, konstrukcja keyword pocorrelation_id, konstrukcja pozycyjna, równość.correlation_id/.publication_pk, treść komunikatu.Bez podbicia wersji.
uv run --isolated pytest -q→ 48 passeduv run --isolated ruff check .→ clean🤖 Generated with Claude Code