/content-type-converter

Convert HTTP POST `Content-Type`, for instance from `application/x-www-form-urlencoded` to `application/json`.

Primary LanguagePythonMIT LicenseMIT

Content-Type converter

Convert HTTP POST Content-Type, for instance from application/x-www-form-urlencoded to application/json.

Test codecov GitHub last commit License

Setup

# Install Python on your computer, then install pipx and Poetry
python3 -m pip install --user pipx
python3 -m pipx ensurepath
pipx install poetry

# Install dependencies (including development dependencies)
poetry install

# Setup pre-commit and pre-push hooks
poetry run pre-commit install -t pre-commit
poetry run pre-commit install -t pre-push

Run the app

# Optionally activate Flask's Debug mode when developing
export FLASK_DEBUG=1

# Run the Flask app
poetry run flask run

Development info

# Run the test suite
poetry run pytest --cov --cov-report=term --cov-report=html
# The output in HTML form can be found in the `htmlcov` folder

# Update dependencies
poetry update