Skip to content

Commit 4d8c0ef

Browse files
FloLeyinmantaci
authored andcommitted
Run black on the .py files of the docs to realign due to the same changes on lsm (PR #7110)
# Description run black on the .py files of the docs to realign it with the same changes on lsm # Self Check: Strike through any lines that are not applicable (`~~line~~`) then check the box - [ ] Attached issue to pull request - [ ] Changelog entry - [ ] Type annotations are present - [ ] Code is clear and sufficiently documented - [ ] No (preventable) type errors (check using make mypy or make mypy-diff) - [ ] Sufficient test cases (reproduces the bug/tests the requested feature) - [ ] Correct, in line with design - [ ] End user documentation is included or an issue is created for end-user documentation (add ref to issue here: ) - [ ] If this PR fixes a race condition in the test suite, also push the fix to the relevant stable branche(s) (see [test-fixes](https://internal.inmanta.com/development/core/tasks/build-master.html#test-fixes) for more info)
1 parent 6c31c50 commit 4d8c0ef

14 files changed

+20
-4
lines changed
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
description: Run black on the .py files of the docs to realign due to the same changes on lsm
2+
change-type: patch
3+
destination-branches: [master, iso7]

docs/check_sphinx.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33

44
import pytest
55

6+
67
@pytest.fixture(scope="session")
78
def build_docs(tmpdir_factory):
89
tmpdir = tmpdir_factory.mktemp("doctest")
@@ -32,4 +33,3 @@ def test_linkcheck(build_docs):
3233
assert os.path.exists(openapi_html_file)
3334
openapi_json_file = htmldir.join("_specs/openapi.json")
3435
assert os.path.exists(openapi_json_file)
35-

docs/conf.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -370,4 +370,4 @@ def check_dot_command():
370370
r'https://github.com/inmanta/examples/tree/master/Networking/SR%20Linux#user-content-sr-linux-topology',
371371
]
372372

373-
graphviz_output_format = "svg"
373+
graphviz_output_format = "svg"

docs/extract_openapi_json.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@
1515
1616
1717
"""
18+
1819
import json
1920

2021

docs/lsm/allocation/allocation_sources/allocation_v2_native.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
66
:license: Inmanta EULA
77
"""
8+
89
from inmanta.util import dict_path
910
from inmanta_plugins.lsm.allocation import AllocationSpecV2
1011
from inmanta_plugins.lsm.allocation_v2.framework import AllocatorV2, ContextV2, ForEach

docs/lsm/allocation/allocation_sources/allocation_v2_track_delete.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
66
:license: Inmanta EULA
77
"""
8+
89
from inmanta.util import dict_path
910
from inmanta_plugins.lsm.allocation import AllocationSpecV2
1011
from inmanta_plugins.lsm.allocation_v2.framework import (

docs/lsm/allocation/allocation_sources/allocation_v2_with_context_v2_wrapper.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
66
:license: Inmanta EULA
77
"""
8+
89
from inmanta.util import dict_path
910
from inmanta_plugins.lsm.allocation import AllocationSpecV2
1011
from inmanta_plugins.lsm.allocation_v2.framework import (

docs/lsm/allocation/allocation_sources/base_example.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
66
:license: Inmanta EULA
77
"""
8+
89
import inmanta_plugins.lsm.allocation as lsm
910

1011
lsm.AllocationSpec(

docs/lsm/allocation/allocation_sources/deallocation.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
66
:license: Inmanta EULA
77
"""
8+
89
import os
910
from typing import Optional
1011
from uuid import UUID

docs/lsm/allocation/allocation_sources/pg_attr_example.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
66
:license: Inmanta EULA
77
"""
8+
89
import os
910
from typing import Any, Optional
1011

docs/lsm/allocation/allocation_sources/pg_id_example.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
66
:license: Inmanta EULA
77
"""
8+
89
import os
910
from typing import Optional
1011
from uuid import UUID

docs/lsm/allocation/allocation_sources/pg_lookup_example.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
66
:license: Inmanta EULA
77
"""
8+
89
import os
910
from typing import Any, Optional
1011

docs/model_developers/unmanaged_resources/basic_example_handler.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,7 @@ class UnmanagedInterface(pydantic.BaseModel):
2626
Datastructure used by the InterfaceDiscoveryHandler to return the attributes
2727
of its discovered resources.
2828
"""
29+
2930
host: str
3031
interface_name: str
3132
ip_address: str
@@ -40,7 +41,8 @@ def discover_resources(
4041
Entrypoint that is called by the agent when the discovery resource is deployed.
4142
"""
4243
discovered: abc.Iterator[UnmanagedInterface] = (
43-
UnmanagedInterface(**attributes) for attributes in self._get_discovered_interfaces(discovery_resource)
44+
UnmanagedInterface(**attributes)
45+
for attributes in self._get_discovered_interfaces(discovery_resource)
4446
if discovery_resource.name_filter is None or re.match(discovery_resource.name_filter, attributes["interface_name"])
4547
)
4648
return {

docs/model_developers/unmanaged_resources/shared_attributes_example_handler.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,7 @@ class UnmanagedInterface(pydantic.BaseModel):
5050
Datastructure used by the InterfaceDiscoveryHandler to return the attributes
5151
of the discovered resources.
5252
"""
53+
5354
host: str
5455
interface_name: str
5556
ip_address: str
@@ -108,7 +109,8 @@ def discover_resources(
108109
Entrypoint that is called by the agent when the discovery resource is deployed.
109110
"""
110111
discovered: abc.Iterator[UnmanagedInterface] = (
111-
UnmanagedInterface(**attributes) for attributes in self._get_discovered_interfaces(discovery_resource)
112+
UnmanagedInterface(**attributes)
113+
for attributes in self._get_discovered_interfaces(discovery_resource)
112114
if discovery_resource.name_filter is None or re.match(discovery_resource.name_filter, attributes["interface_name"])
113115
)
114116
return {

0 commit comments

Comments
 (0)