Message11113
I like the idea of making the platform pure Java, but then I agree Jython shouldn't implement anything that you can do within the JVM. (By default I really like JyNI though! Hoping to get some more time to look at it soon)
Had another idea for a solution for this maybe we should just return None if the OS call fails I did this in https://github.com/jythontools/jython/pull/56 It's actually easy as getlogin() already returns PyObject. I'm not sure its a great solution though what do you think? It avoids the error message issue and is quite faithful to https://linux.die.net/man/3/getlogin If this was adopted it would still be down to the user code to handle the None in some way but the error would be gone.
I don't think the "private static final POSIX posix = POSIXFactory.getJavaPOSIX(posixHandler, true);" would be useful almost all the methods in PosixModule disappear in this case because of the "@Hide(value=OS.NT, posixImpl = PosixImpl.JAVA)" annotation.
Also the github repo is a bit behind the mercurial one I have another issue for that http://bugs.jython.org/issue2556 |
|
Date |
User |
Action |
Args |
2017-02-22 19:46:48 | jamesmudd | set | messageid: <1487792808.88.0.456746982861.issue2534@psf.upfronthosting.co.za> |
2017-02-22 19:46:48 | jamesmudd | set | recipients:
+ jamesmudd, zyasoft, stefan.richthofer, pguermo |
2017-02-22 19:46:48 | jamesmudd | link | issue2534 messages |
2017-02-22 19:46:48 | jamesmudd | create | |
|