Skip to content

Fix Aspire AppHost not building email templates before APIs become ready#886

Merged
tjementum merged 2 commits into
mainfrom
pp-1197-aspire-apphost-does-not-build-email-templates
May 4, 2026
Merged

Fix Aspire AppHost not building email templates before APIs become ready#886
tjementum merged 2 commits into
mainfrom
pp-1197-aspire-apphost-does-not-build-email-templates

Conversation

@tjementum
Copy link
Copy Markdown
Member

@tjementum tjementum commented May 4, 2026

Summary & Motivation

After the localized-emails feature merged to main, starting Aspire on a fresh clone (or any environment without a populated application/account/WebApp/emails/dist/ folder) returned HTTP 500 from every email-sending endpoint with System.IO.FileNotFoundException: Email template 'StartSignup.en-US.html' not found. The crash cascaded through 11 of 14 e2e smoke tests. The dist folder is a gitignored build artifact only populated by the @repo/emails#build turbo task; nothing in the dev pipeline triggered that task before the AppGateway accepted requests.

  • Add @repo/emails#build to dev:setup's dependsOn in application/turbo.json. The Aspire AppHost's frontendBuild resource runs npm startturbo dev, and dev depends on dev:setup. Hooking @repo/emails#build into dev:setup makes turbo block every package's dev server until the email dist exists. The same flow protects every entry point that funnels through turbo devpp restart, pp run, pp e2e, dotnet run --project AppHost, and any IDE-launched AppHost.
  • Update the UnknownUser e2e assertions in application/account/WebApp/tests/e2e/localized-email-flows.spec.ts to match the Slack-style copy the email template was rewritten to use ("No account found" / "Is this the right email address?" in English, "Ingen konto fundet" / "Er det den rigtige e-mailadresse?" in Danish). The previous strings ("Unknown user tried to login to PlatformPlatform" / "You or someone else tried to login to PlatformPlatform") no longer exist in the rendered emails.

Checklist

  • I have added tests, or done manual regression tests
  • I have updated the documentation, if necessary

@tjementum tjementum self-assigned this May 4, 2026
@tjementum tjementum added the Bug Something isn't working label May 4, 2026
@linear
Copy link
Copy Markdown

linear Bot commented May 4, 2026

@tjementum tjementum moved this to 🏗 In Progress in Kanban board May 4, 2026
@sonarqubecloud
Copy link
Copy Markdown

sonarqubecloud Bot commented May 4, 2026

@tjementum tjementum merged commit e0b4d63 into main May 4, 2026
30 checks passed
@tjementum tjementum deleted the pp-1197-aspire-apphost-does-not-build-email-templates branch May 4, 2026 21:58
@github-project-automation github-project-automation Bot moved this from 🏗 In Progress to ✅ Done in Kanban board May 4, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Bug Something isn't working

Projects

Status: ✅ Done

Development

Successfully merging this pull request may close these issues.

1 participant