Troubleshooting
Most Arc snags come down to a handful of causes. Here they are. If the slice uses the Chronicle integration, see Chronicle troubleshooting for event-store-specific issues.
My frontend can’t find the generated proxy
Section titled “My frontend can’t find the generated proxy”Proxies are generated when the backend builds. If the import doesn’t resolve:
- Run
dotnet buildon the backend and confirm it succeeds — no proxies are emitted until the C# compiles. - Check the command/query is discoverable: a
[Command]record with aHandle()method, or a static query method on a[ReadModel]. - Make sure proxy generation is targeting the right output folder for your frontend (see Proxy Generation).
I changed the C# but the TypeScript is stale
Section titled “I changed the C# but the TypeScript is stale”The proxies regenerate on build. Rebuild the backend; the frontend types update with it. If a renamed property doesn’t surface, you’ve found the feature working — the old name should now fail to compile until you update the call site.
My command’s OK/Submit button stays disabled
Section titled “My command’s OK/Submit button stays disabled”The command isn’t considered valid. The usual cause: a required value is being set in onBeforeExecute instead of initialValues. onBeforeExecute runs at execution time — too late to affect validity — so the form never becomes valid. Put injected required values (like a parent id) in initialValues; reserve onBeforeExecute for generated values that don’t gate validity (like a new Guid). See Building a form.
My command returns 401 or 403
Section titled “My command returns 401 or 403”That’s authorization. Check that:
- the caller is authenticated, and
- the caller has the role the command requires (
[Roles(...)]on the command — or on the query method for a 403 on reads).
For local development you can generate a principal so you can exercise authorized endpoints without a full login — see Identity and Authorizing commands and queries.
My validation isn’t firing
Section titled “My validation isn’t firing”Arc discovers a CommandValidator<TCommand> by convention. Confirm the validator’s generic type matches the command exactly, and that any async rule that needs a dependency takes it via the validator’s constructor. See Commands.
My query returns nothing
Section titled “My query returns nothing”This is usually the read side, not proxy generation:
- Confirm the command wrote the document or entity you expect.
- Check any query predicate, especially ids passed through
[Key]. - If the query is observable, confirm the underlying store is configured for observation: MongoDB change streams or EF observed DbSets.
If the slice is backed by Chronicle, also check that the projection has caught up and maps the events you appended.
See also
Section titled “See also”- Backend and Frontend guides.
- Chronicle troubleshooting for optional event-store issues.