Issue2611

classification
Title: mkdir() operation in /Lib/os.py has different behavior when running in Docker container
Type: behaviour Severity: normal
Components: Core Versions: Jython 2.7
Milestone:
process
Status: closed Resolution: out of date
Dependencies: Superseder:
Assigned To: Nosy List: jeff.allen, jochenhebbrecht
Priority: normal Keywords:

Created on 2017-07-20.12:46:17 by jochenhebbrecht, last changed 2018-03-12.22:38:11 by jeff.allen.

Messages
msg11487 (view) Author: Jochen Hebbrecht (jochenhebbrecht) Date: 2017-07-20.12:53:33
Local environment
---------------------
$ java -jar jython-standalone-2.7.0.jar 
Jython 2.7.0 (default:9987c746f838, Apr 29 2015, 02:25:11) 
[Java HotSpot(TM) 64-Bit Server VM (Oracle Corporation)] on java1.8.0_131
Type "help", "copyright", "credits" or "license" for more information.
>>> os.mkdir('/tmp/jochen')
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
NameError: name 'os' is not defined
>>> import os
>>> os.mkdir('/tmp/jochen')
>>> os.mkdir('/tmp/jochen')
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
OSError: [Errno 17] File exists: '/tmp/jochen'

=> We get Errno 17 which is expected.


Docker environment
---------------------
$ java -jar jython-standalone-2.7.0.jar 
Jython 2.7.0 (default:9987c746f838, Apr 29 2015, 02:25:11) 
[Java HotSpot(TM) 64-Bit Server VM (Oracle Corporation)] on java1.8.0_131
Type "help", "copyright", "credits" or "license" for more information.
>>> os.mkdir('/tmp/jochen')
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
NameError: name 'os' is not defined
>>> import os
>>> os.mkdir('/tmp/jochen')
>>> os.mkdir('/tmp/jochen')
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
OSError: [Errno 20000] Unknown error: 20000: '/tmp/jochen'

=> We get a different Errno
msg11775 (view) Author: Jeff Allen (jeff.allen) Date: 2018-03-10.22:35:51
Is this the same (fixed) problem as here?
https://github.com/trustin/sphinx-gradle-plugin/issues/2

Sounds like this was overcome when the sphinx-maven-plugin updated to Jython 2.7.1, and there's nothing to do here.
msg11781 (view) Author: Jochen Hebbrecht (jochenhebbrecht) Date: 2018-03-11.19:39:50
Yes, this is indeed the same issue. Issue seems to be fixed in a more recent version of Jython.
msg11786 (view) Author: Jeff Allen (jeff.allen) Date: 2018-03-12.22:38:11
Closing. Glad you got what you needed, by whatever route.
History
Date User Action Args
2018-03-12 22:38:11jeff.allensetstatus: pending -> closed
messages: + msg11786
2018-03-11 19:39:50jochenhebbrechtsetmessages: + msg11781
2018-03-10 22:35:51jeff.allensetpriority: normal
status: open -> pending
resolution: out of date
messages: + msg11775
nosy: + jeff.allen
2017-07-20 12:53:33jochenhebbrechtsetmessages: + msg11487
2017-07-20 12:46:17jochenhebbrechtcreate