pythonic-fp-fptools 5.1.2__tar.gz → 5.3.0__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (52) hide show
  1. pythonic_fp_fptools-5.3.0/.github/workflows/static.yml +64 -0
  2. {pythonic_fp_fptools-5.1.2 → pythonic_fp_fptools-5.3.0}/.gitignore +2 -0
  3. {pythonic_fp_fptools-5.1.2 → pythonic_fp_fptools-5.3.0}/CHANGELOG.rst +57 -2
  4. {pythonic_fp_fptools-5.1.2 → pythonic_fp_fptools-5.3.0}/PKG-INFO +18 -18
  5. {pythonic_fp_fptools-5.1.2 → pythonic_fp_fptools-5.3.0}/README.rst +5 -5
  6. pythonic_fp_fptools-5.3.0/docs/Makefile +78 -0
  7. pythonic_fp_fptools-5.3.0/docs/gen_conf.py +109 -0
  8. pythonic_fp_fptools-5.3.0/docs/requirements.txt +2 -0
  9. pythonic_fp_fptools-5.3.0/docs/source/api/function.rst +6 -0
  10. pythonic_fp_fptools-5.3.0/docs/source/api/index.rst +20 -0
  11. pythonic_fp_fptools-5.3.0/docs/source/api/lazy.rst +6 -0
  12. pythonic_fp_fptools-5.3.0/docs/source/api/monads/either.rst +6 -0
  13. pythonic_fp_fptools-5.3.0/docs/source/api/monads/index.rst +10 -0
  14. pythonic_fp_fptools-5.3.0/docs/source/api/monads/maybe.rst +6 -0
  15. pythonic_fp_fptools-5.3.0/docs/source/api/monads/state.rst +6 -0
  16. pythonic_fp_fptools-5.3.0/docs/source/changelog.rst +7 -0
  17. pythonic_fp_fptools-5.3.0/docs/source/description.rst +8 -0
  18. pythonic_fp_fptools-5.3.0/docs/source/index.rst +30 -0
  19. pythonic_fp_fptools-5.3.0/docs/source/releases.rst +26 -0
  20. pythonic_fp_fptools-5.3.0/docs/source/usage.rst +29 -0
  21. {pythonic_fp_fptools-5.1.2 → pythonic_fp_fptools-5.3.0}/pyproject.toml +28 -24
  22. pythonic_fp_fptools-5.3.0/src/pythonic_fp/fptools/__init__.py +36 -0
  23. pythonic_fp_fptools-5.3.0/src/pythonic_fp/fptools/__init__.pyi +0 -0
  24. pythonic_fp_fptools-5.3.0/src/pythonic_fp/fptools/either.py +444 -0
  25. {pythonic_fp_fptools-5.1.2 → pythonic_fp_fptools-5.3.0}/src/pythonic_fp/fptools/either.pyi +10 -10
  26. pythonic_fp_fptools-5.3.0/src/pythonic_fp/fptools/function.py +121 -0
  27. {pythonic_fp_fptools-5.1.2 → pythonic_fp_fptools-5.3.0}/src/pythonic_fp/fptools/function.pyi +2 -1
  28. pythonic_fp_fptools-5.3.0/src/pythonic_fp/fptools/lazy.py +215 -0
  29. pythonic_fp_fptools-5.3.0/src/pythonic_fp/fptools/maybe.py +251 -0
  30. {pythonic_fp_fptools-5.1.2 → pythonic_fp_fptools-5.3.0}/src/pythonic_fp/fptools/maybe.pyi +3 -1
  31. pythonic_fp_fptools-5.3.0/src/pythonic_fp/fptools/py.typed +0 -0
  32. pythonic_fp_fptools-5.3.0/src/pythonic_fp/fptools/state.py +248 -0
  33. pythonic_fp_fptools-5.1.2/src/pythonic_fp/fptools/__init__.py +0 -40
  34. pythonic_fp_fptools-5.1.2/src/pythonic_fp/fptools/either.py +0 -306
  35. pythonic_fp_fptools-5.1.2/src/pythonic_fp/fptools/function.py +0 -105
  36. pythonic_fp_fptools-5.1.2/src/pythonic_fp/fptools/lazy.py +0 -187
  37. pythonic_fp_fptools-5.1.2/src/pythonic_fp/fptools/maybe.py +0 -138
  38. pythonic_fp_fptools-5.1.2/src/pythonic_fp/fptools/state.py +0 -121
  39. {pythonic_fp_fptools-5.1.2 → pythonic_fp_fptools-5.3.0}/LICENSE +0 -0
  40. /pythonic_fp_fptools-5.1.2/src/pythonic_fp/fptools/__init__.pyi → /pythonic_fp_fptools-5.3.0/docs/source/_static/.gitkeep +0 -0
  41. /pythonic_fp_fptools-5.1.2/src/pythonic_fp/fptools/py.typed → /pythonic_fp_fptools-5.3.0/docs/source/_templates/.gitkeep +0 -0
  42. {pythonic_fp_fptools-5.1.2 → pythonic_fp_fptools-5.3.0}/src/pythonic_fp/fptools/lazy.pyi +0 -0
  43. {pythonic_fp_fptools-5.1.2 → pythonic_fp_fptools-5.3.0}/src/pythonic_fp/fptools/state.pyi +0 -0
  44. {pythonic_fp_fptools-5.1.2 → pythonic_fp_fptools-5.3.0}/tests/either/test_either.py +0 -0
  45. {pythonic_fp_fptools-5.1.2 → pythonic_fp_fptools-5.3.0}/tests/either/test_sequence_either.py +0 -0
  46. {pythonic_fp_fptools-5.1.2 → pythonic_fp_fptools-5.3.0}/tests/either/test_str_repr_either.py +0 -0
  47. {pythonic_fp_fptools-5.1.2 → pythonic_fp_fptools-5.3.0}/tests/function/test_function.py +0 -0
  48. {pythonic_fp_fptools-5.1.2 → pythonic_fp_fptools-5.3.0}/tests/lazy/test_lazy.py +0 -0
  49. {pythonic_fp_fptools-5.1.2 → pythonic_fp_fptools-5.3.0}/tests/maybe/maybe.py +0 -0
  50. {pythonic_fp_fptools-5.1.2 → pythonic_fp_fptools-5.3.0}/tests/maybe/test_sequence_maybe.py +0 -0
  51. {pythonic_fp_fptools-5.1.2 → pythonic_fp_fptools-5.3.0}/tests/maybe/test_str_repr_maybe.py +0 -0
  52. {pythonic_fp_fptools-5.1.2 → pythonic_fp_fptools-5.3.0}/tests/state/test_state.py +0 -0
