diff --git a/.github/workflows/check-unused-imports.yml b/.github/workflows/check-unused-imports.yml index b89f965..e05aa38 100644 --- a/.github/workflows/check-unused-imports.yml +++ b/.github/workflows/check-unused-imports.yml @@ -10,5 +10,5 @@ permissions: jobs: check-unused-imports: - uses: vyos/.github/.github/workflows/check-unused-imports.yml@T6789-unused-import-checkout-current + uses: vyos/.github/.github/workflows/check-unused-imports.yml@T6789-unused-import-checkout-curre secrets: inherit diff --git a/src/migration-scripts/bgp/1-to-2 b/src/migration-scripts/bgp/1-to-2 index c0fc3b0..4b34e0f 100644 --- a/src/migration-scripts/bgp/1-to-2 +++ b/src/migration-scripts/bgp/1-to-2 @@ -17,6 +17,8 @@ # T5937: Migrate IPv6 BGP Neighbor Peer Groups from vyos.configtree import ConfigTree +import json +import os base = ['protocols', 'bgp'] diff --git a/src/migration-scripts/cluster/1-to-2 b/src/migration-scripts/cluster/1-to-2 index 5ca4531..6bee6d7 100644 --- a/src/migration-scripts/cluster/1-to-2 +++ b/src/migration-scripts/cluster/1-to-2 @@ -15,6 +15,7 @@ import re import sys +import json from vyos.configtree import ConfigTree from vyos.base import MigrationError diff --git a/src/migration-scripts/config-management/0-to-1 b/src/migration-scripts/config-management/0-to-1 index 44c6856..38c8193 100644 --- a/src/migration-scripts/config-management/0-to-1 +++ b/src/migration-scripts/config-management/0-to-1 @@ -16,6 +16,7 @@ # Add commit-revisions option if it doesn't exist from vyos.configtree import ConfigTree +import json def migrate(config: ConfigTree) -> None: if config.exists(['system', 'config-management', 'commit-revisions']): diff --git a/src/migration-scripts/conntrack/1-to-2 b/src/migration-scripts/conntrack/1-to-2 index 0a4fb3d..6d7b860 100644 --- a/src/migration-scripts/conntrack/1-to-2 +++ b/src/migration-scripts/conntrack/1-to-2 @@ -16,6 +16,7 @@ # Delete "set system conntrack modules gre" option from vyos.configtree import ConfigTree +import json def migrate(config: ConfigTree) -> None: diff --git a/src/tests/helper.py b/src/tests/helper.py index c3aed20..faa0aa6 100644 --- a/src/tests/helper.py +++ b/src/tests/helper.py @@ -16,7 +16,6 @@ import sys import importlib.util -import math import json import os diff --git a/src/tests/test_configverify.py b/src/tests/test_configverify.py index e598679..bf48981 100644 --- a/src/tests/test_configverify.py +++ b/src/tests/test_configverify.py @@ -15,6 +15,7 @@ # along with this program. If not, see . from unittest import TestCase +import json from vyos.configverify import verify_diffie_hellman_length from vyos.utils.process import cmd diff --git a/src/tests/test_op_mode.py b/src/tests/test_op_mode.py index 5e64d41..ad661c3 100644 --- a/src/tests/test_op_mode.py +++ b/src/tests/test_op_mode.py @@ -16,6 +16,7 @@ from unittest import TestCase import os +import json import vyos.opmode class TestVyOSOpMode(TestCase): diff --git a/src/utils/initial-setup b/src/utils/initial-setup index 37fc457..bf4ba27 100644 --- a/src/utils/initial-setup +++ b/src/utils/initial-setup @@ -1,6 +1,7 @@ #!/usr/bin/env python3 import argparse +import json import vyos.configtree diff --git a/src/utils/vyos-config-file-query b/src/utils/vyos-config-file-query index a10c7e9..69b4812 100644 --- a/src/utils/vyos-config-file-query +++ b/src/utils/vyos-config-file-query @@ -17,6 +17,7 @@ import re import os +import math import sys import json import argparse