Skip to content

Commit

Permalink
Update Documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
Bibo-Joshi committed Feb 4, 2025
1 parent c7a596d commit 287277c
Show file tree
Hide file tree
Showing 5 changed files with 31 additions and 17 deletions.
16 changes: 8 additions & 8 deletions changes/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -36,16 +36,16 @@ class RstChangeNote(CommentChangeNote):
)
ChangoSectionChangeNote = GitHubSectionChangeNote.with_sections(
[
Section(uid="internal", title="Internal Changes", sort_order=0),
Section(uid="dependencies", title="Dependencies", sort_order=1),
Section(uid="features", title="New Features", sort_order=2),
Section(uid="bugfixes", title="Bug Fixes", sort_order=3),
Section(uid="deprecations", title="Deprecations", sort_order=4),
Section(uid="breaking", title="Breaking Changes", sort_order=5),
Section(uid="security", title="Security Changes", sort_order=6),
Section(uid="highlights", title="Highlights", sort_order=0),
Section(uid="breaking", title="Breaking Changes", sort_order=1),
Section(uid="security", title="Security Changes", sort_order=2),
Section(uid="deprecations", title="Deprecations", sort_order=3),
Section(uid="features", title="New Features", sort_order=4),
Section(uid="bugfixes", title="Bug Fixes", sort_order=5),
Section(uid="dependencies", title="Dependencies", sort_order=6),
Section(uid="other", title="Other Changes", sort_order=7),
Section(uid="documentation", title="Documentation", sort_order=8),
Section(uid="highlights", title="Highlights", sort_order=9),
Section(uid="internal", title="Internal Changes", sort_order=9),
]
)
ChangoSectionChangeNote.OWNER = "Bibo-Joshi"
Expand Down
6 changes: 6 additions & 0 deletions docs/source/chango.concrete.backwardcompatiblechango.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
BackwardCompatibleChanGo
=========================

.. autoclass:: chango.concrete.BackwardCompatibleChanGo
:members:
:show-inheritance:
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
BackwardCompatibleVersionScanner
================================

.. autoclass:: chango.concrete.BackwardCompatibleVersionScanner
:members:
:show-inheritance:
2 changes: 2 additions & 0 deletions docs/source/chango.concrete.rst
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@ concrete
.. toctree::
:titlesonly:

chango.concrete.backwardcompatiblechango
chango.concrete.backwardcompatibleversionscanner
chango.concrete.commentchangenote
chango.concrete.commentversionnote
chango.concrete.directorychango
Expand Down
18 changes: 9 additions & 9 deletions src/chango/concrete/_backwardcompatiblechango.py
Original file line number Diff line number Diff line change
Expand Up @@ -46,27 +46,27 @@ def __init__(
@property
@override
def scanner(self) -> "BackwardCompatibleVersionScanner":
"""The :class:`~chango.abc.BackwardCompatibleVersionScanner` instance that is used
by this :class:`~chango.abc.BackwardCompatibleChanGo`.
"""The :class:`~chango.concrete.BackwardCompatibleVersionScanner` instance that is used
by this :class:`BackwardCompatibleChanGo`.
Hint:
The scanner is a composite of the scanners of
:paramref:`~chango.abc.BackwardCompatibleChanGo.main_instance` and
:paramref:`~chango.abc.BackwardCompatibleChanGo.legacy_instance`.
:paramref:`~BackwardCompatibleChanGo.main_instance` and
:paramref:`~BackwardCompatibleChanGo.legacy_instance`.
"""
return self._scanner

@override
def build_template_change_note(self, slug: str, uid: str | None = None) -> CNT:
"""Calls :meth:`~chango.abc.ChanGo.build_template_change_note` on
:paramref:`~chango.abc.BackwardCompatibleChanGo.main_instance`.
:paramref:`~BackwardCompatibleChanGo.main_instance`.
"""
return self._main_instance.build_template_change_note(slug, uid)

@override
def build_version_note(self, version: Optional["Version"]) -> VNT:
"""Calls :meth:`~chango.abc.ChanGo.build_version_note`
on :paramref:`~chango.abc.BackwardCompatibleChanGo.main_instance` or one of the legacy
on :paramref:`~BackwardCompatibleChanGo.main_instance` or one of the legacy
instances depending on the result of :meth:`~chango.abc.VersionScanner.is_available`.
"""
for chango in (self._main_instance, *self._legacy_instances):
Expand All @@ -77,7 +77,7 @@ def build_version_note(self, version: Optional["Version"]) -> VNT:
@override
def build_version_history(self) -> VHT:
"""Calls :meth:`~chango.abc.ChanGo.build_version_history`
on :paramref:`~chango.abc.BackwardCompatibleChanGo.main_instance`.
on :paramref:`~BackwardCompatibleChanGo.main_instance`.
"""
return self._main_instance.build_version_history()

Expand All @@ -94,14 +94,14 @@ def load_change_note(self, uid: str) -> CNT:
@override
def get_write_directory(self, change_note: CNT | str, version: VUIDInput) -> Path:
"""Calls :meth:`~chango.abc.ChanGo.get_write_directory`
on :paramref:`~chango.abc.BackwardCompatibleChanGo.main_instance`.
on :paramref:`~BackwardCompatibleChanGo.main_instance`.
"""
return self._main_instance.get_write_directory(change_note, version)

def build_github_event_change_note(
self, event: dict[str, Any], data: dict[str, Any] | ChanGoActionData | None = None
) -> CNT | None:
"""Calls :meth:`~chango.abc.ChanGo.build_github_event_change_note`
on :paramref:`~chango.abc.BackwardCompatibleChanGo.main_instance`.
on :paramref:`~BackwardCompatibleChanGo.main_instance`.
"""
return self._main_instance.build_github_event_change_note(event, data)

0 comments on commit 287277c

Please sign in to comment.