@@ -0,0 +1,64 @@
1
+ name: Build and Deploy Furo Themed Sphinx Documentation
2
+
3
+ on:
4
+ push:
5
+ branches: ["main"]
6
+ workflow_dispatch:
7
+
8
+ env:
9
+ RELEASE: '5.2.0'
10
+ DEVEL: '6.0.0'
11
+ PYTHON: '3.14'
12
+
13
+ permissions:
14
+ contents: read
15
+ pages: write
16
+ id-token: write
17
+
18
+ concurrency:
19
+ group: "pages"
20
+ cancel-in-progress: false
21
+
22
+ jobs:
23
+ deploy:
24
+ runs-on: ubuntu-latest
25
+ environment:
26
+ name: github-pages
27
+ url: ${{ steps.deployment.outputs.page_url }}
28
+ steps:
29
+ - name: Checkout
30
+ uses: actions/checkout@v6
31
+
32
+ - name: Select Python
33
+ uses: actions/setup-python@v6
34
+ with:
35
+ python-version: '3.14'
36
+
37
+ - name: Install Sphinx Dependencies
38
+ run: |
39
+ pip install -r docs/requirements.txt
40
+ sudo apt-get install -y graphviz
41
+
42
+ - name: Build Release Docs
43
+ run: |
44
+ pip install pythonic-fp-fptools
45
+ docs/gen_conf.py release ${{ env.RELEASE }} "FP Tools" fptools > docs/source/conf.py
46
+ sphinx-build -M html docs/source docs/build/release
47
+
48
+ - name: Build Development Docs
49
+ run: |
50
+ pip install -e .
51
+ docs/gen_conf.py devel ${{ env.DEVEL }} "FP Tools" fptools > docs/source/conf.py
52
+ sphinx-build -M html docs/source docs/build/development
53
+
54
+ - name: Setup Pages
55
+ uses: actions/configure-pages@v6
56
+
57
+ - name: Upload Artifact
58
+ uses: actions/upload-pages-artifact@v5
59
+ with:
60
+ path: docs/build
61
+
62
+ - name: Deploy to GitHub Pages
63
+ uses: actions/deploy-pages@v5
64
+ id: deployment
@@ -1,6 +1,8 @@
1
1
  # Minimal version - only add to when necessary
