From: icp1994 <icp1994@users.noreply.github.com>
To: ml@inbox.vuxu.org
Subject: [PR PATCH] black: update to 22.3.0.
Date: Sat, 25 Jun 2022 08:35:55 +0200 [thread overview]
Message-ID: <gh-mailinglist-notifications-41a7ca26-5023-4802-975b-f1789d68868e-void-packages-37676@inbox.vuxu.org> (raw)
[-- Attachment #1: Type: text/plain, Size: 947 bytes --]
There is a new pull request by icp1994 against master on the void-packages repository
https://github.com/icp1994/void-packages black
https://github.com/void-linux/void-packages/pull/37676
black: update to 22.3.0.
#### Testing the changes
- I tested the changes in this PR: **YES**|**briefly**|**NO**
#### Local build testing
- I built this PR locally for my native architecture, x86_64
Supersedes https://github.com/void-linux/void-packages/pull/34520. As I mentioned in a comment there, I had to run the tests twice (with jupyter dependencies enabled/disabled) in accordance with the [upstream testing](https://github.com/psf/black/blob/ae2c0758c9e61a385df9700dc9c231bf54887041/tox.ini#L37). I don't know how to remove a dependency installed via `checkdepends` temporarily in `do_check()`. So I moved the module "manually" out of site-packages.
A patch file from https://github.com/void-linux/void-packages/pull/37676.patch is attached
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-black-37676.patch --]
[-- Type: text/x-diff, Size: 2664 bytes --]
From f4d5ebb41219c28b6d724eeec4f368f88f0472c6 Mon Sep 17 00:00:00 2001
From: icp <pangolin@vivaldi.net>
Date: Sat, 25 Jun 2022 11:57:04 +0530
Subject: [PATCH] black: update to 22.3.0.
---
srcpkgs/black/template | 30 ++++++++++++++----------------
1 file changed, 14 insertions(+), 16 deletions(-)
diff --git a/srcpkgs/black/template b/srcpkgs/black/template
index b17749777fb0..c197da7cc670 100644
--- a/srcpkgs/black/template
+++ b/srcpkgs/black/template
@@ -1,30 +1,28 @@
# Template file for 'black'
pkgname=black
-version=21.9b0
-revision=2
+version=22.3.0
+revision=1
build_style=python3-module
-# Disable tests that require `black` in the search path for commands.
-make_check_args="--deselect tests/test_primer.py::PrimerLibTests::test_gen_check_output
- --deselect tests/test_primer.py::PrimerLibTests::test_process_queue
- --deselect tests/test_primer.py::PrimerCLITests::test_async_main"
hostmakedepends="python3-setuptools python3-setuptools_scm"
-depends="python3-click python3-platformdirs python3-tomli
- python3-mypy_extensions python3-pathspec python3-regex
- python3-typing_extensions"
-checkdepends="python3-typed-ast python3-aiohttp python3-aiohttp-cors
- python3-pytest python3-parameterized python3-ipython python3-tokenize-rt
- $depends"
+depends="python3-click python3-platformdirs python3-tomli python3-pathspec python3-mypy_extensions"
+checkdepends="${depends} python3-pytest-xdist python3-aiohttp python3-colorama python3-uvloop
+ python3-ipython python3-tokenize-rt"
short_desc="Uncompromising Python code formatter"
maintainer="Orphaned <orphan@voidlinux.org>"
license="MIT"
homepage="https://github.com/psf/black"
changelog="https://raw.githubusercontent.com/psf/black/main/CHANGES.md"
distfiles="${PYPI_SITE}/b/black/black-${version}.tar.gz"
-checksum=7de4cfc7eb6b710de325712d40125689101d21d25283eed7e9998722cf10eb91
+checksum=35020b8886c022ced9282b51b5a875b6d1ab0c387b31a065b84db7c33085ca79
-pre_build() {
- # <https://gitweb.gentoo.org/repo/gentoo.git/tree/dev-python/black/black-21.8_beta0.ebuild#n45>.
- vsed -i '/setuptools_scm/s:~=:>=:' setup.cfg
+do_check() {
+ PYTHONPATH="$(cd build/lib* && pwd)" python3 -m pytest --run-optional jupyter \
+ -m jupyter --deselect=tests/test_ipynb.py::test_set_input
+
+ pyver=$(python3 -c 'import sys; print(f"{sys.version_info.major}.{sys.version_info.minor}")')
+ mv ${XBPS_MASTERDIR}/usr/lib/python${pyver}/site-packages/IPython ${XBPS_MASTERDIR}/tmp/IPython.bak
+ PYTHONPATH="$(cd build/lib* && pwd)" python3 -m pytest --run-optional no_jupyter
+ mv ${XBPS_MASTERDIR}/tmp/IPython.bak ${XBPS_MASTERDIR}/usr/lib/python${pyver}/site-packages/IPython
}
post_install() {
next reply other threads:[~2022-06-25 6:35 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-06-25 6:35 icp1994 [this message]
2022-06-25 15:21 ` [PR PATCH] [Merged]: " leahneukirchen
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=gh-mailinglist-notifications-41a7ca26-5023-4802-975b-f1789d68868e-void-packages-37676@inbox.vuxu.org \
--to=icp1994@users.noreply.github.com \
--cc=ml@inbox.vuxu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).