(go to: table of contents, index, prev: embedding the Python interpreter, next: changes to Python source)
The default OpenVMS filesystem (ODS-2) supports only uppercase filenames.
The modification makes the module compliant.
This module is used during the installation. See the
'Installation Manual',
'installing and building',
'compile Python files'.
GETPASS.PY has been modified to call
pyvms.pylib_getpass()
on OpenVMS systems.
This module has more functionality, but that has not been changed for OpenVMS.
The module was using a filename character ("@") that is invalid on ODS-2
disks.
The 'TemporaryFileWrapper' class uses a construct (os.open(), os.unlink())
that does not work on OpenVMS. The port pretends to be a 'POSIX' environment,
so the appropriate check fails. The check has been removed - the required piece
of code is directly executed.
Beginning with version 1.5.2-V007 there is no '.' in the temporary name,
because the 'TEST_PKG.PY' uses this module to create temporary directory names.
(On a Unix system there is no fixed 'type' for a directory as on OpenVMS
where this is always '.DIR;1'.)
SETUP.COM creates a subdirectory "[.PYTHON_TMP]" within the
directory that the logical name "SYS$SCRATCH" points to.
The module was using a filename character ("@") that is invalid on ODS-2
and used filenames with multiple '.'s which does not work in ODS-2, too.
This test is currently disabled, because signal handling usually works
different on OpenVMS.
@@ It might come back after some tests with a current DEC C RTL.
The module was using a filename character ("@") that is invalid on ODS-2.
This is an invalid file specification for an ODS-2 formatted disk; the default
OpenVMS file system.
On OpenVMS systems the script executes the file 'PYTHONRC.PY' from the user's
login directory. It does not use "SYS$LOGIN" - instead it uses the C RTL's
"HOME" environment variable. See the script for details.
compileall
ftplib
>>> import ftplib
>>> ftp = ftplib.FTP ('host', 'username', 'password')
>>> ftp.retrlines ('LIST')
...
'226 LIST Directory transfer complete.'
>>>
$ set DEFAULT PYTHON_VMS:
$ set DEFAULT [-.LIB]
$ python ftplib.py -d localhost -l -p -l
*cmd* 'USER anonymous'
*resp* '331 Guest login ok, send ident as password.'
*cmd* 'PASS *************************'
*resp* '530 Username ANONYMOUS has been disabled.'
Traceback (innermost last):
[...]
File "ftplib.py", line 201, in getresp
raise error_perm, resp
ftplib.error_perm: 530 Username ANONYMOUS has been disabled.
$
Problems might remain.
getpass
site
Old:
>>> exit
'Use Ctrl-D (i.e. EOF) to exit.'
>>>
Now:
>>> exit
'Use Ctrl-Z (i.e. EOF) to exit.'
>>>
tempfile
>>> import tempfile
>>>
>>> tempfile.gettempdir ()
'/user_here/zessin/python_tmp'
>>> tempfile.gettempprefix ()
'python_tmp_213_'
>>> tempfile.mktemp ()
'/user_here/zessin/python_tmp/python_tmp_213_1'
>>> tempfile._pid
213
>>> tempfile.counter
1
>>>
$ show logical PYTHON_TMP* /process
(LNM$PROCESS_TABLE)
"PYTHON_TMP1" = "USER_HERE:[ZESSIN.PYTHON_TMP]"
"PYTHON_TMP2" = "/user_here/zessin/python_tmp"
$
$ show logical SYS$SCRATCH
"SYS$SCRATCH" = "USER_HERE:[ZESSIN]" (LNM$JOB_845CE780)
$
There can be a problem if SYS$SCRATCH points to a logical
name search list. The 'pkg' test fails for some reason that I have not tried
to find out - please redefine SYS$SCRATCH in such a situation.
test_rgbimg
test_signal
test_support
user