Implementation details for EF Core change tracking. Use when changing InternalEntityEntry, ChangeDetector, SnapshotFactoryFactory, or related entity state, snapshot, or property accessor code.
68
81%
Does it follow best practices?
Run evals on this skill
Adds up to 20 points to the overall score
View guide
Passed
No findings from the security scan
Manages entity states and detects changes for SaveChanges().
StateManager — central engine, identity maps, tracks all entitiesInternalEntityEntry — per-entity state, property flags, snapshotsSnapshotFactoryFactory subclasses build snapshot factories for change detectionPropertyAccessorsFactory, ClrPropertyGetterFactory and ClrPropertySetterFactory compile property accessors for efficient snapshotting and change detection
indices parameter specify element at each complex collection depthUnit tests: test/EFCore.Tests/ChangeTracking/. Functional tests: test/EFCore.Specification.Tests/GraphUpdates/.
| Pitfall | Solution |
|---|---|
| There is a failure when there is shared identity entry (Added and Deleted) | Add code that checks SharedIdentityEntry |
DetectChanges() identifies modified properties via snapshot comparison61317c9
Also appears in
since Jul 28, 2026
If you maintain this skill, you can claim it as your own. Once claimed, you can manage eval scenarios, bundle related skills, attach documentation or rules, and ensure cross-agent compatibility.