Skip to content

Commit

Permalink
Move catalog reader to it's own python package
Browse files Browse the repository at this point in the history
  • Loading branch information
sonicaj committed May 5, 2024
1 parent a28de63 commit de161b3
Show file tree
Hide file tree
Showing 20 changed files with 13 additions and 13 deletions.
4 changes: 2 additions & 2 deletions apps_validation/ci/git.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@
import subprocess
from collections import defaultdict

from apps_validation.catalog_reader.dev_directory import (
from catalog_reader.dev_directory import (
DEV_DIRECTORY_RELATIVE_PATH, get_ci_development_directory, OPTIONAL_METADATA_FILES
)
from apps_validation.catalog_reader.train_utils import is_train_valid
from catalog_reader.train_utils import is_train_valid
from apps_validation.exceptions import CatalogDoesNotExist


Expand Down
6 changes: 3 additions & 3 deletions apps_validation/scripts/catalog_update.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,12 @@

from jsonschema import validate as json_schema_validate, ValidationError as JsonValidationError

from apps_validation.catalog_reader.catalog import retrieve_train_names, retrieve_trains_data, get_apps_in_trains
from apps_validation.catalog_reader.dev_directory import (
from catalog_reader.catalog import retrieve_train_names, retrieve_trains_data, get_apps_in_trains
from catalog_reader.dev_directory import (
get_app_version, get_ci_development_directory, get_to_keep_versions, OPTIONAL_METADATA_FILES,
REQUIRED_METADATA_FILES, version_has_been_bumped,
)
from apps_validation.catalog_reader.train_utils import get_train_path
from catalog_reader.train_utils import get_train_path
from apps_validation.ci.names import CACHED_CATALOG_FILE_NAME, CACHED_VERSION_FILE_NAME
from apps_validation.exceptions import ValidationErrors
from apps_validation.validation.json_schema_utils import CATALOG_JSON_SCHEMA
Expand Down
2 changes: 1 addition & 1 deletion apps_validation/validation/validate_app_version.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
from jsonschema import validate as json_schema_validate, ValidationError as JsonValidationError
from semantic_version import Version

from apps_validation.catalog_reader.questions_util import CUSTOM_PORTALS_KEY
from catalog_reader.questions_util import CUSTOM_PORTALS_KEY
from apps_validation.exceptions import ValidationErrors

from .app_version import validate_app_version_file
Expand Down
2 changes: 1 addition & 1 deletion apps_validation/validation/validate_catalog.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
from jsonschema import validate as json_schema_validate, ValidationError as JsonValidationError

from apps_validation.ci.names import CACHED_CATALOG_FILE_NAME
from apps_validation.catalog_reader.train_utils import get_train_path
from catalog_reader.train_utils import get_train_path
from apps_validation.exceptions import CatalogDoesNotExist, ValidationErrors

from .json_schema_utils import CATALOG_JSON_SCHEMA
Expand Down
4 changes: 2 additions & 2 deletions apps_validation/validation/validate_dev_directory.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,11 @@

from jsonschema import ValidationError as JsonValidationError

from apps_validation.catalog_reader.dev_directory import (
from catalog_reader.dev_directory import (
get_app_version, get_ci_development_directory, get_to_keep_versions, REQUIRED_METADATA_FILES,
version_has_been_bumped,
)
from apps_validation.catalog_reader.names import UPGRADE_STRATEGY_FILENAME, TO_KEEP_VERSIONS
from catalog_reader.names import UPGRADE_STRATEGY_FILENAME, TO_KEEP_VERSIONS
from apps_validation.exceptions import ValidationErrors

from .app_version import validate_app_version_file
Expand Down
4 changes: 2 additions & 2 deletions apps_validation/validation/validate_questions.py
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import typing
import yaml

from apps_validation.catalog_reader.questions import CUSTOM_PORTALS_ENABLE_KEY, CUSTOM_PORTAL_GROUP_KEY
from apps_validation.catalog_reader.questions_util import CUSTOM_PORTALS_KEY
from catalog_reader.questions import CUSTOM_PORTALS_ENABLE_KEY, CUSTOM_PORTAL_GROUP_KEY
from catalog_reader.questions_util import CUSTOM_PORTALS_KEY
from apps_validation.exceptions import ValidationErrors
from apps_validation.schema.variable import Variable

Expand Down
2 changes: 1 addition & 1 deletion apps_validation/validation/validate_recommended_apps.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

from jsonschema import validate as json_schema_validate, ValidationError as JsonValidationError

from apps_validation.catalog_reader.names import RECOMMENDED_APPS_FILENAME
from catalog_reader.names import RECOMMENDED_APPS_FILENAME
from apps_validation.exceptions import ValidationErrors

from .json_schema_utils import RECOMMENDED_APPS_JSON_SCHEMA
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
description='Validate TrueNAS Apps Catalog',
version=VERSION,
include_package_data=True,
packages=find_packages(),
packages=find_packages(include=['apps_validation', 'catalog_reader', 'apps_validation.*', 'catalog_reader.*']),
license='GNU3',
platforms='any',
entry_points={
Expand Down

0 comments on commit de161b3

Please sign in to comment.