Skip to content

Commit e36af28

Browse files
authored
Docs updates (#76)
* updating docs and release tools * more newsfragments * towncrier commands in Makefile * update towncrier underlines to match existing docs * new underlinew * new underlinew * underlines * underlines * lint * makefile cleanup * remove readme.html stuff * add build dev dependency and verify can build * update dns tool dependency from aiodns to dnspython
1 parent cd289ff commit e36af28

File tree

14 files changed

+245
-74
lines changed

14 files changed

+245
-74
lines changed

.bumpversion.cfg

Lines changed: 0 additions & 12 deletions
This file was deleted.

.gitignore

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -58,9 +58,6 @@ coverage.xml
5858
# Sphinx documentation
5959
docs/_build/
6060

61-
# File just for checking my RST syntax
62-
readme.html
63-
6461
# PyBuilder
6562
target/
6663

HISTORY.rst

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
History
22
=======
33

4+
.. towncrier release notes start
5+
46
0.0.7 (2019-5-8)
57
----------------
68

Makefile

Lines changed: 26 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -11,20 +11,6 @@ endef
1111
export BROWSER_PYSCRIPT
1212
BROWSER := python -c "$$BROWSER_PYSCRIPT"
1313

14-
help:
15-
@echo "clean - remove all build, test, coverage and Python artifacts"
16-
@echo "clean-build - remove build artifacts"
17-
@echo "clean-pyc - remove Python file artifacts"
18-
@echo "clean-test - remove test and coverage artifacts"
19-
@echo "lint - check style with ruff"
20-
@echo "test - run tests quickly with the default Python"
21-
@echo "test-all - run tests on every Python version with tox"
22-
@echo "coverage - check code coverage quickly with the default Python"
23-
@echo "docs - generate Sphinx HTML documentation, including API docs"
24-
@echo "release - package and upload a release"
25-
@echo "dist - package"
26-
@echo "install - install the package to the active Python's site-packages"
27-
2814
clean: clean-build clean-pyc clean-test
2915

3016
clean-build:
@@ -81,24 +67,41 @@ docs:
8167
servedocs: docs
8268
watchmedo shell-command -p '*.rst' -c '$(MAKE) -C docs html' -R -D .
8369

84-
readme.html: README.rst
85-
rst2html.py README.rst > readme.html
86-
8770
.PHONY: authors
8871
authors:
8972
git shortlog --numbered --summary --email | cut -f 2 > AUTHORS
9073

9174
dist: clean
92-
python setup.py sdist
93-
python setup.py bdist_wheel
75+
python -m build
76+
ls -l dist
9477

9578
install: clean
9679
python setup.py install
9780

98-
bump:
99-
bumpversion --tag-name "{new_version}" patch
100-
101-
deploy-prep: clean authors readme.html docs dist
81+
# build newsfragments into release notes and verify docs build correctly
82+
notes: check-bump validate-newsfragments
83+
# Let UPCOMING_VERSION be the version that is used for the current bump
84+
$(eval UPCOMING_VERSION=$(shell bump-my-version bump --dry-run $(bump) -v | awk -F"'" '/New version will be / {print $$2}'))
85+
# Now generate the release notes to have them included in the release commit
86+
towncrier build --yes --version $(UPCOMING_VERSION)
87+
# Before we bump the version, make sure that the towncrier-generated docs will build
88+
make docs
89+
git commit -m "Compile release notes for v$(UPCOMING_VERSION)"
90+
91+
deploy-prep: clean authors docs dist
10292
@echo "Did you remember to bump the version?"
10393
@echo "If not, run 'bumpversion {patch, minor, major}' and run this target again"
10494
@echo "Don't forget to update HISTORY.rst"
95+
96+
# helpers
97+
98+
# verify that newsfragments are valid and towncrier can build them
99+
validate-newsfragments:
100+
python ./newsfragments/validate_files.py
101+
towncrier build --draft --version preview
102+
103+
# verify that a bump argument is set to be passed to bump-my-version
104+
check-bump:
105+
ifndef bump
106+
$(error bump must be set, typically: major, minor, patch, or devnum)
107+
endif

docs/multiaddr.rst

Lines changed: 18 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,10 @@ Subpackages
55
-----------
66

77
.. toctree::
8+
:maxdepth: 4
89

9-
multiaddr.codecs
10-
multiaddr.resolvers
10+
multiaddr.codecs
11+
multiaddr.resolvers
1112

1213
Submodules
1314
----------
@@ -16,39 +17,38 @@ multiaddr.exceptions module
1617
---------------------------
1718

1819
.. automodule:: multiaddr.exceptions
19-
:members:
20-
:undoc-members:
21-
:show-inheritance:
20+
:members:
21+
:show-inheritance:
22+
:undoc-members:
2223

2324
multiaddr.multiaddr module
2425
--------------------------
2526

2627
.. automodule:: multiaddr.multiaddr
27-
:members:
28-
:undoc-members:
29-
:show-inheritance:
28+
:members:
29+
:show-inheritance:
30+
:undoc-members:
3031

3132
multiaddr.protocols module
3233
--------------------------
3334

3435
.. automodule:: multiaddr.protocols
35-
:members:
36-
:undoc-members:
37-
:show-inheritance:
36+
:members:
37+
:show-inheritance:
38+
:undoc-members:
3839

3940
multiaddr.transforms module
4041
---------------------------
4142

4243
.. automodule:: multiaddr.transforms
43-
:members:
44-
:undoc-members:
45-
:show-inheritance:
46-
44+
:members:
45+
:show-inheritance:
46+
:undoc-members:
4747

4848
Module contents
4949
---------------
5050

5151
.. automodule:: multiaddr
52-
:members:
53-
:undoc-members:
54-
:show-inheritance:
52+
:members:
53+
:show-inheritance:
54+
:undoc-members:

multiaddr/multiaddr.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
# flake8: noqa: F811
21
import collections.abc
32
from collections.abc import Iterator, Sequence
43
from typing import Any, Optional, TypeVar, Union, overload

newsfragments/65.feature.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Added support for CIDv1 format and improved sequence protocol handling with enhanced indexing and slicing operations.

newsfragments/65.internal.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Enhanced type safety with comprehensive type hints, improved validation, and expanded test coverage for better code reliability and maintainability.

newsfragments/68.feature.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Adds DNSADDR protocol support.

newsfragments/74.feature.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Adds support for p2p-circuit addresses.

0 commit comments

Comments
 (0)