Fix installed musrfit_startup.xml data paths for standard LMU layout

The web-deployed startup XML used a single data_path root and templates
under d<year>/tdc/... that resolve to paths not present on the standard
LMU machines. Match the working desktop default: one per-instrument
data_path under /psi.ch/group/lmu/public/data/<inst>/his plus the full
template set, and update the run-naming tests that pinned the broken
layout.
This commit is contained in:
salman committed 2026-09-03 13:13:15 +02:00
1 parent 84cea8e629
commit ec647a5484
2 files changed
+111 -39

No files matched your search

+85 -32
View File
@@ -7,39 +7,92 @@
part of the muSRFlow deployment, not a user/system configuration file, and
is deliberately NOT served from the web document root.
The <data_path> entries are search roots. Each <run_name_template> gives an
instrument-specific sub-path + file name; %yyyy% and %yy% are the 4- and
2-digit year, and %rrr...% is the run number zero-padded to the number of
'r' characters. Multiple templates for one instrument are tried in order.
Data on the standard LMU machines lives under
/psi.ch/group/lmu/public/data/<instrument>/his/<year>/
Each <data_path> below names one instrument's data root; each
<run_name_template> gives an instrument-specific sub-path + file name
relative to that root. %yyyy% and %yy% are the 4- and 2-digit year, and
%rrr...% is the run number zero-padded to the number of 'r' characters.
Multiple templates for an instrument are tried in order.
Admin may point MUSRFIT_STARTUP_XML at a different file to override this
default. The installed copy may be edited in place.
-->
<musrfit>
<data_path>/psi.ch/group/lmu/public/data</data_path>
<run_name_template inst="lem">d%yyyy%/tdc/lem%yy%_his_%rrrr%.root</run_name_template>
<run_name_template inst="gps">d%yyyy%/deltat_pta_gps_%rrrr%.bin</run_name_template>
<run_name_template inst="gps">d%yyyy%/tdc/deltat_tdc_gps_%rrrr%.bin</run_name_template>
<run_name_template inst="gps">d%yyyy%/tdc/root/deltatbc_tdc_gps_%yyyy%_%rrrr%.root</run_name_template>
<run_name_template inst="ltf">d%yyyy%/deltat_pta_ltf_%rrrr%.bin</run_name_template>
<run_name_template inst="ltf">d%yyyy%/tdc/deltat_tdc_ltf_%rrrr%.bin</run_name_template>
<run_name_template inst="dolly">d%yyyy%/deltat_pta_dolly_%rrrr%.bin</run_name_template>
<run_name_template inst="dolly">d%yyyy%/tdc/deltat_tdc_dolly_%rrrr%.bin</run_name_template>
<run_name_template inst="dolly">d%yyyy%/tdc/root/deltat_tdc_dolly_%yyyy%_%rrrr%.root</run_name_template>
<run_name_template inst="vms">d%yyyy%/tdc/root/deltat_tdc_vms_%yyyy%_%rrrr%.root</run_name_template>
<run_name_template inst="gpd">d%yyyy%/deltat_pta_gpd_%rrrr%.bin</run_name_template>
<run_name_template inst="gpd">d%yyyy%/tdc/deltat_tdc_gpd_%rrrr%.bin</run_name_template>
<run_name_template inst="gpd">d%yyyy%/tdc/root/deltatbc_tdc_gpd_%yyyy%_%rrrr%.root</run_name_template>
<run_name_template inst="hifi">d%yyyy%/tdc_hifi_%yyyy%_%rrrrr%.bin</run_name_template>
<run_name_template inst="hifi">d%yyyy%/tdc/root/deltat_tdc_hifi_%yyyy%_%rrrr%.root</run_name_template>
<run_name_template inst="flame">d%yyyy%/tdc/deltat_tdc_flame_%yyyy%_%rrrr%.root</run_name_template>
<run_name_template inst="flame">d%yyyy%/flame%yy%_his_%rrrrr%.root</run_name_template>
</musrfit>
<musrfit xmlns="https://lmu.pages.psi.ch/musrfit-docu/">
<data_path>/psi.ch/group/lmu/public/data/lem/his</data_path>
<data_path>/psi.ch/group/lmu/public/data/alc/his</data_path>
<data_path>/psi.ch/group/lmu/public/data/dolly/his</data_path>
<data_path>/psi.ch/group/lmu/public/data/flame/his</data_path>
<data_path>/psi.ch/group/lmu/public/data/gpd/his</data_path>
<data_path>/psi.ch/group/lmu/public/data/gps/his</data_path>
<data_path>/psi.ch/group/lmu/public/data/hal/his</data_path>
<data_path>/psi.ch/group/lmu/public/data/ltf/his</data_path>
<data_path>/psi.ch/group/lmu/public/data/misc/his</data_path>
<data_path>/psi.ch/group/lmu/public/data/vms/his</data_path>
<data_path>/mnt/data/nemu/his</data_path>
<!-- MISC/PSI 1985 - 1990 -->
<run_name_template inst="misc">d%yyyy%/deltat_misc_%rrrr%.bin</run_name_template>
<!-- ALC TD/PSI -->
<run_name_template inst="alc">d%yyyy%/deltat_zh_chem_%rrrr%.bin</run_name_template>
<run_name_template inst="alc">d%yyyy%/deltat_tdc_alc_%rrrr%.bin</run_name_template>
<run_name_template inst="alc">d%yyyy%/tdc/deltat_tdc_alc_%rrrr%.bin</run_name_template>
<!-- VMS/PSI -->
<run_name_template inst="vms">d%yyyy%/tdc/root/deltat_tdc_vms_%yyyy%_%rrrr%.root</run_name_template>
<!-- Dolly/PSI -->
<run_name_template inst="dolly">d%yyyy%/tdc/root/deltat_tdc_dolly_%yyyy%_%rrrr%.root</run_name_template>
<run_name_template inst="dolly">d%yyyy%/pie1/deltat_flc_%rrrr%.bin</run_name_template>
<run_name_template inst="dolly">d%yyyy%/pie3/deltat_flc_%rrrr%.bin</run_name_template>
<run_name_template inst="dolly">d%yyyy%/deltat_flc_%rrrr%.bin</run_name_template>
<run_name_template inst="dolly">d%yyyy%/deltat_pta_dolly_%rrrr%.bin</run_name_template>
<run_name_template inst="dolly">d%yyyy%/pta/deltat_pta_dolly_%rrrr%.bin</run_name_template>
<run_name_template inst="dolly">d%yyyy%/tdc/deltat_tdc_dolly_%rrrr%.bin</run_name_template>
<run_name_template inst="dolly">d%yyyy%/tdc/mdu/deltat_tdc_dolly_%rrrr%.mdu</run_name_template>
<!-- Flame/PSI -->
<run_name_template inst="flame">d%yyyy%/tdc/root/deltat_tdc_flame_%yyyy%_%rrrr%.root</run_name_template>
<run_name_template inst="flame">d%yyyy%/tdc/deltat_tdc_flame_%rrrr%.bin</run_name_template>
<run_name_template inst="flame">d%yyyy%/tdc/mdu/deltat_tdc_flame_%yyyy%_%rrrr%.mdu</run_name_template>
<!-- GPD/PSI -->
<run_name_template inst="gpd">d%yyyy%/tdc/root/deltat_tdc_gpd_%yyyy%_%rrrr%.root</run_name_template>
<run_name_template inst="gpd">d%yyyy%/deltat_mue1_%rrrr%.bin</run_name_template>
<run_name_template inst="gpd">d%yyyy%/deltat_fq_si_%rrrr%.bin</run_name_template>
<run_name_template inst="gpd">d%yyyy%/deltat_strobo_%rrrr%.bin</run_name_template>
<run_name_template inst="gpd">d%yyyy%/deltat_hp_ni_ht_%rrrr%.bin</run_name_template>
<run_name_template inst="gpd">d%yyyy%/deltat_hp_ni_%rrrr%.bin</run_name_template>
<run_name_template inst="gpd">d%yyyy%/deltat_ccr2_%rrrr%.bin</run_name_template>
<run_name_template inst="gpd">d%yyyy%/deltat_gpd_%rrrr%.bin</run_name_template>
<run_name_template inst="gpd">d%yyyy%/deltat_janis_%rrrr%.bin</run_name_template>
<run_name_template inst="gpd">d%yyyy%/deltat_janis_gpd_%rrrr%.bin</run_name_template>
<run_name_template inst="gpd">d%yyyy%/deltat_pta_gpd_%rrrr%.bin</run_name_template>
<run_name_template inst="gpd">d%yyyy%/pta/deltat_pta_gpd_%rrrr%.bin</run_name_template>
<run_name_template inst="gpd">d%yyyy%/tdc/deltat_tdc_gpd_%rrrr%.bin</run_name_template>
<run_name_template inst="gpd">d%yyyy%/tdc/mdu/deltat_tdc_gpd_%rrrr%.mdu</run_name_template>
<!-- GPS/PSI -->
<run_name_template inst="gps">d%yyyy%/tdc/root/deltat_tdc_gps_%yyyy%_%rrrr%.root</run_name_template>
<run_name_template inst="gps">d%yyyy%/deltat_ccr_%rrrr%.bin</run_name_template>
<run_name_template inst="gps">d%yyyy%/deltat_he3_%rrrr%.bin</run_name_template>
<run_name_template inst="gps">d%yyyy%/deltat_stutt_%rrrr%.bin</run_name_template>
<run_name_template inst="gps">d%yyyy%/deltat_ltf_%rrrr%.bin</run_name_template>
<run_name_template inst="gps">d%yyyy%/deltat_flc_%rrrr%.bin</run_name_template>
<run_name_template inst="gps">d%yyyy%/deltat_flc2_%rrrr%.bin</run_name_template>
<run_name_template inst="gps">d%yyyy%/deltat_oven_%rrrr%.bin</run_name_template>
<run_name_template inst="gps">d%yyyy%/deltat_oven2_%rrrr%.bin</run_name_template>
<run_name_template inst="gps">d%yyyy%/deltat_pta_gps_%rrrr%.bin</run_name_template>
<run_name_template inst="gps">d%yyyy%/tdc/deltat_tdc_gps_%rrrr%.bin</run_name_template>
<run_name_template inst="gps">d%yyyy%/tdc/mdu/deltat_tdc_gps_%yyyy%_%rrrr%.mdu</run_name_template>
<!-- HAL-9500/PSI == HIFI/PSI -->
<run_name_template inst="hifi">d%yyyy%/tdc/root/deltat_tdc_hifi_%yyyy%_%rrrr%.root</run_name_template>
<run_name_template inst="hifi">d%yyyy%/tdc/deltat_hifi_%rrrr%.bin</run_name_template>
<run_name_template inst="hifi">d%yyyy%/tdc/tdc_hifi_%yyyy%_%rrrrr%.mdu</run_name_template>
<run_name_template inst="hifi">d%yyyy%/tdc/root/deltat_tdc_hifi_%yyyy%_%rrrr%.mdu</run_name_template>
<!-- LTF/PSI -->
<run_name_template inst="ltf">d%yyyy%/deltat_ltf_%rrrr%.bin</run_name_template>
<run_name_template inst="ltf">d%yyyy%/deltat_ltf2_%rrrr%.bin</run_name_template>
<run_name_template inst="ltf">d%yyyy%/deltat_pta_ltf_%rrrr%.bin</run_name_template>
<run_name_template inst="ltf">d%yyyy%/pta/deltat_pta_ltf_%rrrr%.bin</run_name_template>
<run_name_template inst="ltf">d%yyyy%/tdc/deltat_tdc_ltf_%rrrr%.bin</run_name_template>
<!-- LEM/PSI -->
<run_name_template inst="lem">%yyyy%/lem%yy%_his_%rrrr%.root</run_name_template>
<run_name_template inst="lem">d%yyyy%/tdc/lem%yy%_his_%rrrr%.root</run_name_template>
<run_name_template inst="lem">%yyyy%/lem%yy%_his_%rrrrr%.root</run_name_template>
<run_name_template inst="lem">d%yyyy%/tdc/lem%yy%_his_%rrrrr%.root</run_name_template>
</musrfit>
+26 -7
View File
@@ -84,9 +84,28 @@ function testCommentsAreSkipped() {
const shippable = lib.parseMusrfitStartupXML(
fs.readFileSync(path.join(repoRoot, "cgi", "musrfit_startup.xml"), "utf8")
);
assert.deepStrictEqual(Array.from(shippable.dataPaths), ["/psi.ch/group/lmu/public/data"]);
assert.ok(shippable.templates.lem && shippable.templates.lem.length === 1);
assert.ok(shippable.templates.hifi && shippable.templates.hifi.length === 2);
// Data on the standard LMU machines lives under
// /psi.ch/group/lmu/public/data/<instrument>/his/, so the shipped default
// carries one search root per instrument (plus the legacy NEMU mount).
assert.deepStrictEqual(Array.from(shippable.dataPaths), [
"/psi.ch/group/lmu/public/data/lem/his",
"/psi.ch/group/lmu/public/data/alc/his",
"/psi.ch/group/lmu/public/data/dolly/his",
"/psi.ch/group/lmu/public/data/flame/his",
"/psi.ch/group/lmu/public/data/gpd/his",
"/psi.ch/group/lmu/public/data/gps/his",
"/psi.ch/group/lmu/public/data/hal/his",
"/psi.ch/group/lmu/public/data/ltf/his",
"/psi.ch/group/lmu/public/data/misc/his",
"/psi.ch/group/lmu/public/data/vms/his",
"/mnt/data/nemu/his"
]);
assert.ok(shippable.templates.lem && shippable.templates.lem.length === 4);
assert.ok(shippable.templates.hifi && shippable.templates.hifi.length === 4);
// The whole pointer set: every data_path root names exactly one instrument.
for (const inst of ["lem", "gps", "ltf", "dolly", "vms", "gpd", "hifi"]) {
assert.ok(shippable.templates[inst] && shippable.templates[inst].length >= 1, inst);
}
}
function testTemplateExpansion() {
@@ -310,8 +329,8 @@ function testAllInstrumentsRunLines() {
// [instrument, run, year, accepted sub-path, expected RUN line]
["LEM", 7, "2026", "d2026/tdc/lem26_his_0007.root",
"RUN d2026/tdc/lem26_his_0007.root MUE4 PSI MUSR-ROOT"],
["GPS", 7, "2024", "d2024/tdc/root/deltatbc_tdc_gps_2024_0007.root",
"RUN d2024/tdc/root/deltatbc_tdc_gps_2024_0007.root PIM3 PSI MUSR-ROOT"],
["GPS", 7, "2024", "d2024/tdc/root/deltat_tdc_gps_2024_0007.root",
"RUN d2024/tdc/root/deltat_tdc_gps_2024_0007.root PIM3 PSI MUSR-ROOT"],
["LTF", 7, "2026", "d2026/tdc/deltat_tdc_ltf_0007.bin",
"RUN d2026/tdc/deltat_tdc_ltf_0007.bin PIM3 PSI PSI-BIN"],
["Dolly", 7, "2026", "d2026/tdc/root/deltat_tdc_dolly_2026_0007.root",
@@ -320,8 +339,8 @@ function testAllInstrumentsRunLines() {
"RUN d2026/tdc/root/deltat_tdc_vms_2026_0007.root PIE1 PSI MUSR-ROOT"],
["GPD", 7, "2010", "d2010/tdc/deltat_tdc_gpd_0007.bin",
"RUN d2010/tdc/deltat_tdc_gpd_0007.bin PIE1 PSI PSI-BIN"],
["FLAME", 7, "2026", "d2026/flame26_his_00007.root",
"RUN d2026/flame26_his_00007.root PIM3 PSI MUSR-ROOT"],
["FLAME", 7, "2026", "d2026/tdc/root/deltat_tdc_flame_2026_0007.root",
"RUN d2026/tdc/root/deltat_tdc_flame_2026_0007.root PIM3 PSI MUSR-ROOT"],
["HAL", 7, "2026", "d2026/tdc/root/deltat_tdc_hifi_2026_0007.root",
"RUN d2026/tdc/root/deltat_tdc_hifi_2026_0007.root PIE3 PSI MUSR-ROOT"]
];