2
2
  **/__pycache__/
3
3
  dist/
4
+ docs/build/
5
+ docs/source/conf.py
4
6
  **/.dmypy.json
5
7
  **/.mypy_cache/
6
8
  **/.pytest_cache/
@@ -17,6 +17,37 @@ See `Semantic Versioning 2.0.0 <https://semver.org>`_.
17
17
  Releases and Important Milestones
18
18
  ---------------------------------
19
19
 
20
+ PyPI 5.3.0 - 2026-05-09
21
+ ~~~~~~~~~~~~~~~~~~~~~~~
22
+
23
+ First PyPI release in over a year with actual substative code
24
+ changes.
25
+
26
+ - Finally happy with the Sphinx/Furo based documentation.
27
+ - Fixed errors with MayBe and Either hashing.
28
+ - This will fix the PyPI link issues.
29
+ - Next release will be 6.0.0 when I move the monads to
30
+ their own submodule.
31
+
32
+ Development Status Reappraisal - 2026-05-05
33
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
34
+
35
+ Maintainer reappraised the Development Status for
36
+ pythonic-fp-fptools to be ``"5 - Production/Stable"``.
37
+
38
+
39
+ PyPI 5.2.0 - 2026-01-13
40
+ ~~~~~~~~~~~~~~~~~~~~~~~
41
+
42
+ Added function.compose back on 2025-12-04. Docstring updates for Sphinx.
43
+
44
+
45
+ PyPI 5.1.2 - 2025-09-28
46
+ ~~~~~~~~~~~~~~~~~~~~~~~
47
+
48
+ Patch bump for pythonic-fp PyPI coordinated release 3.3.3.
49
+
50
+
20
51
  PyPI 5.1.1 - 2025-09-09
21
52
  ~~~~~~~~~~~~~~~~~~~~~~~
22
53
 
@@ -33,10 +64,11 @@ made it a MINOR release due to introducing .pyi files.
33
64
  PyPI 5.0.0 - 2025-08-02
34
65
  ~~~~~~~~~~~~~~~~~~~~~~~
35
66
 
36
- Coordinated entire project pythonic-fp PyPI deployment.
67
+ Coordinated moving entire project to the pythonic-fp PyPI name.
37
68
 
38
69
  - moved maybe.py and xor.py from containers, renamed xor.py -> either.py.
39
70
 
71
+
40
72
  PyPI 4.0.0 - 2025-07-13
41
73
  ~~~~~~~~~~~~~~~~~~~~~~~
42
74
 
@@ -48,16 +80,21 @@ Dropped developer status to Beta
48
80
  TODO: After next Boring Math (bm) deployment, I should be able to archive
49
81
  my dtools namespace repos
50
82
 
83
+
51
84
  PyPI 3.0.0 - 2025-07-06
52
85
  ~~~~~~~~~~~~~~~~~~~~~~~
53
86
 
54
87
  First PyPI release as ``pythonic-fp.fptools``
55
88
 
56
- - dropping dtools namespace name because there is a repo by that name.
89
+ - dropping dtools namespace name because there is a repo by that name
90
+ on PyPI.
91
+
57
92
 
58
93
  PyPI 2.0.0 - 2025-05-22
59
94
  ~~~~~~~~~~~~~~~~~~~~~~~
60
95
 
96
+ One more release as dtools.fp.
97
+
61
98
  - Moved dtools.fp.err_handling to the dtools.containers PyPI project
62
99
 
63
100
  - Moved class MayBe -> module dtools.containers.maybe
@@ -66,6 +103,7 @@ PyPI 2.0.0 - 2025-05-22
66
103
 
67
104
  - will import dtools.fp.lazy directly for this functionality
68
105
 
106
+
69
107
  PyPI 1.7.0 - 2025-04-22
70
108
  ~~~~~~~~~~~~~~~~~~~~~~~
71
109
 
@@ -76,6 +114,7 @@ Last PyPI release as dtools.fp
76
114
  - docstring changes
77
115
  - pyproject.toml standardization
78
116
 
117
+
79
118
  PyPI 1.6.1.0 - 2025-04-17
