diff --git a/docs/api/datastore/stix2.datastore.filesystem.rst b/docs/api/datastore/stix2.datastore.filesystem.rst index 2b0d2ee..665df66 100644 --- a/docs/api/datastore/stix2.datastore.filesystem.rst +++ b/docs/api/datastore/stix2.datastore.filesystem.rst @@ -2,4 +2,4 @@ filesystem ========================== .. automodule:: stix2.datastore.filesystem - :members: + :members: \ No newline at end of file diff --git a/docs/api/datastore/stix2.datastore.filters.rst b/docs/api/datastore/stix2.datastore.filters.rst index 3c9f0b1..b556754 100644 --- a/docs/api/datastore/stix2.datastore.filters.rst +++ b/docs/api/datastore/stix2.datastore.filters.rst @@ -2,4 +2,4 @@ filters ======================= .. automodule:: stix2.datastore.filters - :members: + :members: \ No newline at end of file diff --git a/docs/api/datastore/stix2.datastore.memory.rst b/docs/api/datastore/stix2.datastore.memory.rst index eda42cb..b0521c7 100644 --- a/docs/api/datastore/stix2.datastore.memory.rst +++ b/docs/api/datastore/stix2.datastore.memory.rst @@ -2,4 +2,4 @@ memory ====================== .. automodule:: stix2.datastore.memory - :members: + :members: \ No newline at end of file diff --git a/docs/api/datastore/stix2.datastore.taxii.rst b/docs/api/datastore/stix2.datastore.taxii.rst index f1c43bf..68389a0 100644 --- a/docs/api/datastore/stix2.datastore.taxii.rst +++ b/docs/api/datastore/stix2.datastore.taxii.rst @@ -2,4 +2,4 @@ taxii ===================== .. automodule:: stix2.datastore.taxii - :members: + :members: \ No newline at end of file diff --git a/docs/api/equivalence/stix2.equivalence.pattern.rst b/docs/api/equivalence/stix2.equivalence.pattern.rst index 5246ed2..d11e9ce 100644 --- a/docs/api/equivalence/stix2.equivalence.pattern.rst +++ b/docs/api/equivalence/stix2.equivalence.pattern.rst @@ -1,5 +1,5 @@ pattern -============== +========================= .. automodule:: stix2.equivalence.pattern - :members: + :members: \ No newline at end of file diff --git a/docs/api/markings/stix2.markings.granular_markings.rst b/docs/api/markings/stix2.markings.granular_markings.rst index d64ebc9..b4a7160 100644 --- a/docs/api/markings/stix2.markings.granular_markings.rst +++ b/docs/api/markings/stix2.markings.granular_markings.rst @@ -2,4 +2,4 @@ granular_markings ================================ .. automodule:: stix2.markings.granular_markings - :members: + :members: \ No newline at end of file diff --git a/docs/api/markings/stix2.markings.object_markings.rst b/docs/api/markings/stix2.markings.object_markings.rst index 8e8de67..d861c87 100644 --- a/docs/api/markings/stix2.markings.object_markings.rst +++ b/docs/api/markings/stix2.markings.object_markings.rst @@ -2,4 +2,4 @@ object_markings ============================== .. automodule:: stix2.markings.object_markings - :members: + :members: \ No newline at end of file diff --git a/docs/api/markings/stix2.markings.utils.rst b/docs/api/markings/stix2.markings.utils.rst index 66793aa..ee59b6c 100644 --- a/docs/api/markings/stix2.markings.utils.rst +++ b/docs/api/markings/stix2.markings.utils.rst @@ -2,4 +2,4 @@ utils ==================== .. automodule:: stix2.markings.utils - :members: + :members: \ No newline at end of file diff --git a/docs/api/stix2.confidence.rst b/docs/api/stix2.confidence.rst index 5c2658b..2ecf230 100644 --- a/docs/api/stix2.confidence.rst +++ b/docs/api/stix2.confidence.rst @@ -1,5 +1,5 @@ -confidence +confidence ================ .. automodule:: stix2.confidence - :members: + :members: \ No newline at end of file diff --git a/docs/api/stix2.datastore.rst b/docs/api/stix2.datastore.rst index 0d90987..aae929d 100644 --- a/docs/api/stix2.datastore.rst +++ b/docs/api/stix2.datastore.rst @@ -1,5 +1,5 @@ -datastore +datastore =============== .. automodule:: stix2.datastore - :members: + :members: \ No newline at end of file diff --git a/docs/api/stix2.environment.rst b/docs/api/stix2.environment.rst index 6b44ba5..26e5e8b 100644 --- a/docs/api/stix2.environment.rst +++ b/docs/api/stix2.environment.rst @@ -1,5 +1,5 @@ -environment +environment ================= .. automodule:: stix2.environment - :members: + :members: \ No newline at end of file diff --git a/docs/api/stix2.equivalence.rst b/docs/api/stix2.equivalence.rst index b886fc7..db81543 100644 --- a/docs/api/stix2.equivalence.rst +++ b/docs/api/stix2.equivalence.rst @@ -1,5 +1,5 @@ -equivalence -============== +equivalence +================= .. automodule:: stix2.equivalence - :members: + :members: \ No newline at end of file diff --git a/docs/api/stix2.exceptions.rst b/docs/api/stix2.exceptions.rst index ad8ddf3..69156a0 100644 --- a/docs/api/stix2.exceptions.rst +++ b/docs/api/stix2.exceptions.rst @@ -1,5 +1,5 @@ -exceptions +exceptions ================ .. automodule:: stix2.exceptions - :members: + :members: \ No newline at end of file diff --git a/docs/api/stix2.markings.rst b/docs/api/stix2.markings.rst index 881fda1..8c9f1e1 100644 --- a/docs/api/stix2.markings.rst +++ b/docs/api/stix2.markings.rst @@ -1,5 +1,5 @@ -markings +markings ============== .. automodule:: stix2.markings - :members: + :members: \ No newline at end of file diff --git a/docs/api/stix2.parsing.rst b/docs/api/stix2.parsing.rst index bee3e4e..e028e4a 100644 --- a/docs/api/stix2.parsing.rst +++ b/docs/api/stix2.parsing.rst @@ -1,5 +1,5 @@ -parsing -=============== +parsing +============= .. automodule:: stix2.parsing - :members: + :members: \ No newline at end of file diff --git a/docs/api/stix2.pattern_visitor.rst b/docs/api/stix2.pattern_visitor.rst index fe8e34f..83475e6 100644 --- a/docs/api/stix2.pattern_visitor.rst +++ b/docs/api/stix2.pattern_visitor.rst @@ -1,5 +1,5 @@ -pattern_visitor -================ +pattern_visitor +===================== .. automodule:: stix2.pattern_visitor - :members: + :members: \ No newline at end of file diff --git a/docs/api/stix2.patterns.rst b/docs/api/stix2.patterns.rst index f95ec34..99608c0 100644 --- a/docs/api/stix2.patterns.rst +++ b/docs/api/stix2.patterns.rst @@ -1,5 +1,5 @@ -patterns +patterns ============== .. automodule:: stix2.patterns - :members: + :members: \ No newline at end of file diff --git a/docs/api/stix2.properties.rst b/docs/api/stix2.properties.rst index e357ef4..931fdc8 100644 --- a/docs/api/stix2.properties.rst +++ b/docs/api/stix2.properties.rst @@ -1,5 +1,5 @@ -properties +properties ================ .. automodule:: stix2.properties - :members: + :members: \ No newline at end of file diff --git a/docs/api/stix2.serialization.rst b/docs/api/stix2.serialization.rst index bc182d8..00c5163 100644 --- a/docs/api/stix2.serialization.rst +++ b/docs/api/stix2.serialization.rst @@ -1,5 +1,5 @@ -serialization -================ +serialization +=================== .. automodule:: stix2.serialization - :members: + :members: \ No newline at end of file diff --git a/docs/api/stix2.utils.rst b/docs/api/stix2.utils.rst index 49a1e16..c3088ae 100644 --- a/docs/api/stix2.utils.rst +++ b/docs/api/stix2.utils.rst @@ -1,5 +1,5 @@ -utils +utils =========== .. automodule:: stix2.utils - :members: + :members: \ No newline at end of file diff --git a/docs/api/stix2.v20.rst b/docs/api/stix2.v20.rst index 85f4a22..b523168 100644 --- a/docs/api/stix2.v20.rst +++ b/docs/api/stix2.v20.rst @@ -1,5 +1,5 @@ -v20 +v20 ========= .. automodule:: stix2.v20 - :members: + :members: \ No newline at end of file diff --git a/docs/api/stix2.v21.rst b/docs/api/stix2.v21.rst index 7157e3d..565ae61 100644 --- a/docs/api/stix2.v21.rst +++ b/docs/api/stix2.v21.rst @@ -1,5 +1,5 @@ -v21 +v21 ========= .. automodule:: stix2.v21 - :members: + :members: \ No newline at end of file diff --git a/docs/api/stix2.versioning.rst b/docs/api/stix2.versioning.rst index adc2eab..fcbec92 100644 --- a/docs/api/stix2.versioning.rst +++ b/docs/api/stix2.versioning.rst @@ -1,5 +1,5 @@ -versioning -=============== +versioning +================ .. automodule:: stix2.versioning - :members: + :members: \ No newline at end of file diff --git a/docs/api/stix2.workbench.rst b/docs/api/stix2.workbench.rst index 8fa2544..137291e 100644 --- a/docs/api/stix2.workbench.rst +++ b/docs/api/stix2.workbench.rst @@ -1,5 +1,5 @@ -workbench +workbench =============== .. automodule:: stix2.workbench - :members: + :members: \ No newline at end of file diff --git a/docs/conf.py b/docs/conf.py index b6dd6ea..dc43ccf 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -40,7 +40,6 @@ author = 'OASIS Open' version = __version__ release = __version__ -language = None exclude_patterns = ['_build', '_templates', 'Thumbs.db', '.DS_Store', 'guide/.ipynb_checkpoints'] pygments_style = 'sphinx' todo_include_todos = False @@ -102,8 +101,8 @@ class STIXPropertyDocumenter(ClassDocumenter): issubclass(member, _STIXBase) and \ hasattr(member, '_properties') - def add_content(self, more_content, no_docstring=False): - ClassDocumenter.add_content(self, more_content, no_docstring) + def add_content(self, more_content): + ClassDocumenter.add_content(self, more_content) obj = self.object self.add_line(':Properties:', '') diff --git a/docs/guide/custom.ipynb b/docs/guide/custom.ipynb index c31e204..3d65dcb 100644 --- a/docs/guide/custom.ipynb +++ b/docs/guide/custom.ipynb @@ -1482,7 +1482,7 @@ "source": [ "### Custom Cyber Observable Extensions\n", "\n", - "Finally, custom extensions to existing Cyber Observable types can also be created. Just use the @[CustomExtension](../api/v21/stix2.v21.observables.rst#stix2.v21.observables.CustomExtension) decorator. Note that you must provide the Cyber Observable class to which the extension applies. Again, any extra validation of the properties can be implemented by providing an ``__init__()`` but it is not required. Let's say we want to make an extension to the ``File`` Cyber Observable Object:" + "Finally, custom extensions to existing Cyber Observable types can also be created. Just use the @[CustomExtension](../api/v21/stix2.v21.common.rst#stix2.v21.common.CustomExtension) decorator. Note that you must provide the Cyber Observable class to which the extension applies. Again, any extra validation of the properties can be implemented by providing an ``__init__()`` but it is not required. Let's say we want to make an extension to the ``File`` Cyber Observable Object:" ] }, { @@ -1803,7 +1803,7 @@ ], "metadata": { "kernelspec": { - "display_name": "Python 3 (ipykernel)", + "display_name": "Python 3", "language": "python", "name": "python3" }, @@ -1817,7 +1817,7 @@ "name": "python", "nbconvert_exporter": "python", "pygments_lexer": "ipython3", - "version": "3.8.1" + "version": "3.9.2" } }, "nbformat": 4, diff --git a/docs/guide/ts_support.ipynb b/docs/guide/ts_support.ipynb index 8c07134..eb45352 100644 --- a/docs/guide/ts_support.ipynb +++ b/docs/guide/ts_support.ipynb @@ -63,8 +63,7 @@ "\n", "Imports can be used in different ways depending on the use case and support levels.\n", "\n", - "People who want to support the latest version of STIX 2 without having to make changes, can implicitly use the latest version:", - "
\n", + "People who want to support the latest version of STIX 2 without having to make changes, can implicitly use the latest version:
\n", "\n", "**Warning**\n", "\n", @@ -372,7 +371,7 @@ "source": [ "### How custom content works\n", "\n", - "[CustomObject](../api/v21/stix2.v21.sdo.rst#stix2.v21.sdo.CustomObject), [CustomObservable](../api/v21/stix2.v21.observables.rst#stix2.v21.observables.CustomObservable), [CustomMarking](../api/v21/stix2.v21.common.rst#stix2.v21.common.CustomMarking) and [CustomExtension](../api/v21/stix2.v21.observables.rst#stix2.v21.observables.CustomExtension) must be registered explicitly by STIX version. This is a design decision since properties or requirements may change as the STIX Technical Specification advances.\n", + "[CustomObject](../api/v21/stix2.v21.sdo.rst#stix2.v21.sdo.CustomObject), [CustomObservable](../api/v21/stix2.v21.observables.rst#stix2.v21.observables.CustomObservable), [CustomMarking](../api/v21/stix2.v21.common.rst#stix2.v21.common.CustomMarking) and [CustomExtension](../api/v21/stix2.v21.common.rst#stix2.v21.common.CustomExtension) must be registered explicitly by STIX version. This is a design decision since properties or requirements may change as the STIX Technical Specification advances.\n", "\n", "You can perform this by:" ] @@ -416,7 +415,7 @@ "name": "python", "nbconvert_exporter": "python", "pygments_lexer": "ipython3", - "version": "3.9.0a6" + "version": "3.9.2" } }, "nbformat": 4, diff --git a/requirements.txt b/requirements.txt index ed517e0..4cb08b6 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,12 +1,12 @@ bumpversion ipython -nbconvert<6 +nbconvert nbsphinx==0.8.6 pre-commit pygments<3,>=2.4.1 pytest pytest-cov -sphinx<2 +sphinx<6 sphinx-prompt tox diff --git a/stix2/environment.py b/stix2/environment.py index f7c13ee..eab2ba9 100644 --- a/stix2/environment.py +++ b/stix2/environment.py @@ -119,7 +119,6 @@ class Environment(DataStoreMixin): .. automethod:: get .. automethod:: all_versions .. automethod:: query - .. automethod:: creator_of .. automethod:: relationships .. automethod:: related_to .. automethod:: add diff --git a/stix2/equivalence/object/__init__.py b/stix2/equivalence/object/__init__.py index dde52ec..2b16a34 100644 --- a/stix2/equivalence/object/__init__.py +++ b/stix2/equivalence/object/__init__.py @@ -244,7 +244,7 @@ def partial_timestamp_based(t1, t2, tdelta): def partial_list_based(l1, l2): """Performs a partial list matching via finding the intersection between common values. Repeated values are counted only once. This method can be - used for *_refs equality checks when de-reference is not possible. + used for _refs equality checks when de-reference is not possible. Args: l1: A list of values. @@ -262,7 +262,7 @@ def partial_list_based(l1, l2): def exact_match(val1, val2): """Performs an exact value match based on two values. This method can be - used for *_ref equality check when de-reference is not possible. + used for _ref equality check when de-reference is not possible. Args: val1: A value suitable for an equality test.