From 69a9defea769c8b23ff9b5bdcca7e67b2f38f0ba Mon Sep 17 00:00:00 2001 From: Brandon Sprague Date: Fri, 12 Jan 2024 19:40:55 -0800 Subject: [PATCH] Address review comments --- cmd/runner/README.md | 8 +++++++- frontend/i18n.config.ts | 3 ++- 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/cmd/runner/README.md b/cmd/runner/README.md index c6277d2..80ba6a0 100644 --- a/cmd/runner/README.md +++ b/cmd/runner/README.md @@ -15,7 +15,13 @@ bazel run //scripts:run_server -- --use_azure_runner ### Creating a new docker image to run locally -When testing locally (e.g. without `--use_azure_runner`), you can build and tag a runner image locally and use that. To do that, run `bazel run //scripts:build_and_load_runner` +When developing the runner, you have two options: + +* **Test against local Docker** - Run the server **without** the `--use_azure_runner`, which means async tasks will run locally, using `docker run ...`. To test local runner changes, you can build and tag a runner image locally with `bazel run //scripts:build_and_load_runner`. + * After running the script, the updated runner will immediately be available, no need to restart the server. + * This is the option you'll want to use most of the time. +* **Test against Azure Container Apps Jobs** - Run the server **with** the `--use_azure_runner`, which means async tasks will be run on Azure, created via the Azure API. To test changes here, you can build and tag a runner image locally with `bazel run //scripts:build_and_load_runner`, and then push it to Azure with `docker push rmisa.azurecr.io/runner:latest` + * You generally won't need to use this option unless you're testing something very specific about the runner's integration with Azure, as the runner code is identical whether run locally or on Azure. ### Cleaning up old runner containers diff --git a/frontend/i18n.config.ts b/frontend/i18n.config.ts index fc8442d..9c0fa03 100644 --- a/frontend/i18n.config.ts +++ b/frontend/i18n.config.ts @@ -7,8 +7,9 @@ export default defineI18nConfig(() => ({ // Consider using process.env.NODE_ENV == 'prod', etc. const fn = vm?.appContext.app.$nuxt.$missingTranslations.handleMissingTranslation if (fn) { - // const callable = fn as (locale: string, key: string) => void fn(locale, key) + } else { + console.warn(`No handleMissingTranslation function found, can't handle ${locale} ${key}`) } }, }))