Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 62128 - platform module doesnt exist in python-2.2.x
Summary: platform module doesnt exist in python-2.2.x
Status: RESOLVED FIXED
Alias: None
Product: Portage Development
Classification: Unclassified
Component: Core - Interface (emerge) (show other bugs)
Hardware: All All
: High normal (vote)
Assignee: Portage team
URL:
Whiteboard:
Keywords: InVCS
Depends on:
Blocks:
 
Reported: 2004-08-29 11:43 UTC by SpanKY
Modified: 2004-10-22 08:47 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description SpanKY gentoo-dev 2004-08-29 11:43:52 UTC
the platform module is only used in 'emerge' and only to call uname() ...

with python-2.2.x, the platform module does not exist ... but in all python versions so far (2.[2-4].x), os.uname() exists

the only different is the 5th and last field (the processor, or `uname -p`)

jstubbs mentioned that we dont *really* need that field ... so we have two choices:
- dont refer to platform module and call os.uname() and dont include the 5th field
- require python-2.3.x with portage-2.0.51*

in the future i have no problem requiring a newer version of python to use portage if the features used are significant, but atm, this seems like a weak reason to require a newer version of python

example output for you to ponder over:
root@vapier 0 ~ # python -c 'import os; print os.uname()'
('Linux', 'vapier', '2.6.8.1', '#156 SMP Sun Aug 22 23:15:54 EDT 2004', 'i686')
root@vapier 0 ~ # python -c 'import platform; print platform.uname()'
('Linux', 'vapier', '2.6.8.1', '#156 SMP Sun Aug 22 23:15:54 EDT 2004', 'i686', 'Intel(R) Pentium(R) 4 CPU 1.80GHz')

emerge does:
unameout=platform.uname()[2]+" "+platform.uname()[4]+" "+platform.uname()[5]
Comment 1 Jason Stubbs (RETIRED) gentoo-dev 2004-08-30 03:38:29 UTC
Done.
Comment 2 Nicholas Jones (RETIRED) gentoo-dev 2004-10-22 08:47:58 UTC
Bug has been fixed and released in stable portages on or before 2.0.51-r2