Skip to content

Commit 96d8e2a

Browse files
Copilotrubensworks
andcommitted
Fix: handle gui command not found in checking_screen state
Co-authored-by: rubensworks <440384+rubensworks@users.noreply.github.com>
1 parent 186534c commit 96d8e2a

2 files changed

Lines changed: 8 additions & 23 deletions

File tree

‎infobook-html-additions/lib/modloader/IconsGenerator.ts‎

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -272,12 +272,19 @@ export class IconsGenerator {
272272
sendCommand('gui');
273273
commandSent = false;
274274
}, 2000);
275+
} else if (outputBuffer.includes("Couldn't find command for '[gui]'") && !commandSent) {
276+
// gui not yet recognized; hmc-specifics may still be initializing - retry
277+
commandSent = true;
278+
setTimeout(() => {
279+
sendCommand('gui');
280+
commandSent = false;
281+
}, 5000);
275282
} else if (Date.now() - stateSettledAt > 30000 && !commandSent) {
276283
// Timeout - try gui again
277284
commandSent = true;
278285
setTimeout(() => {
279286
sendCommand('gui');
280-
transitionTo('checking_screen');
287+
commandSent = false;
281288
}, 2000);
282289
}
283290
break;

‎yarn.lock‎

Lines changed: 0 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -227,28 +227,6 @@ cross-spawn@^5.0.1:
227227
shebang-command "^1.2.0"
228228
which "^1.2.9"
229229

230-
"cyclops-infobook-html@file:../../../../../tmp/Infobook-html":
231-
version "5.0.0"
232-
resolved "file:../../../../../tmp/Infobook-html"
233-
dependencies:
234-
"@types/mkdirp" "^0.5.2"
235-
"@types/ncp" "^2.0.1"
236-
"@types/node" "^13.1.0"
237-
"@types/node-fetch" "^2.5.0"
238-
"@types/pug" "^2.0.4"
239-
"@types/rimraf" "^3.0.0"
240-
"@types/xml2js" "^0.4.4"
241-
"@types/yauzl" "^2.9.1"
242-
minimist "^1.2.0"
243-
mkdirp "^0.5.1"
244-
mvn-artifact-download "^5.0.0"
245-
ncp "^2.0.0"
246-
node-fetch "^2.6.0"
247-
pug "^3.0.0"
248-
rimraf "^3.0.0"
249-
xml2js "^0.4.19"
250-
yauzl "^2.10.0"
251-
252230
decamelize@^1.0.0:
253231
version "1.2.0"
254232
resolved "https://registry.npmjs.org/decamelize/-/decamelize-1.2.0.tgz"

0 commit comments

Comments
 (0)