Opened 4 years ago

Closed 4 years ago

#6040 enhancement closed fixed (fixed)

on Python 3, make setup.py install the modules that have been ported to Python 3

Reported by: Itamar Turner-Trauring Owned by: Jean-Paul Calderone
Priority: normal Milestone: Python 3.3 Minimal
Component: core Keywords:
Cc: Branch: branches/setup-py3-6040-4
branch-diff, diff-cov, branch-cov, buildbot
Author: exarkun

Description

setup.py on Python 3 should install all modules that have been ported.

Unfortunately tests probably won't run out of an installed twisted package, since a few of the test modules rely on modules that haven't been ported yet, but that should resolve itself over time.

Change History (13)

comment:1 Changed 4 years ago by Jean-Paul Calderone

I love issues that resolve themselves.

comment:2 Changed 4 years ago by Jean-Paul Calderone

Summary: setup.py should run on Python 3on Python 3, make setup.py install the modules that have been ported to Python 3

comment:3 Changed 4 years ago by Jean-Paul Calderone

Owner: set to Jean-Paul Calderone
Status: newassigned

comment:4 Changed 4 years ago by Jean-Paul Calderone

Author: exarkun
Branch: branches/setup-py3-6040

(In [36073]) Branching to 'setup-py3-6040'

comment:5 Changed 4 years ago by Jean-Paul Calderone

Branch: branches/setup-py3-6040branches/setup-py3-6040-2

(In [36103]) Branching to 'setup-py3-6040-2'

comment:6 Changed 4 years ago by Jean-Paul Calderone

Branch: branches/setup-py3-6040-2branches/setup-py3-6040-3

(In [36159]) Branching to 'setup-py3-6040-3'

comment:7 Changed 4 years ago by Jean-Paul Calderone

Keywords: review added
Owner: changed from Jean-Paul Calderone to Itamar Turner-Trauring
Status: assignednew

Eh, well, this still doesn't produce a distribution you can run the tests on, because at least twisted.internet.posixbase is still missing from the ported list. However, I guess that situation will be remedied whenever posixbase does get added to that list, without any further changes needed to this new setup script. So perhaps it's worth just landing this now (of course this could be irrational optimism and it may turn out that even once all the modules are available there is something else missing...).

Anyway, I'll let you take a look and see what you think.

comment:8 Changed 4 years ago by Itamar Turner-Trauring

Note that even with posixbase, we'll have issues running all of tests out of the installed version. Specifically, some of ported trial tests depend on importing some other trial modules that haven't yet been ported.

comment:9 Changed 4 years ago by Jean-Paul Calderone

I propose that we add a third category of module, then. Not-really-ported-but-needed-by-ported. Otherwise we're never going to be able to run tests on the package we're generating and we won't have a very good idea of whether the package actually works or not.

comment:10 Changed 4 years ago by Itamar Turner-Trauring

Keywords: review removed
Owner: changed from Itamar Turner-Trauring to Jean-Paul Calderone

Thanks for figuring this out.

  1. News file; maybe setup3.py is actually worth mentioning there?
  2. future imports in setup3.py.
  3. The moved getAllScripts looks like it needs a test? You could just open a ticket for that, since it's unchanged in Python 2 and unused in Python 3.
  4. Having a third category makes sense, yes. You should add all modules necessary for tests to run. Hopefully just trial stuff (I'm going to merge posixbase next).
  5. I was actually going to add abstract.py with a new ticket that also covered twisted.test.test_abstract; you can move it to not-really-ported list, or leave it where it is, up to you.

Fix, then merge.

comment:11 Changed 4 years ago by Jean-Paul Calderone

Branch: branches/setup-py3-6040-3branches/setup-py3-6040-4

(In [36194]) Branching to 'setup-py3-6040-4'

comment:12 Changed 4 years ago by Jean-Paul Calderone

Thanks!

News file; maybe setup3.py is actually worth mentioning there?

r36191

future imports in setup3.py.

r36192

The moved getAllScripts looks like it needs a test? You could just open a ticket for that, since it's unchanged in Python 2 and unused in Python 3.

Filed #6137

Having a third category makes sense, yes. You should add all modules necessary for tests to run. Hopefully just trial stuff (I'm going to merge posixbase next). I was actually going to add abstract.py with a new ticket that also covered twisted.test.test_abstract; you can move it to not-really-ported list, or leave it where it is, up to you.

r36193, r36196, and r36197

comment:13 Changed 4 years ago by Jean-Paul Calderone

Resolution: fixed
Status: newclosed

(In [36198]) Merge setup-py3-6040-4

Author: exarkun Reviewer: itamarst Fixes: #6040

Add setup3.py script which can package and install a subset of Twisted on Python 3.

Note: See TracTickets for help on using tickets.