* [gentoo-python] python_get_version replacement @ 2013-08-26 1:51 Mike Gilbert 2013-08-26 20:21 ` Michał Górny 0 siblings, 1 reply; 4+ messages in thread From: Mike Gilbert @ 2013-08-26 1:51 UTC (permalink / raw To: gentoo-python I just committed this somewhat ugly code in twisted-core-13.0.0-r2.ebuild. # Bug 299736 local pyver=$("${PYTHON}" -c 'import sys; print("%d.%d" % sys.version_info[:2])') touch "${D%/}${PYTHON_SITEDIR}/Twisted-${PV}-py${pyver}.egg-info" This takes the place of a python_get_version -l call from the old python.eclass. Is this something that we should provide in the new eclasses? ^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [gentoo-python] python_get_version replacement 2013-08-26 1:51 [gentoo-python] python_get_version replacement Mike Gilbert @ 2013-08-26 20:21 ` Michał Górny 2013-08-26 21:11 ` Mike Gilbert 0 siblings, 1 reply; 4+ messages in thread From: Michał Górny @ 2013-08-26 20:21 UTC (permalink / raw To: Mike Gilbert; +Cc: gentoo-python [-- Attachment #1: Type: text/plain, Size: 729 bytes --] Dnia 2013-08-25, o godz. 21:51:17 Mike Gilbert <floppym@gentoo.org> napisał(a): > I just committed this somewhat ugly code in twisted-core-13.0.0-r2.ebuild. > > # Bug 299736 > local pyver=$("${PYTHON}" -c 'import sys; print("%d.%d" % > sys.version_info[:2])') > touch "${D%/}${PYTHON_SITEDIR}/Twisted-${PV}-py${pyver}.egg-info" > > This takes the place of a python_get_version -l call from the old python.eclass. > > Is this something that we should provide in the new eclasses? I don't really feel like we should be touching egg-info like this. By the way, doesn't the 'bundle' egg-info imply pulling in all Twisted packages rather than -core itself? -- Best regards, Michał Górny [-- Attachment #2: signature.asc --] [-- Type: application/pgp-signature, Size: 966 bytes --] ^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [gentoo-python] python_get_version replacement 2013-08-26 20:21 ` Michał Górny @ 2013-08-26 21:11 ` Mike Gilbert 2013-08-26 21:22 ` Michał Górny 0 siblings, 1 reply; 4+ messages in thread From: Mike Gilbert @ 2013-08-26 21:11 UTC (permalink / raw To: Michał Górny; +Cc: gentoo-python On Mon, Aug 26, 2013 at 4:21 PM, Michał Górny <mgorny@gentoo.org> wrote: > Dnia 2013-08-25, o godz. 21:51:17 > Mike Gilbert <floppym@gentoo.org> napisał(a): > >> I just committed this somewhat ugly code in twisted-core-13.0.0-r2.ebuild. >> >> # Bug 299736 >> local pyver=$("${PYTHON}" -c 'import sys; print("%d.%d" % >> sys.version_info[:2])') >> touch "${D%/}${PYTHON_SITEDIR}/Twisted-${PV}-py${pyver}.egg-info" >> >> This takes the place of a python_get_version -l call from the old python.eclass. >> >> Is this something that we should provide in the new eclasses? > > I don't really feel like we should be touching egg-info like this. > > By the way, doesn't the 'bundle' egg-info imply pulling in all Twisted > packages rather than -core itself? > You could look at it that way; however, we also need to keep in mind that it was designed for easy_install / pip. As well, the download page[1] at Twisted upstream literally says "You probably don't want these unless you have special consideration" in the section containing the individual project tarballs, so our installation method could already be considered non-standard. With portage, we express more precise dependencies at the ebuild level, so the dependencies that end up in egg-info/requires.txt are largely irrelevant. The above code just fakes it out so that pkg_requires doesn't throw an exception. An alternative would be to patch setup.py for any package which sets install_requires="Twisted". Said patches would probably not be accepted by any upstream. [1] http://twistedmatrix.com/trac/wiki/Downloads ^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [gentoo-python] python_get_version replacement 2013-08-26 21:11 ` Mike Gilbert @ 2013-08-26 21:22 ` Michał Górny 0 siblings, 0 replies; 4+ messages in thread From: Michał Górny @ 2013-08-26 21:22 UTC (permalink / raw To: Mike Gilbert; +Cc: gentoo-python [-- Attachment #1: Type: text/plain, Size: 1785 bytes --] Dnia 2013-08-26, o godz. 17:11:12 Mike Gilbert <floppym@gentoo.org> napisał(a): > On Mon, Aug 26, 2013 at 4:21 PM, Michał Górny <mgorny@gentoo.org> wrote: > > Dnia 2013-08-25, o godz. 21:51:17 > > Mike Gilbert <floppym@gentoo.org> napisał(a): > > > >> I just committed this somewhat ugly code in twisted-core-13.0.0-r2.ebuild. > >> > >> # Bug 299736 > >> local pyver=$("${PYTHON}" -c 'import sys; print("%d.%d" % > >> sys.version_info[:2])') > >> touch "${D%/}${PYTHON_SITEDIR}/Twisted-${PV}-py${pyver}.egg-info" > >> > >> This takes the place of a python_get_version -l call from the old python.eclass. > >> > >> Is this something that we should provide in the new eclasses? > > > > I don't really feel like we should be touching egg-info like this. > > > > By the way, doesn't the 'bundle' egg-info imply pulling in all Twisted > > packages rather than -core itself? > > > > You could look at it that way; however, we also need to keep in mind > that it was designed for easy_install / pip. As well, the download > page[1] at Twisted upstream literally says "You probably don't want > these unless you have special consideration" in the section containing > the individual project tarballs, so our installation method could > already be considered non-standard. > > With portage, we express more precise dependencies at the ebuild > level, so the dependencies that end up in egg-info/requires.txt are > largely irrelevant. The above code just fakes it out so that > pkg_requires doesn't throw an exception. Ok, I see. Yet another Python project management screwup ;/. Can we get setup.py to create the egg-info file in a more friendly way? Like adding something to packages or so on? -- Best regards, Michał Górny [-- Attachment #2: signature.asc --] [-- Type: application/pgp-signature, Size: 966 bytes --] ^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2013-08-26 21:21 UTC | newest] Thread overview: 4+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2013-08-26 1:51 [gentoo-python] python_get_version replacement Mike Gilbert 2013-08-26 20:21 ` Michał Górny 2013-08-26 21:11 ` Mike Gilbert 2013-08-26 21:22 ` Michał Górny
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox