Skip to content

Commit 46b46ef

Browse files
committed
Sort all imports with isort
1 parent 737878c commit 46b46ef

30 files changed

+76
-65
lines changed

src/gardenlinux/apt/package_repo_info.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,10 @@
44
APT repositories
55
"""
66

7-
from apt_repo import APTRepository
87
from typing import Optional
98

9+
from apt_repo import APTRepository
10+
1011

1112
class GardenLinuxRepo(APTRepository):
1213
"""

src/gardenlinux/features/__main__.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,6 @@
1717
from .cname import CName
1818
from .parser import Parser
1919

20-
2120
_ARGS_TYPE_ALLOWED = [
2221
"cname",
2322
"cname_base",

src/gardenlinux/features/cname.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,10 @@
44
Canonical name (cname)
55
"""
66

7-
from typing import Optional
87
import re
8+
from typing import Optional
99

1010
from ..constants import ARCHS
11-
1211
from .parser import Parser
1312

1413

src/gardenlinux/features/cname_main.py

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -5,21 +5,20 @@
55
gl-cname main entrypoint
66
"""
77

8-
from functools import reduce
9-
from os.path import basename, dirname
108
import argparse
119
import logging
1210
import re
13-
14-
from .cname import CName
15-
from .parser import Parser
11+
from functools import reduce
12+
from os.path import basename, dirname
1613

1714
from .__main__ import (
1815
get_cname_base,
1916
get_minimal_feature_set,
2017
get_version_and_commit_id_from_files,
2118
sort_subset,
2219
)
20+
from .cname import CName
21+
from .parser import Parser
2322

2423

2524
def main():

src/gardenlinux/features/parser.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,21 +4,21 @@
44
Features parser based on networkx.Digraph
55
"""
66

7-
from glob import glob
8-
from typing import Callable, Optional
97
import logging
10-
import networkx
118
import os
129
import re
1310
import subprocess
11+
from glob import glob
12+
from typing import Callable, Optional
13+
14+
import networkx
1415
import yaml
1516

1617
from ..constants import (
1718
ARCHS,
1819
BARE_FLAVOR_FEATURE_CONTENT,
1920
BARE_FLAVOR_LIBC_FEATURE_CONTENT,
2021
)
21-
2222
from ..logger import LoggerSetup
2323

2424

src/gardenlinux/flavors/__main__.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,19 +5,19 @@
55
gl-flavors-parse main entrypoint
66
"""
77

8-
from argparse import ArgumentParser
9-
from pathlib import Path
10-
from tempfile import TemporaryDirectory
118
import json
129
import os
1310
import sys
11+
from argparse import ArgumentParser
12+
from pathlib import Path
13+
from tempfile import TemporaryDirectory
1414

1515
from git import Repo
1616
from git.exc import GitError
1717

18-
from .parser import Parser
1918
from ..constants import GL_REPOSITORY_URL
2019
from ..git import Git
20+
from .parser import Parser
2121

2222

2323
def _get_flavors_file_data(flavors_file):

src/gardenlinux/flavors/parser.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,10 @@
44
Flavors parser
55
"""
66

7-
from jsonschema import validate as jsonschema_validate
87
import fnmatch
8+
99
import yaml
10+
from jsonschema import validate as jsonschema_validate
1011

1112
from ..constants import GL_FLAVORS_SCHEMA
1213
from ..logger import LoggerSetup

src/gardenlinux/git/git.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
# -*- coding: utf-8 -*-
22

3+
import sys
34
from os import PathLike
45
from pathlib import Path
5-
import sys
66

7-
from git import Repo
87
from git import Git as _Git
8+
from git import Repo
99

1010
from ..logger import LoggerSetup
1111

src/gardenlinux/oci/__main__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,8 @@
55
"""
66

77
import os
8-
import click
98

9+
import click
1010
from pygments.lexer import default
1111

1212
from .container import Container

src/gardenlinux/oci/container.py

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -5,27 +5,27 @@
55
"""
66

77
import json
8-
import jsonschema
98
import logging
109
from base64 import b64encode
11-
from configparser import ConfigParser, UNNAMED_SECTION
1210
from collections.abc import Sequence
11+
from configparser import UNNAMED_SECTION, ConfigParser
1312
from hashlib import sha256
14-
from oras.container import Container as OrasContainer
15-
from oras.defaults import unknown_config_media_type as UNKNOWN_CONFIG_MEDIA_TYPE
16-
from oras.provider import Registry
17-
from oras.utils import make_targz, extract_targz
18-
from os import fdopen, getenv, PathLike
13+
from os import PathLike, fdopen, getenv
1914
from pathlib import Path
20-
from requests import Response
2115
from tempfile import mkstemp
2216
from typing import Optional
2317
from urllib.parse import urlsplit
2418

19+
import jsonschema
20+
from oras.container import Container as OrasContainer
21+
from oras.defaults import unknown_config_media_type as UNKNOWN_CONFIG_MEDIA_TYPE
22+
from oras.provider import Registry
23+
from oras.utils import extract_targz, make_targz
24+
from requests import Response
25+
2526
from ..constants import GL_MEDIA_TYPE_LOOKUP, OCI_IMAGE_INDEX_MEDIA_TYPE
2627
from ..features.cname import CName
2728
from ..logger import LoggerSetup
28-
2929
from .index import Index
3030
from .layer import Layer
3131
from .manifest import Manifest

0 commit comments

Comments
 (0)