80
119
  ~~~~~~~~~~~~~~~~~~~~~~~~~
81
120
 
@@ -91,11 +130,13 @@ PyPI 1.6.1.0 - 2025-04-17
91
130
 
92
131
  - Also noticed MB and XOR still have camelCase APIs
93
132
 
133
+
94
134
  PyPI 1.6.0 - 2025-04-07
95
135
  ~~~~~~~~~~~~~~~~~~~~~~~
96
136
 
97
137
  - typing improvements
98
138
 
139
+
99
140
  PyPI 1.4.0 - 2025-03-16
100
141
  ~~~~~~~~~~~~~~~~~~~~~~~
101
142
 
@@ -115,11 +156,13 @@ PyPI 1.4.0 - 2025-03-16
115
156
 
116
157
  - avoid using these methods in pure code
117
158
 
159
+
118
160
  PyPI 1.3.1 - 2025-02-05
119
161
  ~~~~~~~~~~~~~~~~~~~~~~~
120
162
 
121
163
  - added class method sequence to class State
122
164
 
165
+
123
166
  PyPI 1.3.0 - 2025-01-17
124
167
  ~~~~~~~~~~~~~~~~~~~~~~~
125
168
 
@@ -130,6 +173,7 @@ Repo name changes.
130
173
  - GitHub: fp -> dtools-fp
131
174
  - PyPI: grscheller.fp -> dtools.fp
132
175
 
176
+
133
177
  PyPI 1.2.0 - 2025-01-04
134
178
  ~~~~~~~~~~~~~~~~~~~~~~~
135
179
 
@@ -137,6 +181,7 @@ PyPI 1.2.0 - 2025-01-04
137
181
  - renamed flatmap methods to bind
138
182
  - minor MB and XOR updates/corrections
139
183
 
184
+
140
185
  PyPI 1.1.0 - 2024-11-18
141
186
  ~~~~~~~~~~~~~~~~~~~~~~~
142
187
 
@@ -145,6 +190,7 @@ Added fp.function module.
145
190
  - combine and partially apply functions as first class objects
146
191
  - some tests may be lacking
147
192
 
193
+
148
194
  Version 1.0.2.0 - 2024-10-20 (Devel environment only)
149
195
  ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
150
196
 
@@ -162,6 +208,7 @@ Version 1.0.2.0 - 2024-10-20 (Devel environment only)
162
208
 
163
209
  - will redo docs in docs repo
164
210
 
211
+
165
212
  PyPI 1.0.1 - 2024-10-20
166
213
  ~~~~~~~~~~~~~~~~~~~~~~~
167
214
 
@@ -173,6 +220,7 @@ PyPI 1.0.1 - 2024-10-20
173
220
  PyPI 1.0.0 - 2024-10-18
174
221
  ~~~~~~~~~~~~~~~~~~~~~~~
175
222
 
223
+
176
224
  Decided to make this release first stable release.
177
225
 
178
226
  - renamed module fp.woException to fp.err_handling
@@ -181,11 +229,13 @@ Decided to make this release first stable release.
181
229
 
182
230
  - pytest improvements based on pytest documentation
183
231
 
232
+
184
233
  PyPI 0.4.0 - 2024-10-03
185
234
  ~~~~~~~~~~~~~~~~~~~~~~~
186
235
 
187
236
  Long overdue PyPI release.
188
237
 
238
+
189
239
  Version 0.3.5.1 - 2024-10-03 (Devel environment only)
190
240
  ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
191
241
 
@@ -204,6 +254,7 @@ New module ``grscheller.fp.nothingness`` which contains
204
254
 
205
255
  - prefer class ``MB`` to represent a missing value in client code
206
256
 
257
+
207
258
  PyPI 0.3.3 - 2024-08-25
208
259
  ~~~~~~~~~~~~~~~~~~~~~~~
209
260
 
@@ -216,6 +267,7 @@ PyPI 0.3.3 - 2024-08-25
216
267
  - makeRight(self, right: R|Nada=nada) -> XOR\[L, R\]:
217
268
  - swapRight(self, right: R) -> XOR\[L, R\]:
218
269
 
270
+
219
271
  PyPI 0.3.0 - 2024-08-17
220
272
  ~~~~~~~~~~~~~~~~~~~~~~~
221
273
 
@@ -223,6 +275,7 @@ Class Nothing re-added but renamed class Nada.
223
275
 
