You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
sm new project/module: generated event records implement IEvent directly and don't compile (should derive from DomainEvent) #218
A freshly scaffolded project does not compile: the generated domain-event record implements IEvent directly, but IEvent now requires EventId and OccurredAt.
Repro
dotnet tool install -g SimpleModule.Cli # 0.0.37
sm new project InvoiceManager
cd InvoiceManager
dotnet build
Actual
Items.Contracts/Events/ItemCreatedEvent.cs(5,53): error CS0535:
'ItemCreatedEvent' does not implement interface member 'IEvent.EventId'
Items.Contracts/Events/ItemCreatedEvent.cs(5,53): error CS0535:
'ItemCreatedEvent' does not implement interface member 'IEvent.OccurredAt'
Build FAILED.
IEvent's own XML doc says "Event records typically inherit DomainEvent rather than implementing this directly." — but the sm new project / sm new module templates still emit : IEvent.
Suggested fix
Update the event template(s) in the CLI to derive from DomainEvent:
Activity
fix(cli): resolve scaffold build/runtime bugs (#218, #219, #221, #225, …
antosubash commentedon Jun 3, 2026
Fixed in #231 (merged db8be0e). Verified the fix is present on
main.