@karmaniverous/smoz
    Preparing search index...

    Troubleshooting

    Symptoms:

    • Cannot find module '@/app/generated/register.*'

    Fix:

    npx smoz register
    

    Tip: Commit the generated register.*.ts to keep typecheck stable. The Serverless plugin (exported as @karmaniverous/smoz/serverless-plugin) runs smoz register before package/deploy.

    • Normalize separators when deriving paths:
    import { fileURLToPath } from 'node:url';
    import { toPosixPath } from '@karmaniverous/smoz';
    export const APP_ROOT_ABS = toPosixPath(
    fileURLToPath(new URL('..', import.meta.url)),
    );
    • Ensure registers are fresh (npx smoz register).
    • Clear caches/build output if necessary:
    rimraf .tsbuild .rollup.cache dist
    
    • The HTTP stack maps Zod validation failures to 400. Check your eventSchema and responseSchema.
    • Do not duplicate HEAD; the HTTP stack short‑circuits HEAD to 200 {} and sets the configured content type.