Skip to content
This repository has been archived by the owner on Feb 12, 2024. It is now read-only.

Commit

Permalink
lint
Browse files Browse the repository at this point in the history
  • Loading branch information
AndreasBurger authored and ccwienk committed Jun 7, 2021
1 parent 751e671 commit fe544eb
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions bindings-python/gci/componentmodel.py
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ class AccessType(enum.Enum):
LOCAL_FILESYSTEM_BLOB = 'localFilesystemBlob'
NONE = 'None' # the resource is only declared informally (e.g. generic)


class SourceType(enum.Enum):
GIT = 'git'

Expand All @@ -45,6 +46,7 @@ class ResourceType(enum.Enum):
OCI_IMAGE = 'ociImage'
GENERIC = 'generic'


class ResourceRelation(enum.Enum):
LOCAL = 'local'
EXTERNAL = 'external'
Expand Down Expand Up @@ -377,10 +379,10 @@ def _read_schema_file(schema_file_path: str):


def enum_or_string(v, enum_type: enum.Enum):
try:
return enum_type(v)
except ValueError:
return str(v)
try:
return enum_type(v)
except ValueError:
return str(v)


@dc
Expand Down

0 comments on commit fe544eb

Please sign in to comment.