Skip to content

Commit

Permalink
Merge pull request #28 from dkolbly/allow-lint-flags
Browse files Browse the repository at this point in the history
allows 'suppress_checks' flag in attributes
  • Loading branch information
dkolbly authored May 29, 2024
2 parents d6637d5 + ee44669 commit e07b620
Show file tree
Hide file tree
Showing 2 changed files with 31 additions and 0 deletions.
30 changes: 30 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
# a Dockerfile to containerize the build of ocsf-validator
#
# To build a container:
#
# docker build -t ocsf-validator:latest .
#
# To use it to validate a schema
#
# docker run --rm -v $PWD:/schema ocsf-validator:latest /schema
#

FROM python:3.11.9-alpine3.19

RUN apk add --no-cache poetry nodejs npm

WORKDIR /src

# install stuff that doesn't change much
ADD poetry.lock pyproject.toml .
RUN poetry install --no-root

# pull in the rest of the code
ADD . .
RUN poetry install --only-root
RUN poetry run black .
RUN poetry run isort .
RUN poetry run pyright ocsf_validator
RUN poetry run pytest

ENTRYPOINT ["poetry", "run", "python", "-m", "ocsf_validator"]
1 change: 1 addition & 0 deletions ocsf_validator/types.py
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,7 @@ class OcsfDeprecationInfo(TypedDict):
"enum": NotRequired[Dict[str, OcsfEnumMember]],
"group": NotRequired[str],
"is_array": NotRequired[bool],
"suppress_checks": NotRequired[Sequence[str]],
"max_len": NotRequired[int],
"name": NotRequired[str],
"notes": NotRequired[str],
Expand Down

0 comments on commit e07b620

Please sign in to comment.