224
276
  Version grscheller.untyped.nothing for more strictly typed code.
225
277
 
278
+
226
279
  PyPI 0.2.1 - 2024-07-26
227
280
  ~~~~~~~~~~~~~~~~~~~~~~~
228
281
 
@@ -231,6 +284,7 @@ PyPI grscheller.fp package release v0.2.1
231
284
  - forgot to update README.md on last PyPI release
232
285
  - simplified README.md to help alleviate this mistake in the future
233
286
 
287
+
234
288
  PyPI 0.2.0 - 2024-07-26
235
289
  ~~~~~~~~~~~~~~~~~~~~~~~
236
290
 
@@ -243,6 +297,7 @@ PyPI 0.2.0 - 2024-07-26
243
297
 
244
298
  - renamed ``fp.wo_exception`` to ``fp.woException``
245
299
 
300
+
246
301
  PyPI 0.1.0 - 2024-07-11
247
302
  ~~~~~~~~~~~~~~~~~~~~~~~
248
303
 
@@ -1,29 +1,29 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: pythonic-fp-fptools
3
- Version: 5.1.2
4
- Summary: Pythonic FP - Functional Programming Tools
3
+ Version: 5.3.0
4
+ Summary: Functional Programming Tools
5
5
  Keywords: either,fp,functional,functional programming,lazy,maybe,monad,non-strict
6
6
  Author-email: "Geoffrey R. Scheller" <geoffrey@scheller.com>
7
- Requires-Python: >=3.12
7
+ Requires-Python: >=3.13
8
8
  Description-Content-Type: text/x-rst
9
- Classifier: Development Status :: 4 - Beta
9
+ Classifier: Development Status :: 5 - Production/Stable
10
10
  Classifier: Framework :: Pytest
11
11
  Classifier: Intended Audience :: Developers
12
12
  Classifier: License :: OSI Approved :: Apache Software License
13
13
  Classifier: Operating System :: OS Independent
14
- Classifier: Programming Language :: Python :: 3.13
14
+ Classifier: Programming Language :: Python :: 3.14
15
15
  Classifier: Typing :: Typed
16
16
  License-File: LICENSE
17
- Requires-Dist: pythonic-fp-booleans>=2.0.0
18
- Requires-Dist: pythonic-fp-circulararray>=6.0.0
19
- Requires-Dist: pythonic-fp-gadgets>=3.1.0
17
+ Requires-Dist: pythonic-fp-booleans>=3.0.2
18
+ Requires-Dist: pythonic-fp-circulararray>=6.0.4
19
+ Requires-Dist: pythonic-fp-gadgets>=4.0.2
20
20
  Requires-Dist: pytest>=8.4.1 ; extra == "test"
21
- Requires-Dist: pythonic-fp-containers>=4.0.0 ; extra == "test"
22
- Requires-Dist: pythonic-fp-iterables>=5.1.2 ; extra == "test"
23
- Requires-Dist: pythonic-fp-queues>=4.1.0 ; extra == "test"
21
+ Requires-Dist: pythonic-fp-containers>=4.0.1 ; extra == "test"
22
+ Requires-Dist: pythonic-fp-iterables>=5.1.3 ; extra == "test"
23
+ Requires-Dist: pythonic-fp-queues>=5.1.1 ; extra == "test"
24
24
  Project-URL: Changelog, https://github.com/grscheller/pythonic-fp-fptools/blob/main/CHANGELOG.rst
25
- Project-URL: Documentation, https://grscheller.github.io/pythonic-fp/fptools/development/build/html/
26
- Project-URL: Homepage, https://grscheller.github.io/pythonic-fp/homepage/build/html/
25
+ Project-URL: Documentation, https://grscheller.github.io/pythonic-fp/projects/fptools.html
26
+ Project-URL: Homepage, https://grscheller.github.io/pythonic-fp/
27
27
  Project-URL: Source, https://github.com/grscheller/pythonic-fp-fptools
28
28
  Provides-Extra: test
29
29
 
@@ -32,7 +32,7 @@ Pythonic FP - Functional tools
32
32
 
33
33
  PyPI project
34
34
  `pythonic-fp.fptools
35
- <https://pypi.org/project/pythonic-fp.fptools>`_.
35
+ <https://pypi.org/project/pythonic-fp-fptools>`_.
36
36
 
37
37
  Tools to aid with functional programming in Python while still
