Issue1954

classification
Title: Fix for broken distribute_setup.py call to os.umask on Windows
Type: behaviour Severity: normal
Components: Library Versions: 2.7a2
Milestone:
process
Status: closed Resolution: fixed
Dependencies: Superseder:
Assigned To: fwierzbicki Nosy List: amak, fwierzbicki, varialus
Priority: normal Keywords:

Created on 2012-07-31.22:20:30 by varialus, last changed 2013-02-05.21:22:56 by fwierzbicki.

Messages
msg7343 (view) Author: Varialus (varialus) Date: 2012-07-31.22:20:28
I get an error while trying to run distribute_setup.py on Windows because os has no attribute umask. The following pull request resolves the issue.

https://bitbucket.org/jython/jython/pull-request/2/updated-java-native-runtime-jars-to-latest

Here's the stack trace that I get while trying to run distribute_setup.py from Jython 2.7a2. I get the same stack trace from the the unpatched development build.

Installing easy_install-2.7 script to C:\jython2.7a2\bin
Traceback (most recent call last):
  File "setup.py", line 159, in <module>
    for cmd in SETUP_COMMANDS
  File "C:\jython2.7a2\Lib\distutils\core.py", line 152, in setup
    dist.run_commands()
  File "C:\jython2.7a2\Lib\distutils\core.py", line 152, in setup
    dist.run_commands()
  File "C:\jython2.7a2\Lib\distutils\dist.py", line 953, in run_commands
    self.run_command(cmd)
  File "C:\jython2.7a2\Lib\distutils\dist.py", line 972, in run_command
    cmd_obj.run()
  File "C:\Documents and Settings\user\Local Settings\Temp\tmppy0bej\distribute-0.6.28\setuptools\command\install.py", line 73, in run
    self.do_egg_install()
  File "C:\Documents and Settings\user\Local Settings\Temp\tmppy0bej\distribute-0.6.28\setuptools\command\install.py", line 101, in do_egg_install
    cmd.run()
  File "C:\Documents and Settings\user\Local Settings\Temp\tmppy0bej\distribute-0.6.28\setuptools\command\easy_install.py", line 358, in run
    self.easy_install(spec, not self.no_deps)
  File "C:\Documents and Settings\user\Local Settings\Temp\tmppy0bej\distribute-0.6.28\setuptools\command\easy_install.py", line 578, in easy_install
    return self.install_item(None, spec, tmpdir, deps, True)
  File "C:\Documents and Settings\user\Local Settings\Temp\tmppy0bej\distribute-0.6.28\setuptools\command\easy_install.py", line 630, in install_item
    self.process_distribution(spec, dist, deps)
  File "C:\Documents and Settings\user\Local Settings\Temp\tmppy0bej\distribute-0.6.28\setuptools\command\easy_install.py", line 659, in process_distribution
    self.install_egg_scripts(dist)
  File "C:\Documents and Settings\user\Local Settings\Temp\tmppy0bej\distribute-0.6.28\setuptools\command\easy_install.py", line 529, in install_egg_scripts
    self.install_wrapper_scripts(dist)
  File "C:\Documents and Settings\user\Local Settings\Temp\tmppy0bej\distribute-0.6.28\setuptools\command\easy_install.py", line 734, in install_wrapper_scripts
    self.write_script(*args)
  File "C:\Documents and Settings\user\Local Settings\Temp\tmppy0bej\distribute-0.6.28\setuptools\command\easy_install.py", line 773, in write_script
    mask = current_umask()
  File "C:\Documents and Settings\user\Local Settings\Temp\tmppy0bej\distribute-0.6.28\setuptools\command\easy_install.py", line 1883, in current_umask
    tmp = os.umask(022)
AttributeError: 'module' object has no attribute 'umask'
Something went wrong during the installation.
See the error message above.
msg7624 (view) Author: Frank Wierzbicki (fwierzbicki) Date: 2013-02-05.21:22:55
Thanks for the effort you put into the pull request. I recently updated the native jars to even newer versions - please let me know if you still have trouble with this (and re-open this issue or another. Sorry this languished for so long.
History
Date User Action Args
2013-02-05 21:22:56fwierzbickisetstatus: open -> closed
priority: normal
resolution: fixed
messages: + msg7624
2012-08-28 22:21:52amaksetnosy: + amak
2012-08-02 21:36:55fwierzbickisetassignee: fwierzbicki
nosy: + fwierzbicki
2012-07-31 22:20:30varialuscreate