wwivbbs / wwiv

WWIV BBS Software v5
http://www.wwivbbs.org
Other
186 stars 71 forks source link

WWIVbasic scripts not finding json because of filename case differences #1611

Closed granitepenguin closed 1 year ago

granitepenguin commented 1 year ago

WWIV Bulletin Board System [5.9.0.3696] OS: linux debian 10

When I updated from 5.8.0.3549 to 5.9.0.3696, I noticed that oneliners was running, but wasn't finding the existing entries in the json file. Bumped up to --v=3 and found the following:

2023-06-28 10:19:10,995 INFO  Running basic script: oneliners.bas
2023-06-28 10:19:11,057 VER-3 ReadFileIntoString:
2023-06-28 10:19:11,138 VER-3 JSON File does not exist: /bbs/wwiv/data/ONELINERS.script.json

As you can see, it's looking for an uppercase script name, not lowercase; so it's munging this somewhere.

wwiv commented 1 year ago

is the file on disk ONELINERS.script.json?

Can you rty with the latest 5.8 on jenkins too please to help narrow down where it broke?

wwiv commented 1 year ago

I suspect it's this change https://github.com/wwivbbs/wwiv/commit/c67c0bceddf625fbfbd40d68b33963269cf6a7f6 but that was in 5.8 so wanted to confirm where we need to fix (5.8 and 5.9 or just 5.9)

If so, the fix would be localized to https://github.com/wwivbbs/wwiv/blob/4b85f1d53bd1a8dff43282bf1749317aa76bd919/bbs/basic/wwiv_data.cpp#L113 where we should always lower case filenames before IO

granitepenguin commented 1 year ago

the file on disk is all lowercase: oneliners.script.json

I was able to symlink as a workaround, so that's something at least. I'll see if I can try 5.8 for comparison. Do you know what the latest 5.8 is on jenkins?

granitepenguin commented 1 year ago

confirmed this is working now.