craigsapp / website-polish-scores

Front-end for digital transcriptions of the Polish Music Heritage in Open Access project
https://polishscores.org
3 stars 1 forks source link

Problem with score index #196

Closed craigsapp closed 1 year ago

craigsapp commented 1 year ago

The latest update of scores seems to have problems with the score index being incomplete JSON data:

Screen Shot 2022-10-04 at 6 26 07 PM

The score index cannot be downloaded, so the is no content displayed on the website browse page (and by extension, work pages cannot be shown).

Here is the index file that is causing problems:

https://data.nifc.humdrum.org/popc2-score-index.json

Probably caused by two things:

(1) The data is still being served from California mirror for some reason, so switch to the Polish server.

and (2) The problem on the California server is that aton2json is not working:

(cd indexes; aton2json popc2-score-index.aton | sed 's/^{"ENTRY"://; s/}[]]}$/}]/' > popc2-score-index.json)
internal/modules/cjs/loader.js:638
    throw err;
    ^

Error: Cannot find module 'aton'
    at Function.Module._resolveFilename (internal/modules/cjs/loader.js:636:15)
    at Function.Module._load (internal/modules/cjs/loader.js:562:25)
    at Module.require (internal/modules/cjs/loader.js:692:17)
    at require (internal/modules/cjs/helpers.js:25:18)
    at Object.<anonymous> (/usr/local/bin/aton2json:30:13)
    at Module._compile (internal/modules/cjs/loader.js:778:30)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:789:10)
    at Module.load (internal/modules/cjs/loader.js:653:32)
    at tryModuleLoad (internal/modules/cjs/loader.js:593:12)
    at Function.Module._load (internal/modules/cjs/loader.js:585:3)
(cd indexes; gzip popc2-score-index.json)
(cd indexes; gzip popc2-score-index.aton)

so the nodejs package for aton needs to be reinstalled (or the command needs to be run as root which may know where the aton package is located).

craigsapp commented 1 year ago

The website is now up again:

Screen Shot 2022-10-04 at 6 49 48 PM

The problem was that the indexing was not done as root, and only root is aware of the aton package for some reason (probably only installed in root account).

In any case, the data should still be served from Polish score server instead of the California one.