-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #14 from voquis/12-use-oidc-publishing
#12 use oidc publishing
- Loading branch information
Showing
16 changed files
with
216 additions
and
1,144 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,31 +1,43 @@ | ||
[tool.poetry] | ||
[build-system] | ||
build-backend = "hatchling.build" | ||
requires = ["hatchling"] | ||
|
||
[project] | ||
name = "value-fetcher" | ||
version = "1.0.2" | ||
version = "1.0.3" | ||
description = "Fetch a value from various sources, e.g AWS Secrets Manager and SSM Parameter Store" | ||
authors = ["Voquis Limited <opensource@voquis.com>"] | ||
readme = "README.md" | ||
packages = [{include = "value_fetcher", from = "src"}] | ||
homepage = "https://github.com/voquis/value-fetcher" | ||
repository = "https://github.com/voquis/value-fetcher" | ||
keywords = ["parameters", "secrets", "configuration", "values"] | ||
readme = "README.md" | ||
license = "MIT" | ||
requires-python = ">=3.8" | ||
|
||
authors = [{ name = "Voquis Limited", email = "opensource@voquis.com" }] | ||
|
||
classifiers = [ | ||
"Programming Language :: Python :: 3", | ||
"License :: OSI Approved :: MIT License", | ||
"Operating System :: OS Independent", | ||
] | ||
|
||
[tool.poetry.dependencies] | ||
python = "^3.11" | ||
boto3 = "^1.26.27" | ||
pyyaml = "^6.0" | ||
dependencies = ["boto3"] | ||
|
||
[project.optional-dependencies] | ||
dev = [ | ||
'black', | ||
'build', | ||
'flake8', | ||
'moto', | ||
'pylint', | ||
'pytest', | ||
'pytest-cov', | ||
'twine' | ||
] | ||
|
||
[project.urls] | ||
Homepage = "https://github.com/voquis/value-fetcher" | ||
Issues = "https://github.com/voquis/value-fetcher/issues" | ||
|
||
[tool.pytest.ini_options] | ||
pythonpath = [ | ||
"src" | ||
] | ||
|
||
[tool.poetry.group.dev.dependencies] | ||
moto = "^4.0.11" | ||
pylint = "^2.15.8" | ||
pytest = "^7.2.0" | ||
coverage = "^6.5.0" | ||
|
||
[build-system] | ||
requires = ["poetry-core"] | ||
build-backend = "poetry.core.masonry.api" |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,27 @@ | ||
#!/bin/bash | ||
set -euo pipefail | ||
|
||
# Install dependencies, including development dependencies | ||
poetry install --no-root | ||
# Assumes the src contains a single package to be built | ||
PACKAGE_PATH=$(find src/* -type d | head -n 1) | ||
PACKAGE_NAME=${PACKAGE_PATH#src/} | ||
echo "Using package name: $PACKAGE_NAME" | ||
|
||
# Run linting checks on package, tests and app entrypoint | ||
poetry run pylint src tests | ||
# Install development dependencies with pip | ||
pip install .[dev] | ||
|
||
# Run tests and generate test coverage report | ||
poetry run coverage run -m pytest tests | ||
poetry run coverage html --omit="tests*" | ||
poetry run coverage xml --omit="tests/*" | ||
poetry run coverage report --omit="tests/*" --precision=2 --fail-under=100.00 | ||
# Run formatting checks | ||
flake8 | ||
|
||
# Run linting checks | ||
black --check --diff . | ||
pylint src tests | ||
|
||
# Run tests and generate coverage reports | ||
pytest --cov="$PACKAGE_NAME" \ | ||
--cov-report term \ | ||
--cov-report html \ | ||
--cov-fail-under=100.00 | ||
|
||
# Check the build | ||
python -m build | ||
twine check --strict dist/* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,7 @@ | ||
""" | ||
Load value fetcher class to make available at the package level | ||
""" | ||
|
||
from .base import ValueFetcher | ||
|
||
type(ValueFetcher) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.