From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp0 ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms11 with LMTPS id EOUIKjdKzF4qJQAA0tVLHw (envelope-from ) for ; Mon, 25 May 2020 22:44:07 +0000 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp0 with LMTPS id oCnoJTdKzF5vWQAA1q6Kng (envelope-from ) for ; Mon, 25 May 2020 22:44:07 +0000 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 335E19400AF for ; Mon, 25 May 2020 22:44:07 +0000 (UTC) Received: from localhost ([::1]:58608 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jdLpF-0001lg-QQ for larch@yhetil.org; Mon, 25 May 2020 18:44:05 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:43022) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jdLpC-0001lO-F5 for guix-patches@gnu.org; Mon, 25 May 2020 18:44:02 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:59444) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jdLpC-0004lW-6F for guix-patches@gnu.org; Mon, 25 May 2020 18:44:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1jdLpC-0001Kb-5A for guix-patches@gnu.org; Mon, 25 May 2020 18:44:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#41455] [PATCH 1/2] gnu: Add python-libtmux Resent-From: Marius Bakke Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Mon, 25 May 2020 22:44:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 41455 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: Edouard Klein , 41455@debbugs.gnu.org Received: via spool by 41455-submit@debbugs.gnu.org id=B41455.15904466005042 (code B ref 41455); Mon, 25 May 2020 22:44:02 +0000 Received: (at 41455) by debbugs.gnu.org; 25 May 2020 22:43:20 +0000 Received: from localhost ([127.0.0.1]:42753 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jdLoW-0001JG-Bx for submit@debbugs.gnu.org; Mon, 25 May 2020 18:43:20 -0400 Received: from eggs.gnu.org ([209.51.188.92]:35552) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jdLoV-0001J4-0U for 41455@debbugs.gnu.org; Mon, 25 May 2020 18:43:19 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:59000) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jdLoP-0004i5-JN; Mon, 25 May 2020 18:43:13 -0400 Received: from ti0006q161-2604.bb.online.no ([84.202.68.75]:39812 helo=localhost) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1jdLoO-0004IK-M3; Mon, 25 May 2020 18:43:13 -0400 From: Marius Bakke In-Reply-To: <87y2pgiclc.fsf@alice.lan> References: <87d06wazez.fsf@alice.lan> <87y2pgiclc.fsf@alice.lan> Date: Tue, 26 May 2020 00:43:10 +0200 Message-ID: <87pnar63gh.fsf@gnu.org> MIME-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha512; protocol="application/pgp-signature" X-Spam-Score: -2.3 (--) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-Spam-Score: -3.3 (---) X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+larch=yhetil.org@gnu.org Sender: "Guix-patches" X-Scanner: scn0 Authentication-Results: aspmx1.migadu.com; dkim=none; dmarc=none; spf=pass (aspmx1.migadu.com: domain of guix-patches-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=guix-patches-bounces@gnu.org X-Spam-Score: -0.61 X-TUID: wci/KoKH0J1x --=-=-= Content-Type: text/plain Content-Transfer-Encoding: quoted-printable Edouard Klein writes: > * gnu/packages/check.scm (python-pytest-4): New variable. > * gnu/packages/tmux.scm (python-libtmux): New variable. Thanks! Can you submit these as two separate patches? > + (native-inputs > + `(("python-setuptools-scm" ,python-setuptools-scm) > + ("git" ,git))) > + (arguments `(#:phases > + (modify-phases %standard-phases > + (add-after 'unpack 'git-tag > + (lambda _ > + ;; setuptools-scm needs to know the version > + (invoke "git" "init") > + (invoke "git" "add" ".") > + (invoke "git" "config" "user.name" "John Doe") > + (invoke "git" "config" "user.email" "nobody@examp= le.com") > + (invoke "git" "commit" "-m" "dummy commit") > + (invoke "git" "tag" ,version)))))) This is weird, we haven't needed this before. Is there a way to avoid the dependency on git here? In the worst case maybe we can create ".git/refs/tags/,version" manually? :-/ Also, please make this inherit from pytest instead of duplicating all the fields. [...] =20=20 > +(define-public python-libtmux > + (package > + (name "python-libtmux") > + (version "0.8.2") > + (source > + (origin > + (method git-fetch) > + ;; Pypi source tarball does not include tests > + (uri (git-reference > + (url "https://github.com/tmux-python/libtmux.git") > + (commit (string-append "v" version)))) > + (file-name "python-libtmux") > + (sha256 > + (base32 > + "1akjv6aqpc690c4l2cjh0fxbpxxg63sfjggapfjjjaqmcl38g1dz")))) > + (build-system python-build-system) > + (propagated-inputs > + `(("python-pytest-4" ,python-pytest-4) Do you know if pytest 4 is really needed? Often Python packages pin a specific version for no good reason, and one can simply substitute "=3D=3D" with ">=3D" in setup.py and it's all good. > + ("tmux" ,tmux) Even though this is useless without tmux, I'm not sure if we should propagate it. Some users might have custom versions of tmux, but would still want to use this library. WDYT? > + ("procps" ,procps))) ;; Tests need top ^ only one semicolon for margin comments ;typically without a space, like this > + (arguments > + `(#:phases > + (modify-phases %standard-phases > + (replace 'check > + (lambda _ > + ;; Extend PYTHONPATH so the built package will be found. > + (setenv "PYTHONPATH" > + (string-append (getcwd) "/build/lib:" > + (getenv "PYTHONPATH"))) > + ;; Skip tests that I suspect fail because of a change > + ;; in behavior in tmux 3 from tmux 2 > + ;; https://github.com/tmux-python/libtmux/issues/281 > + (invoke "pytest" "-vv" "-k" > + (string-append "not test_show_option_unknown " > + "and not test_show_window_option_unk= nown")) > + #t))))) > + (home-page > + "https://github.com/tmux-python/libtmux") This line break is unnecessary. Otherwise looks good. Can you send updated patches? --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQEzBAEBCgAdFiEEu7At3yzq9qgNHeZDoqBt8qM6VPoFAl7MSf4ACgkQoqBt8qM6 VPopWAf8C5GSdQz00GcRPaO/WqO01W+WXLVmiAh2j//0UTgAq7uZraXOaRc4Im3v eLMzPqBbeyyZ6WJUKFftK+o0Q7DzjKoNRWWECFsjajCTdgRqUWwyIKTJxz4rDsRR BnjSTOFy+/TkSvT+bZnztFNRVR49JSFQhQaP7HTUUj3LKmIopFfNWrkJuYmlJDjB 9pyI+d6S1QShUmIMTlrc3O/B6uO6IEY1LNqCFZXGe8BVcDcQZ6+A42bKVOJk/uYC 5ymB3x17lofMkku4v8ZAc9T/snzzkWeMl0B+T1P7b9fDEetrbxND/k0tq/CW3ifb mewsa9leFldUA+7Ea3p3vusD5flKeA== =LZC0 -----END PGP SIGNATURE----- --=-=-=--