Path: csiph.com!news.mixmin.net!aioe.org!bofh.it!news.nic.it!robomod From: Piotr =?utf-8?Q?O=C5=BCarowski?= Newsgroups: linux.debian.maint.python Subject: Re: Packaging with 2to3 Date: Tue, 19 Dec 2017 13:40:02 +0100 Message-ID: References: X-Original-To: debian-python@lists.debian.org X-Mailbox-Line: From debian-python-request@lists.debian.org Tue Dec 19 12:31:52 2017 Old-Return-Path: X-Amavis-Spam-Status: No, score=-6.979 tagged_above=-10000 required=5.3 tests=[BAYES_00=-2, HEADER_FROM_DIFFERENT_DOMAINS=0.001, LDO_WHITELIST=-5, MURPHY_DRUGS_REL8=0.02] autolearn=ham autolearn_force=no X-Policyd-Weight: using cached result; rate: -6.1 Mail-Followup-To: debian-python@lists.debian.org MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline X-Operating-System: Debian GNU/Linux (4.11.0-0.bpo.1-amd64) User-Agent: NeoMutt/20171208 X-Mailing-List: archive/latest/15411 List-ID: List-URL: List-Archive: https://lists.debian.org/msgid-search/20171219123133.ma7hv6en4v6i7jlp@sar0.p1otr.com Approved: robomod@news.nic.it Lines: 16 Organization: linux.* mail to news gateway Sender: robomod@news.nic.it X-Original-Date: Tue, 19 Dec 2017 13:31:33 +0100 X-Original-Message-ID: <20171219123133.ma7hv6en4v6i7jlp@sar0.p1otr.com> X-Original-References: <87wp1jenho.fsf@debian.org> Xref: csiph.com linux.debian.maint.python:10016 [Michael Hudson-Doyle, 2017-12-19] > > I want to create a package (pyraf, #711038) for both Python2 and > > Python3. While the package itself is still not Python 3 compatible, > > upstream says that running through 2to3 will make it; however the > > resulting code is not Python 2 compatible anymore. > > > > Is there a way to instruct pybuild to run the Python 3 code through > > 2to3? > > python-urwid does this, by passing use_2to3 to the distutils setup() > function, I guess you could patch it to do the same. if you need 2to3 for tests as well, see: https://wiki.debian.org/Python/Pybuild#line-148 -- GPG: 1D2F A898 58DA AF62 1786 2DF7 AEF6 F1A2 A745 7645