[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
160/361: gnu: dynaconf: Improve package style.
From: |
guix-commits |
Subject: |
160/361: gnu: dynaconf: Improve package style. |
Date: |
Fri, 22 Nov 2024 06:00:32 -0500 (EST) |
andreas pushed a commit to branch python-team
in repository guix.
commit ea84bc7ff86c0a78ac66c00be93c12eed18f3fe3
Author: Nicolas Graves <ngraves@ngraves.fr>
AuthorDate: Fri May 10 00:53:22 2024 +0200
gnu: dynaconf: Improve package style.
* gnu/packages/python-xyz.scm (dynaconf): Improve package-style and
ignore coverage tests.
[origin](snippet): More concise snippet. Remove coverage management.
[arguments]<#:test-flags>: Add arguments from former check
replacement phase.
<#:phases>: Remove check replacement phase.
Change-Id: I2a0e0a8dea5000aecc05707c35d307c867c96709
Signed-off-by: Nicolas Goaziou <mail@nicolasgoaziou.fr>
---
gnu/packages/python-xyz.scm | 42 ++++++++++++++----------------------------
1 file changed, 14 insertions(+), 28 deletions(-)
diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm
index 2e9fe797cb..08672fa25d 100644
--- a/gnu/packages/python-xyz.scm
+++ b/gnu/packages/python-xyz.scm
@@ -36302,43 +36302,29 @@ Python @code{set} interface.")
"0fj2ffvzfvjf4d7f672h5x5fzq26f8hax9j3dfsix158fwm0212w"))
(patches (search-patches "dynaconf-unvendor-deps.patch"))
(modules '((guix build utils)))
- (snippet '(begin
- ;; Remove vendored dependencies
- (let ((unvendor '("click" "dotenv" "ruamel" "toml")))
- (with-directory-excursion "dynaconf/vendor"
- (for-each delete-file-recursively unvendor)))
- ;; Lower coverage quality gate for unit tests
- (substitute* ".coveragerc"
- (("fail_under = 95") "fail_under = 50"))))))
+ ;; Remove vendored dependencies
+ (snippet '(let ((unvendor '("click" "dotenv" "ruamel" "toml")))
+ (with-directory-excursion "dynaconf/vendor"
+ (for-each delete-file-recursively unvendor))))))
(build-system pyproject-build-system)
(arguments
`(#:test-flags
- '("-k"
- ,(let ((click-tests '("test_negative_get"
- "test_inspect_invalid_format")))
- ;; Disable integration tests
- (string-append "not integration and not "
- ;; These tests fail because we use Click 8.*
instead of
- ;; Click 7
- (string-join click-tests " and not "))))
+ '("--ignore=tests/test_vault.py" ; depend on hvac and a live Vault
+ "-k" ,(let ((click-tests '("test_negative_get"
+ "test_inspect_invalid_format")))
+ ;; Disable integration tests
+ (string-append "not integration and not "
+ ;; These tests fail because we use Click 8.*
+ ;; instead of Click 7
+ (string-join click-tests " and not ")))
+ "tests")
#:phases
(modify-phases %standard-phases
(add-after 'unpack 'patch-for-click-8
(lambda _
(substitute* "dynaconf/cli.py"
(("click.get_os_args\\()") ;deprecated from Click 8.1+
- "sys.argv[1:]"))))
- (replace 'check
- (lambda* (#:key tests? test-flags #:allow-other-keys)
- (when tests?
- ;; These tests depend on hvac and a live Vault process.
- (delete-file "tests/test_vault.py")
- (apply invoke
- `("py.test" ,@test-flags "-v"
- "--cov-config" ".coveragerc"
- "--cov=dynaconf"
- "-l" "--tb=short"
- "--maxfail=1" "tests/"))))))))
+ "sys.argv[1:]")))))))
(propagated-inputs
(list python-click python-configobj python-dotenv-0.13.0
python-ruamel.yaml-0.16 python-toml python-tomli))
- 297/361: gnu: python-pluggy: Update to 1.5.0., (continued)
- 297/361: gnu: python-pluggy: Update to 1.5.0., guix-commits, 2024/11/22
- 300/361: gnu: Remove python-pytest-8., guix-commits, 2024/11/22
- 313/361: gnu: python-pytest-xprocess: Update to 1.0.2., guix-commits, 2024/11/22
- 326/361: gnu: python-packaging-bootstrap: Update to 24.2., guix-commits, 2024/11/22
- 328/361: gnu: python-hatchling: Update to 1.26.1., guix-commits, 2024/11/22
- 331/361: gnu: python-attrs: Update to 24.2.0., guix-commits, 2024/11/22
- 360/361: gnu: python-dirty-equals: Update to 0.8.0., guix-commits, 2024/11/22
- 358/361: gnu: python-pytest-httpbin: Update to 2.1.0., guix-commits, 2024/11/22
- 104/361: gnu: python-requests: Update to 2.31.0., guix-commits, 2024/11/22
- 127/361: gnu: python-pyls-black: Add missing input., guix-commits, 2024/11/22
- 160/361: gnu: dynaconf: Improve package style.,
guix-commits <=
- 217/361: gnu: python-qemu-qmp: Move to pyproject-build-system., guix-commits, 2024/11/22
- 225/361: gnu: python-array-api-compat: Update to 1.9.1., guix-commits, 2024/11/22
- 231/361: gnu: python-daft: Adjust inputs., guix-commits, 2024/11/22
- 235/361: gnu: python-lazy-loader: Adjust inputs., guix-commits, 2024/11/22
- 228/361: gnu: python-automat: Update to 22.10.0., guix-commits, 2024/11/22
- 239/361: gnu: python-requests-toolbelt: Update to 1.0.0., guix-commits, 2024/11/22
- 242/361: gnu: python-requests-unixsocket: Fix build., guix-commits, 2024/11/22
- 241/361: gnu: python-waitress: Adjust inputs., guix-commits, 2024/11/22
- 248/361: gnu: Add python-pytest-html., guix-commits, 2024/11/22
- 240/361: gnu: python-responses: Update to 0.25.3., guix-commits, 2024/11/22