Compare commits

..

2 commits

Author SHA1 Message Date
0e4c7ca0f1 Fixing 5x loop when warming up
Some checks failed
ci/woodpecker/push/test Pipeline failed
ci/woodpecker/push/deploy unknown status
2026-04-30 22:21:38 +02:00
64c4354e5e Fixing bootstrapped notification to show proper version 2026-04-30 22:10:00 +02:00
2 changed files with 5 additions and 2 deletions

View file

@ -62,9 +62,9 @@ export class NtfyProvider implements OnApplicationBootstrap {
async sendBootstrappedNotification() {
const version =
this.configService.get<string>('GIT_COMMIT') ??
this.configService.get('LOCAL') === 'true'
(this.configService.get('LOCAL') === 'true'
? 'LOCAL'
: 'unknown'
: 'unknown')
await this.publishQueue.add(
...NtfyProvider.defaultJob({
title: 'Autobaan up and running',

View file

@ -721,6 +721,7 @@ export class BaanReserverenService {
const classList = Object.values(classListObj)
const rClass = classList.filter((cl) => /r-\d{2}/.test(cl))[0]
const courtNumber =
// @ts-expect-error just in case
`${CourtSlotToNumber[rClass.replace(/r-/, '') as CourtSlot]}` ??
'unknown court'
const startTime = await court
@ -912,8 +913,10 @@ export class BaanReserverenService {
try {
currentAttempt++
await this.init()
break
} catch (err: unknown) {
if (err instanceof RunningReservationsNavigationError) {
this.loggerService.warn('Hit expected warmup error, retrying', { currentAttempt })
await new Promise((res) => setTimeout(res, delay))
} else {
throw err