38
38
  endeavoring to be Pythonic.
@@ -53,19 +53,19 @@ endeavoring to be Pythonic.
53
53
 
54
54
  Part of the
55
55
  `pythonic-fp
56
- <https://grscheller.github.io/pythonic-fp/homepage/build/html/index.html>`_
56
+ <https://grscheller.github.io/pythonic-fp/>`_
57
57
  PyPI projects.
58
58
 
59
59
  Documentation
60
60
  -------------
61
61
 
62
- Documentation for this project is hosted on
62
+ Documentation and other links for this project are hosted on
63
63
  `GitHub Pages
64
- <https://grscheller.github.io/pythonic-fp/fptools/development/build/html>`_.
64
+ <https://grscheller.github.io/pythonic-fp/projects/fptools.html>`_.
65
65
 
66
66
  Copyright and License
67
67
  ---------------------
68
68
 
69
- Copyright (c) 2023-2025 Geoffrey R. Scheller. Licensed under the Apache
69
+ Copyright (c) 2023-2026 Geoffrey R. Scheller. Licensed under the Apache
70
70
  License, Version 2.0. See the LICENSE file for details.
71
71
 
@@ -3,7 +3,7 @@ Pythonic FP - Functional tools
3
3
 
4
4
  PyPI project
5
5
  `pythonic-fp.fptools
6
- <https://pypi.org/project/pythonic-fp.fptools>`_.
6
+ <https://pypi.org/project/pythonic-fp-fptools>`_.
7
7
 
8
8
  Tools to aid with functional programming in Python while still
9
9
  endeavoring to be Pythonic.
@@ -24,18 +24,18 @@ endeavoring to be Pythonic.
24
24
 
25
25
  Part of the
26
26
  `pythonic-fp
27
- <https://grscheller.github.io/pythonic-fp/homepage/build/html/index.html>`_
27
+ <https://grscheller.github.io/pythonic-fp/>`_
28
28
  PyPI projects.
29
29
 
30
30
  Documentation
31
31
  -------------
32
32
 
33
- Documentation for this project is hosted on
33
+ Documentation and other links for this project are hosted on
34
34
  `GitHub Pages
35
- <https://grscheller.github.io/pythonic-fp/fptools/development/build/html>`_.
35
+ <https://grscheller.github.io/pythonic-fp/projects/fptools.html>`_.
36
36
 
37
37
  Copyright and License
38
38
  ---------------------
39
39
 
40
- Copyright (c) 2023-2025 Geoffrey R. Scheller. Licensed under the Apache
40
+ Copyright (c) 2023-2026 Geoffrey R. Scheller. Licensed under the Apache
41
41
  License, Version 2.0. See the LICENSE file for details.
