Releases: sscovil/python-dev-cli
Expand Environment Variables
[1.1.0] - 2023-09-30
Added
- Add
parse_help
setting, to disable parsing script templates in thedev
CLI help page - Add
Template Parsing
subsection to theCaveats
section ofREADME.md
- Add caching for
Scripts.context
property, to avoid rebuilding the context dictionary on every access
Changed
- Modify
Scripts.__resolve()
to useos.path.expandvars()
for parsing environment variables in script templates - Modify boolean property setters in
Settings
to correctly parse string values as booleans - Update
README.md
with newparse_help
setting and information about parsing environment variables
Fixed
- Raise
ModuleNotFoundError
when attempting to import a missing module, instead of raisingTypeError
- Only raise an exception and show stack trace if
-d
or--debug
flag is set indev
CLI
Fix GitHub Action Publish Workflow
Apparently, the PyPI publish GitHub Action doesn't build the package for you. 🤦
This release adds the missing build step to the publish
workflow. No changes to the actual Python code.
Cross-Platform Testing
This release ensures tests are run on ubuntu-latest
, macos-latest
, windows-latest
, using Python versions 3.11
, 3.12.0-rc.3
. In order for tests to pass on Windows, a minor change needed to be made to Scripts.run_script()
so that function will no longer raise a FileNotFoundError
if shutil.which()
does not find the executable for a given script command. This was necessary because unit tests make liberal use of the echo
command, which is a built-in command (not an executable file) on Windows. Moreover, the dev
CLI should not enforce this restriction; instead, it now defers to subprocess.run()
.
Tag Commit For Release
Previous run of the publish workflow failed with this error:
ERROR HTTPError: 400 Bad Request from https://upload.pypi.org/legacy/
'1.0.3.dev0+g6f63100.d20230924' is an invalid value for Version. Error:
Can't use PEP 440 local versions. See
https://packaging.python.org/specifications/core-metadata for more
information.
This is an attempt to prevent the .dev
prefix from being added to the version by setuptools_scm
.
Fix GitHub Action Publish Workflow
Minor change to fix a failing code lint step in the new publish
workflow.
Dynamic Versioning & Automated Releases
This release makes no changes to the dev
CLI itself, but it removes an unnecessary dev dependency on pip-tools as well as the requirements.txt
and requirements-dev.txtfiles, in favor of using the
pip install -e ".[dev]"` command.
It also uses setuptools_scm to synchronize the package version with GitHub release tags; and adds a GitHub Action to automate the publication of new versions when a GitHub release is published.