From 3b23cd3c4c4fb4bf74346f18a2af18c09c8b589a Mon Sep 17 00:00:00 2001 From: Natalia Portillo Date: Thu, 18 Jun 2026 04:18:59 +0100 Subject: [PATCH] feat: Add lessons learned documentation and guidelines for persistent agent notes --- .agents/lessons-learned.md | 7 +++++++ AGENTS.md | 3 ++- 2 files changed, 9 insertions(+), 1 deletion(-) create mode 100644 .agents/lessons-learned.md diff --git a/.agents/lessons-learned.md b/.agents/lessons-learned.md new file mode 100644 index 00000000..c7fdccb2 --- /dev/null +++ b/.agents/lessons-learned.md @@ -0,0 +1,7 @@ +# Lessons Learned + +## 2026-06-18 + +- In `Marechai/Pages/Admin/SoftwareReleaseDialog.razor`, release regions and languages cannot rely on `ReleaseId` during add mode because the release does not exist yet. Keep provisional junction selections in local dialog state and return them through `SoftwareReleaseDialogResult`. +- Persist add-mode release regions and languages only after `SoftwareReleasesService.CreateAsync(...)` succeeds in `Marechai/Pages/Admin/SoftwareReleases.razor.cs`. +- When fixing add-mode behavior for one release junction picker in this dialog, check the sibling pickers for the same `ReleaseId <= 0` pattern. Regions and languages had the same bug shape. diff --git a/AGENTS.md b/AGENTS.md index 155d2c6a..07aec1d5 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -110,6 +110,8 @@ Test results are stored in the `TestResults/` directory. ## Notes for AI Agents +0. Persistent agent notes and lessons learned should be stored under `.agents/` in this repository. + 1. When adding new pages/views to Marechai.App: - Create ViewModel in `Presentation/ViewModels/` - Create View (XAML) in `Presentation/Views/` @@ -129,4 +131,3 @@ Test results are stored in the `TestResults/` directory. 4. Package versions are centrally managed - update `Directory.Packages.props` when adding/updating packages. 5. The project targets .NET 10.0 preview - be aware of potential API changes. -