@@ -0,0 +1,78 @@
1
+ # Makefile for Sphinx documentation
2
+
3
+ # Last and future releases
4
+ # - former needs to agree with PyPI
5
+ # - later needs to agree with pyproject.toml
6
+ PROJECT_NAME = FP Tools Array
7
+ PYPI_NAME = fptools
8
+ RELEASE_VERSION = 5.3.0
9
+ DEVEL_VERSION = 5.3.0
10
+ CUSTOM_VERSION = 0.0.0
11
+
12
+ SPHINXOPTS ?=
13
+ SPHINXBUILD ?= sphinx-build
14
+ SOURCEDIR = source
15
+ BUILDDIR = build
16
+
17
+ STATICDIR = source/_static
18
+ TEMPLATEDIR = source/_templates
19
+
20
+ # Put help first so that "make" without argument is like "make help".
21
+ help:
22
+ @$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS)
23
+
24
+ clean_source:
25
+ @rm -f "$(SOURCEDIR)"/conf.py
26
+
27
+ clean_devel:
28
+ @rm -rf "$(BUILDDIR)"/development
29
+
30
+ clean_release:
31
+ @rm -rf "$(BUILDDIR)"/release
32
+
33
+ clean_custom:
34
+ @rm -rf "$(BUILDDIR)"/custom
35
+
36
+ clean: clean_devel clean_release clean_custom clean_source
37
+ @rm -rf $(BUILDDIR)
38
+ @echo Removed all doc build artifacts.
39
+
40
+ setup_devel: clean_devel
41
+ @./gen_conf.py devel "$(DEVEL_VERSION)" "$(PROJECT_NAME)" "$(PYPI_NAME)" > "$(SOURCEDIR)"/conf.py
42
+
43
+ setup_release: clean_release
44
+ @./gen_conf.py release "$(RELEASE_VERSION)" "$(PROJECT_NAME)" "$(PYPI_NAME)" > "$(SOURCEDIR)"/conf.py
45
+
46
+ setup_custom: clean_custom
47
+ @./gen_conf.py custom "$(CUSTOM_VERSION)" "$(PROJECT_NAME)" "$(PYPI_NAME)" > "$(SOURCEDIR)"/conf.py
48
+
49
+ setup_redo: clean_custom
50
+ @echo Redoing custom build with a possibly reeditted conf.py
51
+ @./gen_conf.py redo "" "" ""
52
+
53
+ # Build development labeled html docs.
54
+ devel: Makefile setup_devel
55
+ @$(SPHINXBUILD) -M html "$(SOURCEDIR)" "$(BUILDDIR)"/development $(SPHINXOPTS)
56
+
57
+ # Build release labeled html docs.
58
+ release: Makefile setup_release
59
+ @$(SPHINXBUILD) -M html "$(SOURCEDIR)" "$(BUILDDIR)"/release $(SPHINXOPTS)
60
+
61
+ # Build custom labeled html docs.
62
+ custom: Makefile setup_custom
63
+ @$(SPHINXBUILD) -M html "$(SOURCEDIR)" "$(BUILDDIR)"/custom $(SPHINXOPTS)
64
+
65
+ # Build HTML docs with previous generated (possibly hand edited) source/conf.py,
66
+ # put results in $(BUILDDIR)/custom.
67
+ redo: Makefile setup_redo
68
+ @$(SPHINXBUILD) -M html "$(SOURCEDIR)" "$(BUILDDIR)"/custom $(SPHINXOPTS)
69
+
70
+ # Catch-all target: route all unknown targets to Sphinx and save to $(BUILDDIR)/custom.
71
+ # Reuse a previously generated source/conf.py.
72
+ %: Makefile setup_redo
73
+ @$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)"/custom $(SPHINXOPTS)
74
+
75
+ .PHONY: help Makefile
76
+ .PHONY: setup_devel setup_release setup_custom
77
+ .PHONY: devel release
78
+ .PHONY: clean_source clean_devel clean_release clean_custom clean
@@ -0,0 +1,109 @@
1
+ #!/usr/bin/env python
2
+ # Generate conf.py Sphinx configuration executable
3
+
4
+ import sys
5
+ import os
6
+
7
+ project_prefix = 'Pythonic FP'
8
+ pypi_prefix = 'pythonic-fp'
9
+ author = 'Geoffrey R. Scheller'
10
+ copyright = f'2023-2026, {author}'
11
+
12
+ args = sys.argv[1:]
13
+ num_args = len(args)
14
+
15
+ if num_args == 4:
16
+ build_type, version, project_name, pypi_name = args
17
+ project = project_prefix + ' - ' + project_name
18
+ pypi_project_repo = pypi_prefix + '-' + pypi_name
19
+ project_url_rst = f'`{project} <https://pypi.org/project/{pypi_project_repo}/>`_'
20
+ homepage_url_rst = f'`{project_prefix} <https://grscheller.github.io/{pypi_prefix}/>`_'
21
+
22
+ else:
23
+ sys.exit('Error: gen_conf.py takes exactly 4 arguments')
24
+
25
+ match build_type:
26
+ case 'custom':
27
+ release = f'{version}'
28
+ release_string = f'**Custom PyPI Non-release version {release}**'
29
+ case 'devel':
30
+ release = f'{version}'
31
+ release_string = f'**Proposed PyPI release version {release}**'
32
+ case 'release':
33
+ release = f'{version}'
34
+ release_string = f'**PyPI release version {release}**'
35
+ case 'redo':
36
+ if not os.path.isfile('source/conf.py'):
37
+ sys.exit('Error: cannot redo without source/conf.py')
38
+ sys.exit()
39
+ case _:
40
+ sys.exit(f'Error: unknown built_type {build_type} given')
41
+
42
+ print(f'''# Generated conf.py Sphinx configuration executable
43
+
44
+ from typing import Any
45
+ from sphinx.application import Sphinx
46
+
47
+ project = '{project}'
48
+ author = '{author}'
49
+ copyright = '{copyright}'
50
+ release = '{release}'
51
+ release_string = '{release_string}'
52
+
53
+ def skip_abc_methods(
54
+ app: Any, what: str, name: str, obj: Any, skip: bool, options: Any
55
+ ) -> bool:
56
+ if name in [
57
+ '__init_subclass__',
58
+ '__subclasshook__',
59
+ '__class_getitem__',
60
+ '__weakref__',
61
+ ]:
62
+ return True # Skip these members
63
+ return skip
64
+
65
+
66
+ def setup(app: Sphinx) -> None:
67
+ app.connect('autodoc-skip-member', skip_abc_methods)
68
+
69
+
70
+ extensions = [
71
+ 'sphinx.ext.autodoc',
72
+ 'sphinx.ext.graphviz',
73
+ ]
74
+
75
+ autodoc_default_options = {{
76
+ 'members': True,
77
+ 'private-members': True,
78
+ 'special-members': True,
79
+ 'inherited-members': False,
80
+ 'show-inheritance': True,
81
+ }}
82
+ autodoc_member_order = 'bysource'
83
+ autoclass_content = 'class'
84
+ autodoc_class_signature = 'separated'
85
+ autodoc_typehints_format = 'short'
86
+ autodoc_use_type_comments = True
87
+ autodoc_docstring_signature = False
88
+ autodoc_preserve_defaults = True
89
+ autodoc_warningiserror = False
90
+
91
+ templates_path = ['_templates']
92
+ exclude_patterns: list[str] = []
93
+
94
+ html_theme_options = {{
95
+ 'light_css_variables': {{
96
+ 'color-link--visited': 'var(--color-link)',
97
+ }},
98
+ 'dark_css_variables': {{
99
+ 'color-link--visited': 'var(--color-link)',
100
+ }},
101
+ }}
102
+ html_theme = 'furo'
103
+ html_static_path = ['_static']
104
+
105
+ rst_epilog = """
106
+ .. |RELEASE_STRING| replace:: {release_string}
107
+
108
+ """
109
+ ''')
@@ -0,0 +1,2 @@
1
+ sphinx>=9.1
2
+ furo
@@ -0,0 +1,6 @@
1
+ function
2
+ ========
3
+
4
+ .. automodule:: pythonic_fp.fptools.function
5
+ :members:
6
+ :special-members:
@@ -0,0 +1,20 @@
1
+ FP Tools
2
+ ========
3
+
4
+ .. toctree::
5
+ :caption: Function manipulation
6
+ :maxdepth: 1
7
+
8
+ function
9
+
10
+ .. toctree::
11
+ :caption: Lazy function evaluation
12
+ :maxdepth: 1
13
+
14
+ lazy
15
+
16
+ .. toctree::
17
+ :caption: Monads
18
+ :maxdepth: 2
19
+
20
+ monads/index
@@ -0,0 +1,6 @@
1
+ lazy
2
+ ====
3
+
4
+ .. automodule:: pythonic_fp.fptools.lazy
5
+ :members:
6
+ :special-members:
@@ -0,0 +1,6 @@
1
+ either monad
2
+ ============
3
+
4
+ .. automodule:: pythonic_fp.fptools.either
5
+ :members:
6
+ :special-members:
@@ -0,0 +1,10 @@
1
+ Monads
2
+ ======
3
+
4
+ .. toctree::
5
+ :caption: Monads
6
+ :maxdepth: 2
7
+
8
+ maybe
9
+ either
10
+ state
@@ -0,0 +1,6 @@
1
+ maybe monad
2
+ ===========
3
+
4
+ .. automodule:: pythonic_fp.fptools.maybe
5
+ :members:
6
+ :special-members:
@@ -0,0 +1,6 @@
1
+ state monad
2
+ ===========
3
+
4
+ .. automodule:: pythonic_fp.fptools.state
5
+ :members:
6
+ :special-members:
@@ -0,0 +1,7 @@
1
+ Changelog
2
+ =========
3
+
4
+ Change log for the
5
+ `pythonic-fp-fptools
6
+ <https://github.com/grscheller/pythonic-fp-fptools/blob/main/CHANGELOG.rst>`_
7
+ PyPI project.
@@ -0,0 +1,8 @@
1
+ Description
2
+ -----------
3
+
4
+ .. automodule:: pythonic_fp.fptools
5
+ :no-members:
6
+ :ignore-module-all:
7
+ :no-index:
8
+