delph-in / matrix

The Grammar Matrix
https://matrix.ling.washington.edu/index.html
Other
12 stars 6 forks source link

datestamp and generally updating the live site #640

Open olzama opened 2 years ago

olzama commented 2 years ago

I removed an outdated comment from matrix.tdl just now, and I want to update the live site. As usual, the install script is out of sync with something (potentially related also to my credentials, because I am getting permissions errors, but not only that; it also just reports some rsync errors and what not). This has often happened in the past and I have been resorting to just scp-ing the specific files, so I did that, to the test server:

https://matrix.ling.washington.edu/trunktest/matrix.cgi

So now the version on this test server is the new one with the updated matrix.tdl (removed outdated comment).

Now, the datestamp on the main page of course didn't change, with this procedure. I think it is important to make sure it is changed, before I actually update the live site, otherwise this will potentially lead to much confusion. In fact, I now realize, since I've been scp-ing things before, the existing datestamp (August 2 2021) may not necessarily be accurate.

What would be a good solution here? I am assuming the install script was making sure the datetime stamp is updated? I cannot quite figure it out. @bmgraves can you tell??...

From deffile.py:

    def main_page(self, cookie, vr):
        print(HTTP_header)
        print('Set-cookie: session=' + cookie + '\n')
        print(HTML_pretitle)
        print('<title>The Matrix</title>')
        print(HTML_posttitle % ('', '', '', ''))

        try:
            f = open('datestamp', 'r')
            datestamp = f.readlines()[0].strip()
            f.close()
        except:
            datestamp = "[date unknown]"

        print(HTML_mainprebody % (datestamp))
        print('<div class="indented">')

Current output if I try to use the install script:

(py3env) (base) Murkin16:matrix-git olzama$ python matrix.py install olzama@patas.ling.washington.edu:/home/www-matrix/html/trunktest/
Please enter your patas username:
olzama
cat: /Users/olzama/Research/matrix-git/gmcs/../matrix-core//roots.tdl: No such file or directory
sed: 1: "/tmp/matrix.31338/matri ...": invalid command code m
olzama@patas.ling.washington.edu's password: 
building file list ... done
rsync: recv_generator: mkdir "/home/www-matrix/html/trunktest/py3env" failed: Permission denied (13)
*** Skipping any contents from this failed directory ***
.htaccess
datestamp
matrix-types
gmcs/customize.py
gmcs/linglib/information_structure.py
matrix-core/matrix.tdl
py3env/
saved-choices/.htaccess
rsync: mkstemp "/home/www-matrix/html/trunktest/.htaccess.8UMcms" failed: Permission denied (13)
rsync: mkstemp "/home/www-matrix/html/trunktest/.datestamp.ofaq0D" failed: Permission denied (13)
rsync: mkstemp "/home/www-matrix/html/trunktest/.matrix-types.Q5iOEP" failed: Permission denied (13)
rsync: mkstemp "/home/www-matrix/html/trunktest/gmcs/.customize.py.A5djj1" failed: Permission denied (13)
rsync: mkstemp "/home/www-matrix/html/trunktest/gmcs/linglib/.information_structure.py.iIjWXc" failed: Permission denied (13)
rsync: mkstemp "/home/www-matrix/html/trunktest/matrix-core/.matrix.tdl.YFRaDo" failed: Permission denied (13)
rsync: connection unexpectedly closed (2368 bytes received so far) [sender]
rsync error: error in rsync protocol data stream (code 12) at /AppleInternal/BuildRoot/Library/Caches/com.apple.xbs/Sources/rsync/rsync-54.120.1/rsync/io.c(453) [sender=2.6.9]
(py3env) (base) Murkin16:matrix-git olzama$