Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
281 commits
Select commit Hold shift + click to select a range
a527fb0
Add test for helpers.
led02 Aug 1, 2025
2fbe1e0
Using mock_document for setup.
led02 Aug 1, 2025
e362b15
Remove test for pyld internals.
led02 Aug 1, 2025
8b2e59f
Switch test to use mock_context from helpers.
led02 Aug 1, 2025
4b8c3b7
Added more tests.
led02 Aug 1, 2025
3bceb49
Restructured tests for ld_container (type conversions).
led02 Aug 1, 2025
ef2eb70
Update poetry lock to get CI running.
led02 Aug 1, 2025
af21ace
Fix linting errors.
led02 Aug 1, 2025
8b4f9a3
Delete tests for old data model.
led02 Aug 1, 2025
d825217
Disable tests that fail due to missing old data model.
led02 Aug 1, 2025
d9761ab
Fix test for mock document.
led02 Aug 1, 2025
9113c7b
Fix mock document.
led02 Aug 1, 2025
df5b0ef
Silence flake8 on inactive tests.
led02 Aug 1, 2025
4fe4ffb
Silence flake8 on inactive tests more agressively.
led02 Aug 1, 2025
797ded3
Fix handling of identifier in compaction and expansion.
led02 Aug 1, 2025
026b09f
Disable tests that fail due to missing old data model.
led02 Aug 1, 2025
b347dc2
Silence flake8 on inactive tests.
led02 Aug 1, 2025
7a2b0d6
Silence flake8 on inactive tests more agressively.
led02 Aug 1, 2025
d577aab
Revert "Silence flake8 on inactive tests more agressively."
led02 Aug 1, 2025
b432ccf
Revert "Silence flake8 on inactive tests."
led02 Aug 1, 2025
6a10129
Revert "Disable tests that fail due to missing old data model."
led02 Aug 1, 2025
82b45e5
Delete tests for old data model.
led02 Aug 1, 2025
de09fdb
Revert "Delete tests for old data model."
led02 Aug 1, 2025
158c8d3
Merge branch 'feature/347-update-build_backend' into refactor/data-model
sdruskat Aug 5, 2025
73df3ea
Merge pull request #417 from softwarepub/refresh-based-on-develop
sdruskat Aug 5, 2025
6bcdbe9
Show skipped tests when running
sdruskat Aug 5, 2025
80cade3
Merge pull request #415 from softwarepub/refactor/411-disable-tests
sdruskat Aug 5, 2025
7b10cdc
Merge pull request #403 from softwarepub/refactor/383-test-ld_context
sdruskat Aug 5, 2025
0edc582
Merge remote-tracking branch 'origin/refactor/data-model' into refact…
led02 Aug 5, 2025
68aec7f
Update poetry.lock for added test dependencies.
led02 Aug 5, 2025
ea08105
Add missing dependencies again.
led02 Aug 5, 2025
409b43a
Add test file for `ld_dict`
sdruskat Aug 1, 2025
6c7baf8
Merge branch 'refactor/data-model' into refactor/384-test-ld_dict
sdruskat Aug 7, 2025
2969b09
Merge pull request #398 from softwarepub/refactor/381-test-ld_container
SKernchen Aug 7, 2025
0193974
Merge pull request #414 from softwarepub/refactor/412-fix-id-issues
SKernchen Aug 7, 2025
79ffbc6
Fix typos in docstring
sdruskat Aug 7, 2025
f869336
Merge branch 'refactor/data-model' into refactor/372-test-pyld-util
Aug 7, 2025
bb7741b
Add missing license header
Aug 7, 2025
78af0b5
Use correct field name in tests
sdruskat Aug 7, 2025
c1a0448
Fix KeyError and first Tests for ld_list
Aug 7, 2025
4cb2af0
Mark test as expectedly failing due to #419
sdruskat Aug 7, 2025
32c41f1
Make passing xfail tests fail test suite
sdruskat Aug 7, 2025
9e7ecf5
Mark another test as expectedly failing due to #419
sdruskat Aug 7, 2025
d4e2366
Parametrize xfailing test getting CodeMeta items, re-format
sdruskat Aug 7, 2025
1f4501c
Test correct inputs for getting expanded terms from prefixed vocabula…
sdruskat Aug 7, 2025
5512f7e
Test raises when prefix doesn't exist for compacted input
sdruskat Aug 7, 2025
3262691
Test raises when term doesn't exist for compacted input
sdruskat Aug 7, 2025
241f914
Remove duplicate tests, and not-to-be-tested parameters
sdruskat Aug 7, 2025
ebe9200
Improve reporting unexpected exceptions and add tests for expanded in…
sdruskat Aug 7, 2025
de0f24a
Add test for unimplemented and undecided functionality
sdruskat Aug 7, 2025
3793e7c
Report unexpectedly raised exception
sdruskat Aug 7, 2025
586201e
Rename module to match hermes.error
sdruskat Aug 7, 2025
e99d930
Define context error, fix bad naming
sdruskat Aug 7, 2025
0260ab5
Rename error (add prefix)
sdruskat Aug 7, 2025
ad4221b
Merge branch 'refactor/define-model-errors' into refactor/384-mark-ex…
sdruskat Aug 7, 2025
6c4a523
Raise new error when getting term whose prafix is not in context
sdruskat Aug 7, 2025
1242311
Test that non-existent prefix raises error on getting item
sdruskat Aug 7, 2025
9621e77
Add xfailing test for returning only existing terms from given vocabu…
sdruskat Aug 7, 2025
9a980b4
Test raising context errors where implemented
sdruskat Aug 7, 2025
b808152
Raise context error on empty string, reformat
sdruskat Aug 7, 2025
0d61163
Pacify flake8
sdruskat Aug 7, 2025
e9ca175
Satisfy REUSE
sdruskat Aug 7, 2025
629bec9
Merge pull request #420 from softwarepub/refactor/define-model-errors
sdruskat Aug 7, 2025
9109d52
wrote first testsfor ld_dict
Sep 3, 2025
4fd198f
added missing dependency
Sep 4, 2025
0c4a500
added more tests
Sep 4, 2025
75f2b66
added two more test cases
Sep 4, 2025
0ca9af4
fixed small bug
Sep 4, 2025
f3133e8
added tests for ld_list
Sep 5, 2025
71a5f87
fixed bug in __getitem__
Sep 5, 2025
23eda6c
added support for slices and fixed bug in __setitem__
Sep 5, 2025
562f3bf
linted ld_list.py and test_ld_list.py
Sep 5, 2025
2679a0a
added more tests
Sep 5, 2025
1da06c3
fixed small bug in __iter__ of ld_list
Sep 5, 2025
8975cf9
added FIXME and linted test_ld_list.py
Sep 5, 2025
f29875b
added tests and adjusted some according to what was discussed in a me…
Sep 9, 2025
76a93b2
added check to __init__ of ld_dict
Sep 9, 2025
af19fcc
suggested fix for nested conversions
Sep 9, 2025
f4621ab
fixed formatting mistakes
Sep 9, 2025
da2f010
added a fixme comment
Sep 9, 2025
d822fb5
added some edge cases to the tests
Sep 9, 2025
4c1631d
Merge branch 'refactor/data-model' into refactor/384-test-ld_dict
sdruskat Sep 9, 2025
1feddda
Add basic implementation of API class
sdruskat Sep 9, 2025
74ba45d
Test initialization of API class
sdruskat Sep 9, 2025
e709d6f
added fixme comments and two test cases and removed unused pytest marker
Sep 10, 2025
88fd409
adjusted tests and ld_list as ld_list.itemlist should be expanded jso…
Sep 10, 2025
63de367
added more fixme comments and test cases
Sep 10, 2025
99571c5
added (all) missing kw args to __init__.py (#364)
Sep 11, 2025
4dce650
added fixme string
Sep 12, 2025
29f0a8a
removed false/ unnecessary fixme
Sep 12, 2025
79575b8
Test API object initiatlization with and without data
sdruskat Sep 17, 2025
69f6a24
Test API object initialization with nested object
sdruskat Sep 17, 2025
8e1a38b
Test appending objects to model via API
sdruskat Sep 17, 2025
b65989e
Test model building via API object
sdruskat Sep 17, 2025
a08eaf2
Correct context parameter to list
Sep 18, 2025
c6fab45
Fixes test input format and describes all problems
SKernchen Sep 24, 2025
fce1519
added another case for testing of get and added the issue number to a…
Sep 25, 2025
59180c7
added an add method to SoftwareMetadata and improved __init__ of it a…
Sep 25, 2025
daed5d3
Change existing test to assume returned lists
sdruskat Sep 26, 2025
4583915
Add test for harvesting case
sdruskat Sep 26, 2025
6808272
Add more comprehensive usage test
sdruskat Sep 26, 2025
2f7eadf
Add new license annotation for Python files
sdruskat Sep 26, 2025
0f32494
changed conversions of types to output ld_lists for every item in a dict
Sep 26, 2025
8298e49
added some tests for the conversions and formated to satisfy flake8
Sep 26, 2025
3a8bfbe
added three more conversions for container to expanded json
Sep 26, 2025
2ef89d3
always return a list when getting an item from ld_dict
Sep 26, 2025
2db93cf
added tests and fixed issues
Sep 26, 2025
f38b662
changed type conversions as discussed in #423 and #433 and tweaked th…
Sep 26, 2025
1721325
clean up
Oct 2, 2025
1ecd0f8
suggestion for fix of #435
Oct 2, 2025
1fb7574
Comment out local extension that breaks build
sdruskat Oct 2, 2025
8d147a8
Document data model API
sdruskat Oct 2, 2025
7e1ac64
Update dependency lock
sdruskat Oct 2, 2025
5fde82a
added contains and equals check for ld_list with tests and added issu…
Oct 6, 2025
9be8041
removed tests of unclear matters (@type and @context fields) and adde…
Oct 6, 2025
c34fc81
Merge branch 'refactor/data-model' into refactor/384-test-ld_dict
SKernchen Oct 10, 2025
39d25e9
Merge pull request #410 from softwarepub/refactor/384-test-ld_dict
SKernchen Oct 10, 2025
dd854c7
Track data in model in simplified form
sdruskat Oct 17, 2025
f4c1e7d
Link to dummy section
sdruskat Oct 17, 2025
97ebad4
Make tone less intimidating, more neutral/positive
sdruskat Oct 17, 2025
da136c3
changed ld_list according to issue #439
Oct 17, 2025
03ebd32
implemented tests for problem 2 of the issue and more tests
Oct 20, 2025
d1eb612
added a few missing conversions and formatted the file a little bit d…
Oct 20, 2025
d28dc10
removed one conversion, added one and changed _to_python to fix conve…
Oct 20, 2025
fb5aa64
fixed formatting errors
Oct 20, 2025
5248853
fixed ld_container tests, a type conversion and equals of ld_list
Oct 24, 2025
c233573
First tests for ld_proc
SKernchen Oct 24, 2025
d5f64e1
Happy case test jsonldproc
SKernchen Nov 7, 2025
e2c1bba
added detailed comparison for ld_list, ld_dict and json_values and ad…
Nov 7, 2025
aeb88fb
added support for graph and set again and improved expansion of json-ld
Nov 21, 2025
007e3a3
removed unnecessary lambda
Nov 21, 2025
a68f2ae
Add test file
sdruskat Nov 21, 2025
3c9ea61
fixed set and from_list and added del
Nov 21, 2025
66e03df
updated tests of ld_container and fixed found bugs
Nov 21, 2025
c4aea65
pacified flake8
Nov 21, 2025
7d30b16
improved ld_list.__contains__ and added tests for it
Nov 24, 2025
f8d259f
added one TODO item to ld_list
Nov 24, 2025
2b98627
began adding doc strings, type hints and comments for ld_container
Nov 24, 2025
1958518
improved _to_expanded_json
Nov 28, 2025
4acf8de
added doc-strings and comments and pacified flake8
Nov 28, 2025
b751130
began commenting and adding doc-strings to ld_list
Nov 28, 2025
3c243f2
fixed bug in _to_expanded_json
Dec 5, 2025
e0f0fc9
added a few test cases to delete of ld_list
Dec 5, 2025
1b5656e
added more comments to ld_list
Dec 5, 2025
071630c
added more doc strings
Dec 5, 2025
d4b34b4
corrected type hints
Dec 8, 2025
f0f1818
documented the rest of the methods in ld_container
Dec 8, 2025
460e3d4
Merge pull request #374 from softwarepub/refactor/372-test-pyld-util
SKernchen Dec 12, 2025
c72353e
Merge branch 'refactor/data-model' into refactor/384-mark-expected-fa…
SKernchen Dec 12, 2025
e86d5fe
Merge pull request #421 from softwarepub/refactor/384-mark-expected-f…
SKernchen Dec 12, 2025
bcc233d
implemented list comparison and added tests for it
Dec 12, 2025
287d37a
added tests and fixed small bug and fixed typos
Dec 15, 2025
5f2214e
Merge pull request #445 from softwarepub/refactor/439-restrict-ld_list
SKernchen Dec 19, 2025
14868ad
Merge branch 'refactor/data-model' into refactor/385-test-ld_list
notactuallyfinn Dec 19, 2025
20fbefc
fixed ld_dict tests
Dec 19, 2025
504a345
removed unnecessary fixme
Dec 19, 2025
0999f44
Delete deprecated function
SKernchen Dec 19, 2025
6bc1648
Merge pull request #418 from softwarepub/refactor/385-test-ld_list
SKernchen Dec 19, 2025
7adb02f
Merge branch 'refactor/data-model' into refactor/423-implement-public…
SKernchen Dec 19, 2025
6f039e8
slightly adjusted tests and fixed miniature bugs in ld_container and …
Dec 19, 2025
c2b9c4f
cleaned up __init__.py
Jan 5, 2026
bd1a19f
ran 'poetry lock'
Jan 5, 2026
9527e26
updated type hints to be supported by python 3.10
Jan 5, 2026
97d9d95
update type hints and began commenting ld_dict
Jan 5, 2026
cd6e3d5
added and updated comments
Jan 9, 2026
95288a2
added first e2e harvest test for SoftwareMetadata
Jan 12, 2026
de457e3
Apply Style Changes (Author names instead of foo etc.)
SKernchen Jan 13, 2026
e9d010f
Correct lower letters for emails
SKernchen Jan 13, 2026
23ec20c
Merge branch 'refactor/423-implement-public-api' into refactor/423-im…
SKernchen Jan 13, 2026
8ace58c
Merge pull request #438 from softwarepub/refactor/423-implement-publi…
SKernchen Jan 13, 2026
605201d
fixed small bug in set_item of ld_dict
Jan 16, 2026
4920090
added more tests
Jan 16, 2026
38ef40e
refactored end to end tests
Jan 16, 2026
eb6f587
Fix compact_iri for schema elements with containers
SKernchen Jan 16, 2026
ddcd26a
updated creation of SoftwareMetadata objects in e2e tests
Jan 19, 2026
9b44b53
added tests and support for curate step
Jan 19, 2026
6c3ba13
started to add support for deposit step and added useful method for S…
Jan 19, 2026
0284b01
Correct Docs for newer functionality
SKernchen Jan 20, 2026
d46394e
Correct type of value
SKernchen Jan 23, 2026
feeb16b
worked on invenio deposit
Jan 23, 2026
4f6cc9d
Merge branch 'refactor/data-model' into feature/454-e2e-deposit
Jan 26, 2026
ed0916b
fixed bugs in invenio.py
Jan 26, 2026
382e2c3
fixed bug and adjusted tests
Jan 30, 2026
96861ec
adjusted invenio.py and its test a bit
Feb 2, 2026
4887eae
Merge pull request #432 from softwarepub/refactor/423-implement-publi…
SKernchen Feb 6, 2026
248ae33
added adjusted files from feature/153-refactor-datamodel for process
Feb 6, 2026
ebebca4
added first tests
Feb 6, 2026
f21df49
(re)added version and help commands to the available commands
Feb 9, 2026
d4d9ca8
made test for process step more complex
Feb 9, 2026
7cfa7bc
made process step and ld_container._to_expanded_json more robust
Feb 9, 2026
520ef39
improved flake8 rating
Feb 9, 2026
8606933
Merge branch 'refactor/423-implement-public-api' into feature/454-e2e…
SKernchen Feb 13, 2026
d04b0e2
Remove SysExit call
SKernchen Feb 13, 2026
13a0952
Fix typo
SKernchen Feb 13, 2026
bcdc821
added lots of comments and fixed small inconsistencies
Feb 13, 2026
1c10dca
added coments and fix small bug
Feb 27, 2026
aa4284e
removed unnecessary print statements
Feb 27, 2026
4080091
json_ids are now returned as ld_dicts instead of the id string
Mar 3, 2026
b7543ee
reworked merging and added strategies
Mar 5, 2026
08619ee
fixed formation errors
Mar 5, 2026
ac36a28
updated strategies and match functions
Mar 6, 2026
3291c4d
formatting and doc strings
Mar 9, 2026
7365526
Merge branch 'feature/454-e2e-test-plugin-api' into feature/454-e2e-c…
notactuallyfinn Mar 9, 2026
62f1345
Merge pull request #468 from softwarepub/feature/454-e2e-curate
notactuallyfinn Mar 9, 2026
1e781ca
fixed mistake in merge
Mar 9, 2026
2878155
Merge pull request #470 from softwarepub/feature/454-e2e-process
notactuallyfinn Mar 9, 2026
57cdfb0
Merge branch 'feature/454-e2e-test-plugin-api' into feature/454-e2e-d…
notactuallyfinn Mar 9, 2026
e5065c2
Merge pull request #469 from softwarepub/feature/454-e2e-deposit
notactuallyfinn Mar 9, 2026
0e8b49c
fixed minor bugs
Mar 9, 2026
bd7e732
adapted postprocess and added test
Mar 10, 2026
a30d385
changed imports and fixed syntax error for python 3.10
Mar 11, 2026
50c58d3
Merge pull request #475 from softwarepub/feature/454-e2e-postprocess
notactuallyfinn Mar 11, 2026
230ee05
fixed syntax error and added lost dependency
Mar 11, 2026
1fcbb4b
adjusted comments and config for doc build to try get it running
Mar 11, 2026
65f3d10
tweeked documentation a bit
Mar 13, 2026
4f3372c
tweeked documentation of ld_list
Mar 13, 2026
45459fc
improved comments for ld_dict
Mar 13, 2026
8afb37b
split test_api_e2e.py into multiple files
Mar 13, 2026
4a08fbe
added and updated comments
Mar 13, 2026
1d1c18d
commented the rest of the new files
Mar 16, 2026
02340e0
added support for user defined merge strategies
Mar 16, 2026
5e296cb
added class to ignore list for autoapi
Mar 18, 2026
630dd00
updated documentation for plugin development, made curate pluginizabl…
Mar 19, 2026
296fbb7
fixed formatting errors
Mar 19, 2026
758dbde
reactivated tests and added afew log calls
Mar 20, 2026
7de8c7d
applied simple suggestions
Mar 20, 2026
ad63e5a
fixed misspelled class name
Mar 23, 2026
7a8e8ae
implemented suggestions and fixed bug
Mar 23, 2026
9d3dc7f
added test_case and generate strategies automatically
Mar 25, 2026
c699ae2
finished implementation of CodemetaProcessPlugin
Mar 26, 2026
d514c9f
implement more comments
Mar 26, 2026
ba8b549
add codemeta_doi postprocess plugin
Mar 26, 2026
9b1c48a
reworked zenodo_sandbox_auth for cli testing
Mar 26, 2026
55e086d
fix post process and add license header to conftest.py
Mar 26, 2026
9d770a1
improve error handling of commands
Mar 26, 2026
180cc10
make process more verbose for errors while merging
Mar 26, 2026
0251cd1
potentially fixed error where multiple record ids are halucinated.
Mar 26, 2026
73467f5
flake8
Mar 26, 2026
34877b9
adjusted logging a bit
Mar 27, 2026
a0c0005
fix tests that are affected by error handling update
Mar 27, 2026
279e672
added another process test and fixed small bug
Mar 27, 2026
65399be
flake8
Mar 27, 2026
89191ec
Imporve first cli harvest tests
SKernchen Apr 13, 2026
a42c315
add reject strategies for special properties
Apr 13, 2026
9294d0a
Add good case tests for cli
SKernchen Apr 22, 2026
e40965d
Merge pull request #456 from softwarepub/feature/454-e2e-test-plugin-api
SKernchen Apr 22, 2026
5108696
Ignore flake8 C901 (too complex)
SKernchen Apr 22, 2026
224d5b7
Merge pull request #479 from softwarepub/refactor/423-implement-publi…
SKernchen Apr 22, 2026
3e7c83d
update dependencies
Apr 23, 2026
23a11b3
add/ update comments and doc strings
Apr 23, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
359 changes: 359 additions & 0 deletions LICENSES/CC-BY-SA-3.0.txt

Large diffs are not rendered by default.

17 changes: 17 additions & 0 deletions LICENSES/W3C-20150513.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
This work is being provided by the copyright holders under the following license.

License
By obtaining and/or copying this work, you (the licensee) agree that you have read, understood, and will comply with the following terms and conditions.

Permission to copy, modify, and distribute this work, with or without modification, for any purpose and without fee or royalty is hereby granted, provided that you include the following on ALL copies of the work or portions thereof, including modifications:

• The full text of this NOTICE in a location viewable to users of the redistributed or derivative work.
• Any pre-existing intellectual property disclaimers, notices, or terms and conditions. If none exist, the W3C Software and Document Short Notice should be included.
• Notice of any changes or modifications, through a copyright statement on the new code or document such as "This software or document includes material copied from or derived from [title and URI of the W3C document]. Copyright (c) [YEAR] W3C® (MIT, ERCIM, Keio, Beihang)."

Disclaimers
THIS WORK IS PROVIDED "AS IS," AND COPYRIGHT HOLDERS MAKE NO REPRESENTATIONS OR WARRANTIES, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO, WARRANTIES OF MERCHANTABILITY OR FITNESS FOR ANY PARTICULAR PURPOSE OR THAT THE USE OF THE SOFTWARE OR DOCUMENT WILL NOT INFRINGE ANY THIRD PARTY PATENTS, COPYRIGHTS, TRADEMARKS OR OTHER RIGHTS.

COPYRIGHT HOLDERS WILL NOT BE LIABLE FOR ANY DIRECT, INDIRECT, SPECIAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF ANY USE OF THE SOFTWARE OR DOCUMENT.

The name and trademarks of copyright holders may NOT be used in advertising or publicity pertaining to the work without specific, written prior permission. Title to copyright in this work will at all times remain with copyright holders.
6 changes: 6 additions & 0 deletions REUSE.toml
Original file line number Diff line number Diff line change
Expand Up @@ -17,3 +17,9 @@ path = ["REUSE.toml"]
precedence = "aggregate"
SPDX-FileCopyrightText = "German Aerospace Center (DLR), Helmholtz-Zentrum Dresden-Rossendorf, Forschungszentrum Jülich"
SPDX-License-Identifier = "CC0-1.0"

[[annotations]]
path = ["src/**/*.py", "test/**/*.py"]
precedence = "aggregate"
SPDX-FileCopyrightText = "German Aerospace Center (DLR), Helmholtz-Zentrum Dresden-Rossendorf, Forschungszentrum Jülich"
SPDX-License-Identifier = "Apache-2.0"
9 changes: 9 additions & 0 deletions conftest.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
# SPDX-FileCopyrightText: 2026 German Aerospace Center (DLR)
#
# SPDX-License-Identifier: Apache-2.0

# SPDX-FileContributor: Michael Fritzsche

# add option to pass zenodo sandbox auth token to pytest to run ./test/hermes_test/commands/deposit/test_invenio_e2e.py
def pytest_addoption(parser):
parser.addoption("--sandbox_auth", action="store", default=None)
33 changes: 33 additions & 0 deletions docs/source/_static/custom.css
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@

/*
* SPDX-FileContributor: Oliver Bertuch
* SPDX-FileContributor: Michael Fritzsche
*/

img.member {
Expand All @@ -22,4 +23,36 @@ img.badge-icon {
img.member {
max-width: 23%;
}
}

img {
display: block;
margin: auto;
}

.bd-page-width {
max-width: none !important;
}

@media (min-width: 1200px) {
.bd-article-container {
max-width: none !important;
}
}

.bd-article-container {
max-width: 100%;
}

.bd-sidebar-primary.bd-sidebar {
max-width: min-content;
}

.bd-docs-nav {
min-width: max-content;
}

.bd-sidebar-secondary{
max-width: 15%;
width: max-content;
}
27 changes: 24 additions & 3 deletions docs/source/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ def read_from_pyproject(file_path="../../pyproject.toml"):
data = toml.load(file_path)

# Navigate to the authors metadata
metadata = data.get("tool", {}).get("poetry", {})
metadata = data.get("project", {})
if not metadata:
return "No metadata found in pyproject.toml"
return metadata
Expand All @@ -56,7 +56,7 @@ def read_authors_from_pyproject():
if not authors:
return "No authors metadata found in pyproject.toml"
# Convert the list of authors to a comma-separated string
return ", ".join([a.split(" <")[0] for a in authors])
return ", ".join([author["name"] for author in authors])

def read_version_from_pyproject():
metadata = read_from_pyproject()
Expand All @@ -73,7 +73,7 @@ def read_version_from_pyproject():
author = read_authors_from_pyproject()

# The full version, including alpha/beta/rc tags
release = read_version_from_pyproject()
version = release = read_version_from_pyproject()


# -- General configuration ---------------------------------------------------
Expand Down Expand Up @@ -131,6 +131,9 @@ def read_version_from_pyproject():
autoapi_dirs = ["../../src"]
autoapi_root = "api"
autoapi_ignore = ["*__main__*"]
autoapi_options = [
"members", "undoc-members", "private-members", "special-members", "show-inheritance", "show-module-summary"
]

# -- Options for HTML output -------------------------------------------------

Expand Down Expand Up @@ -161,6 +164,7 @@ def read_version_from_pyproject():
"repository_url": "https://github.com/hermes-hmc/hermes",
"use_repository_button": True,
"navigation_with_keys": False,
"max_navbar_depth": -1
}

html_css_files = [
Expand All @@ -182,3 +186,20 @@ def read_version_from_pyproject():
# -- Options for sphinx-togglebutton -----------------------------------------

togglebutton_hint = "Click to show screenshot"


# TODO: remove this workaround and remove "undoc-members" from autoapi_options once everything is documented
# This removes all generated entries for known documented classes (because autoapi will add all attributes
# it finds in the code no matter if they are described in a class doc string or not).
def autoapi_skip_member(app, obj_type, name, obj, skip, options):
if obj_type == "attribute":
if any(documented_type in obj.id for documented_type in [
"Collect", "HermesCache", "HermesContext", "HermesMergeError", "ld_container", "ld_context", "ld_dict",
"ld_list", "ld_merge_dict", "ld_merge_list", "MergeSet"
]):
return True

return skip

def setup(app):
app.connect("autoapi-skip-member", autoapi_skip_member)
Loading
Loading