From 4363ac9dd33856bfbbffd4418635490321bcb90d Mon Sep 17 00:00:00 2001 From: Paul Fioravanti Date: Thu, 3 Oct 2024 14:44:38 +1000 Subject: [PATCH] Update pytest config --- .github/workflows/ci.yml | 1 - .github/workflows/release.yml | 1 - .gitignore | 1 + README.md | 40 +---------------------------- setup.cfg | 5 ++-- src/plover_1password/__version__.py | 2 +- 6 files changed, 5 insertions(+), 45 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 1818667..aa1a605 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -25,7 +25,6 @@ jobs: - name: Install Test, Coverage, Lint, Type Checking Dependencies run: | python -m pip install --editable ".[test]" - python -m pip install git+https://git@github.com/1Password/onepassword-sdk-python.git@v0.1.1 - name: Run Linter run: pylint src diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index c3586b7..efd0cc1 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -25,7 +25,6 @@ jobs: - name: Install Test, Coverage, Lint, Type Checking Dependencies run: | python -m pip install --editable ".[test]" - python -m pip install git+https://git@github.com/1Password/onepassword-sdk-python.git@v0.1.1 - name: Run Linter run: pylint src diff --git a/.gitignore b/.gitignore index 16f79b6..876e6be 100644 --- a/.gitignore +++ b/.gitignore @@ -16,3 +16,4 @@ dist/ # Test coverage htmlcov/ .coverage +.coverage.* diff --git a/README.md b/README.md index 598b7c2..bb87161 100644 --- a/README.md +++ b/README.md @@ -7,12 +7,6 @@ retrieve secrets defined in your [1Password][] vaults. ## Install -> [!WARNING] -> Windows users cannot currently go through the Plover Plugins manager for -> installation due to [this GitHub issue][] related to getting the [1Password -> Python SDK][] library onto [PyPI][]. Please see [this issue][] for -> installation instructions that will require manual installation via [Git][]. - 1. In the Plover application, open the Plugins Manager (either click the Plugins Manager icon, or from the `Tools` menu, select `Plugins Manager`). 2. From the list of plugins, find `plover-1password` @@ -75,33 +69,6 @@ etc add: $ENV:OP_SERVICE_ACCOUNT_TOKEN = "" ``` -### Manually install 1Password Python SDK - -The [1Password Python SDK][] is not currently available on [PyPI][], which means -you will need to install it manually directly via URL with the following -Python [pip][] command in order for the plugin to work properly: - -```console -python -m pip install git+https://git@github.com/1Password/onepassword-sdk-python.git@v0.1.1 -``` - -Unfortunately, PyPi does not allow [direct URL dependencies][] in projects, so -in order to get this plugin on to PyPI, the SDK could not be listed as a -required dependency in `setup.cfg` like: - -```cfg -[options] -install_requires = - plover >= 4.0.0.dev12 - onepassword @ git+https://git@github.com/1Password/onepassword-sdk-python.git@v0.1.1 -``` - -This means a manual installation process instead of the plugin automatically -doing it for you. - -Currently, [this GitHub issue][] is tracking adding the SDK to PyPI, which when -closed will eliminate this step. - ### Install 1Password CLI and turn on desktop app integration Follow all the steps to [Get started with 1Password CLI][] to install the @@ -249,11 +216,10 @@ plover --script plover_plugins uninstall plover-1password [Coverage.py]: https://github.com/nedbat/coveragepy [create a new vault]: https://support.1password.com/create-share-vaults/#create-a-vault [create a Service Account]: https://developer.1password.com/docs/service-accounts/get-started/#create-a-service-account -[direct URL dependencies]: https://setuptools.pypa.io/en/latest/userguide/dependency_management.html#direct-url-dependencies [environment variable]: https://en.wikipedia.org/wiki/Environment_variable [extension]: https://plover.readthedocs.io/en/latest/plugin-dev/extensions.html [Get started with 1Password CLI]: https://developer.1password.com/docs/cli/get-started/ -[Git]: https://git-scm.com/ +[git]: https://git-scm.com/ [Invoke Plover from the command line]: https://github.com/openstenoproject/plover/wiki/Invoke-Plover-from-the-command-line [`just`]: https://github.com/casey/just [`justfile`]: ./test/justfile @@ -262,9 +228,7 @@ plover --script plover_plugins uninstall plover-1password [meta]: https://plover.readthedocs.io/en/latest/plugin-dev/metas.html [move or copy items]: https://support.1password.com/move-copy-items/ [Mypy]: https://github.com/python/mypy -[pip]: https://pip.pypa.io/en/stable/ [plover-1password project file]: https://github.com/paulfioravanti/dotfiles/blob/master/tmuxinator/plover_1password.yml -[PyPI]: https://pypi.org/ [PyPI downloads image]: https://img.shields.io/pypi/dm/plover-1password [PyPI version image]: https://img.shields.io/pypi/v/plover-1password [PyPI url]: https://pypi.org/project/plover-1password/ @@ -280,7 +244,5 @@ plover --script plover_plugins uninstall plover-1password [secret references]: https://developer.1password.com/docs/cli/secret-reference-syntax/ [Setup]: ./#Setup [syntax rules]: https://developer.1password.com/docs/cli/secret-reference-syntax/#syntax-rules -[this GitHub issue]: https://github.com/1Password/onepassword-sdk-python/issues/107 -[this issue]: https://github.com/paulfioravanti/plover-1password/issues/1 [Tmuxinator]: https://github.com/tmuxinator/tmuxinator [`workflow_context.yml`]: https://github.com/openstenoproject/plover/blob/master/.github/workflows/ci/workflow_context.yml diff --git a/setup.cfg b/setup.cfg index 4ad8e06..3337066 100644 --- a/setup.cfg +++ b/setup.cfg @@ -21,6 +21,7 @@ version = attr: plover_1password.__version__ zip_safe = True install_requires = plover >= 4.0.0.dev12 + onepassword-sdk >= 0.1.2 setup_requires = setuptools >= 30.3.0 package_dir = @@ -35,6 +36,7 @@ plover.extension = test = coverage mypy + onepassword-sdk pylint pytest pytest-asyncio @@ -44,9 +46,6 @@ test = [options.packages.find] where = src -[tool:pytest] -pythonpath = plover_1password - [mypy] strict = True diff --git a/src/plover_1password/__version__.py b/src/plover_1password/__version__.py index c0f8dd0..71e7cff 100644 --- a/src/plover_1password/__version__.py +++ b/src/plover_1password/__version__.py @@ -2,4 +2,4 @@ Version attribute """ -__version__ = "0.3.18" +__version__ = "0.4.0"