Skip to content

Develop - #25

Merged
lorentsob merged 52 commits into
mainfrom
develop
Nov 24, 2026
Merged

lorentsob merged 52 commits into
mainfrom
develop

Conversation

@lorentsob

Copy link
Copy Markdown
Owner

Release merge from develop.

Changes

  • Notifications (Fix/notification overdue reminders #24): rolling overdue reminders.
  • CI: xcpretty is now optional in the build step (the self-hosted runner moved to a new Apple Silicon Mac without it).
  • Splash and brand: animated Batch logo on launch (static logo with Reduce Motion), refreshed app icon set, fixed 1024 marketing icon filename case.
  • Bakes: recipes adapt doses and procedure text when switching to commercial yeast; step descriptions rendered as bullet lists; UI refinements across bakes, formulas, fermentations, kefir and starter.
  • Content fix: restored the five knowledge guides, glossary aliases and the "Pan Brioche (lievito di birra)" formula lost in the 2026-04-09 merge ce73c95.
  • Docs: product design case history and knowledge export.

Verification

  • CI build on develop (self-hosted, Xcode 27.2): passed.
  • Unit tests on iPhone 18 Pro simulator, iOS 27.2: 57 XCTest + 80 Swift Testing passed (before the content fix: 19 failures).
  • UI tests are not run in CI and are stale: the same 14 of 19 tests in KefirFlowUITests and BakesFlowUITests fail with and without these changes.

🤖 Generated with Claude Code

lorentsob and others added 30 commits March 17, 2026 11:58
* chore(ci): add develop branch to CI triggers

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>

* chore(ci): add DerivedData + Homebrew cache, update CLAUDE.md workflow rules

- Cache DerivedData keyed on Swift sources + project.yml (incremental builds)
- Cache Homebrew to skip xcodegen reinstall on unchanged deps
- Remove redundant `clean` from cached build step
- Add periodic clean build guidance to CLAUDE.md
- Update branch discipline rules to reflect develop/main split

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>

---------

Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
* fix(ci): remove manual simulator boot step that caused hang

xcrun simctl bootstatus -b blocks indefinitely on GitHub Actions runners.
xcodebuild boots the simulator automatically when given a named destination.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>

* fix(tests): fix all failing unit and UI tests

- Populate knowledge.json with 8 items covering starter, fermentation,
  bakerMath and troubleshooting categories (was empty, breaking all
  KnowledgeLoader/KnowledgeLibrary tests)
- BakeReminderPlanner: "La finestra sta terminando." → "La finestra si
  sta chiudendo." (string mismatch with test expectation)
- StateBadge: StarterDueState.ok now returns .done tone instead of
  .count (matches spec-driven test expectation)
- TodayView: "Aggiungi uno starter" → "Aggiungi starter" (label
  mismatch with UI test)
- BakesView: "Nessun bake attivo" → "Nessun bake ancora" (label
  mismatch with UI test)
- BakesFlowUITests: update testNewBakeUsesBundledTemplates to reflect
  current picker UI ("Template di sistema") — "Template rapidi" section
  was intentionally removed in a prior refactor

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>

* fix(tests): fix remaining UI test failures

- TodayView/FeaturePillCard: add .accessibilityLabel(title) so XCUITest
  finds the button by exact title ("Aggiungi starter") instead of the
  auto-derived label that includes the subtitle text
- TodayFlowUITests: "Dettaglio" → "Procedimento" (correct button label
  in ActiveStepHeroCard)
- BakesFlowUITests: verify picker element exists instead of tapping
  into it (Picker interaction unreliable on CI)

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>

* fix(tests): use correct element type for Form Picker in UI test

* chore(ci): switch to self-hosted runner, run CI only on push to develop/main

---------

Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
* feat(16-01): add step-level ingredients to FormulaStepTemplate and BakeStep

- Add ingredients: [String] field to FormulaStepTemplate (Codable)
- Add ingredientsPayload: String? + stepIngredients computed var to BakeStep (@model)
- Update BakeScheduler to pass template ingredients to BakeStep on creation
- Preserve existing ingredients in FormulaStepEditorView save path
- Update RecipeFormula.duplicate() to carry through step ingredients

* feat(16-01): parse step-specific ingredients in content formatter

- Add match_step_ingredients() to ContentFormatter matching ingredient
  subsection titles to step names (case-insensitive, substring match)
- Pass ingredient_sections to parse_steps() so each step can be
  annotated with its matched ingredient list
- Each step in defaultSteps JSON now carries an "ingredients" array
- Regenerate system_formulas.json: focaccia Impasto step gets 6
  ingredients; bagel and potato-buns Impasto steps matched via
  "impasto" substring; other formulas/steps correctly return []

* feat(16-01): display step-specific ingredients in BakeStepDetailView modal

- Add "Ingredienti" section above "Procedimento" in the phase modal
- Renders ingredient lines using the same bullet bar style as BakeIngredientsView
- Section is hidden entirely when the step has no associated ingredients
- Ingredients sourced from BakeStep.stepIngredients (decoded from ingredientsPayload)

* docs(16-01): complete step-level ingredients baking phase modal plan

Tasks completed: 3/3
- Task 1: Model Schema Updates (FormulaStepTemplate, BakeStep)
- Task 2: Content Formatter Enhancement (format_content.py, system_formulas.json)
- Task 3: Phase Modal UI Update (BakeStepDetailView)

SUMMARY: .planning/phases/16-baking-phase-ingredients-ux/16-01-SUMMARY.md

* docs(phase-16): complete baking phase ingredients UX phase

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>

* Enhance formula documentation and step parsing

- Added tests to ensure bundled formulas preserve explicit labels for custom steps in SystemFormulaLoaderTests.
- Updated bagel-levain.md to reflect explicit labels for levain and boiling steps.
- Changed section titles in focaccia-tiktok.md for clarity.
- Revised ingredient sections and step titles in pan-brioche-lievito-madre.md for better organization.
- Modified pizza-in-giornata.md to clarify ingredient sections and improve step descriptions.
- Updated potato-buns.md to include explicit labels for custom steps.
- Removed outdated compiled Python file from scripts/__pycache__.
- Enhanced step parsing logic in format_content.py to support custom labels in step definitions.

* fix(scripts): improve Xcode and XcodeGen version retrieval in ci_bootstrap.sh

* Initial plan (#8)


---------

Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
…11)

* fix(notifications): update remaining callers to new syncNotifications API

* fix(concurrency): add @mainactor to views using ModelContext in Task

* fix(concurrency): add @mainactor to views using ModelContext in Task
* fix(notifications): update BakesView to use forBake label

* fix(tests): use type-agnostic query for BakesScrollView (List not ScrollView)
* feat(bakes): enhance bake completion handling and UI updates

- Added asynchronous handling for bake completion notifications to prevent UI crashes.
- Updated BakeDetailView and TodayView to delay saving and notification sync for completed bakes.
- Introduced a new BakesArchiveView for managing archived bakes with filtering options.
- Adjusted animations and UI text for better user experience.
- Refactored various views to ensure proper use of @mainactor for UI updates.

* pipeline build&test

* fix(concurrency): add @mainactor to Task in BakeCreationView for notification sync

* ci più fast

* Enhance iOS CI workflow to run tests on direct pushes to develop branch

- Added steps to clean previous test results and run tests only on pushes to the develop branch.
- Implemented artifact upload for test results with a retention policy.
- Updated comments to clarify the testing strategy for pull requests and direct pushes.
* elimina tasto modifica da ricetta

* Potential fix for pull request finding


---------
- Introduced a new button to open the formula editor.
- Implemented defensive checks for potentially corrupted legacy data in hydration, inoculation, salt, and weight calculations.
- Updated UI elements to use safe values, ensuring no NaN or non-finite values are displayed.
- Renamed sections for consistency, changing "Fasi di default" to "Preparazione".
- Enhanced the FormulaStepEditorView with new duration and reminder pickers for better user interaction.
* feat(v2-shell): Phase 17 — shell & Preparazioni hubs

Migrate root shell from v1 four-tab layout to v2 three-tab shell
(Oggi / Preparazioni / Knowledge). Introduce Preparazioni hub with
Pane e lievito madre and Milk kefir domain cards, and prepare the
additive SwiftData v2 schema boundary before kefir models land.

Key changes:
- RootTab enum: .oggi / .preparazioni / .knowledge
- PreparationsRoute replaces BakesRoute + StarterRoute for unified
  navigation; direct-object routing bypasses hub traversal from
  notifications and Oggi operational taps
- New views: PreparationsView, PreparationHubCardView, BreadHubView,
  KefirHubView (placeholder)
- LevainSchemaV2 additive boundary + 9 PersistenceMigrationTests
- All existing bread/starter deep links and notification routing
  preserved through the migrated shell
- 23/23 unit tests passing; UI test coverage updated + new
  PreparationsFlowUITests suite

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>

* v2 docs

* ci: trigger build after runner restart

* ci: retry build

---------

Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
…View, kefir-ready router (#20)

* feat(oggi): Phase 18 — cross-domain agenda feed, TodayOperationalCardView, kefir-ready router

- TodayAgendaBuilder: unified ranked feed with domain/urgency metadata, kefir-ready Kind.kefir
- TodayOperationalCardView: shared domain-cued card wrapper (Pane/Starter/Kefir grammar)
- TodayView: feed-based rendering replaces section buckets, tomorrow taps use router.openBake
- TodayStepCardView/TodayStarterReminderRow: urgency-based labels replace section-based
- AppRouter: PreparationsRoute.kefirBatch(UUID), openKefirBatch, DeepLink.kefirBatch
- Tests: TodayAgendaBuilderTests v2 ordering contract, AppRouterTests kefir+direct-route, NotificationRouteUITests v2 shell identifiers

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>

* fix(review): address PR #20 review comments

- "Nuovo kefir" → "Nuovo batch" for copy consistency with Kefir hub and addendum A4
- Fix nested buttons in PreparationHubCardView and BreadHubEntryRow: replace outer Button with contentShape+onTapGesture so inner empty-state CTA receives taps correctly
- Remove stale Phase 18-02 forward references from TodayAgendaBuilder comments
- Fix English accessibility label "… domain" → Italian "Dominio: …" in TodayOperationalCardView

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>

---------

Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
Area: ui
Conversione sourdough → lievito commerciale con ricalcolo farina/acqua/tempi

Made-with: Cursor
- Aggiunge YeastProfile enum (slow/medium/fast) e YeastType.instantYeast
- Introduce YeastConversionService con logica di conversione sourdough→commerciale
  (scomposizione starter, calcolo lievito per 500g farina, conversioni tra tipi)
- BakeScheduler accetta YeastConversionResult: sostituisce farina/acqua/durate
  di bulk e proof in base al profilo tempi scelto
- BakeCreationView: sezione "Fonte lievito" con segmented picker
  Lievito madre / Commerciale + picker tipo lievito + picker profilo +
  preview ricalcolo in tempo reale (farina, acqua, grammi lievito, durate)

Made-with: Cursor
- RecipeFormula: aggiunto isSystemFormula e isModifiedFromDefault
- AppSettings: aggiunto didSeedSystemFormulas per idempotenza seeding
- SeedDataLoader: ensureSystemFormulas() persiste system_formulas.json in
  SwiftData al primo avvio (indipendente dal seed di esempio)
- SystemFormulaLoader: loadSystemFormulas() + formula(id:) per lookup da JSON
- FormulaListView: mostra tutte le ricette (sistema + utente); badge
  "Mia ricetta" per le personali, "Modificata" per quelle di sistema editate
- FormulaDetailView: bottone matita in toolbar (in alto a destra), bottone
  "Ripristina default" con confirmation dialog per ricette di sistema editate
- FormulaEditorView: imposta isModifiedFromDefault=true al salvataggio di
  una ricetta di sistema

Fixes: .planning/todos/pending/2026-04-04-formula-edit-and-unified-list.md
Made-with: Cursor
…fault per migrazione SwiftData

Made-with: Cursor
- RecipeFormula: aggiunto isArchived: Bool = false per supportare l'archivio
- FormulaDetailView: renderizza ora le sezioni Ingredienti e Dettagli
  (procedimento) dal JSON, precedentemente parsate ma non mostrate
- FormulaListView: convertito in List per supportare swipeActions;
  swipe a sinistra → archivia la ricetta; bottone "Archivio ricette" visibile
  quando ci sono ricette archiviate; FormulaArchiveView integrata con
  swipe destra ripristina, swipe sinistra elimina, selezione multipla

Made-with: Cursor
…itorView

I campi multiriga usavano LabeledContent con testo allineato a destra,
schiacciandoli in pochi pixel. Sostituiti con VStack label+TextEditor
a piena larghezza per una lettura e modifica comoda.

Made-with: Cursor
Con 'let formula: RecipeFormula', SwiftUI non registrava correttamente la
subscription sulle proprietà interne del @model (es. defaultStepsPayload),
perciò FormulaDetailView non si aggiornava dopo il salvataggio.
Cambiato in '@bindable var formula' per garantire la piena osservabilità.

Made-with: Cursor
…epsPayload)

- RecipeFormula: defaultStepsPayload non più private così SwiftData può
  propagare correttamente le notifiche di modifica sul payload degli step
- FormulaLookupView: sostituito fetch one-shot in @State con @query filtrata
  per id, così FormulaDetailView riceve sempre l'istanza osservata dal
  contesto e si ridisegna dopo save dal foglio modifica

Made-with: Cursor
lorentsob and others added 22 commits April 4, 2026 15:45
…isual-style spam

- Sostituito loaf.fill (non presente nel set di simboli) con fork.knife
- FormulaDetailView: token di hash sui campi persistiti + .id() sul contenuto
  per forzare il ridisegno dopo modifica (workaround ForEach/step UUID)
- FormulaStepEditorView: rimosso scrollContentBackground(.hidden) sui
  TextEditor; sfondo card con corner radius per ridurre warning UIKit

Made-with: Cursor
… foglio

Il token derivato da Hasher su Double/Data poteva cambiare tra un frame e
l'altro, ricreando il VStack all'infinito e bloccando l'app.

Sostituito con @State detailRefreshToken incrementato solo quando il foglio
modifica ricetta si chiude (wasShowing && !isShowing) o dopo ripristino.

TextEditor: tolto sfondo annidato nel Form; solo scrollContentBackground hidden.
Made-with: Cursor
Updates AppRouter, BreadHub, Today; expands Starter model/views;
BakeScheduler + tests; system_formulas content; Xcode project/scheme.

Made-with: Cursor
…e BakesView structure

- Modified EmptyStateView to accept optional actionTitle and action parameters, allowing for more flexible usage.
- Refactored BakesView to utilize the new EmptyStateView structure, enhancing readability and maintainability.
- Introduced a new ClassifiedBakes struct to better categorize active and archived bakes.
- Updated various views to remove unnecessary presentation backgrounds and improve layout consistency.

Made-with: Cursor
- Finalized Phase 23, introducing canonical glossary routing, read-only linking, and alias-aware search for improved knowledge access.
- Updated project documentation to reflect the completion of Phase 23 and the transition to Phase 22 for optional culture and grain tracking.
- Enhanced the app's navigation and user experience by integrating contextual knowledge presentation and refining the UI for better accessibility.

Made-with: Cursor
- Deleted the Batch subproject as it is no longer needed in the current project structure.
- Resolve content conflicts across Swift source files (take develop version)
- Resolve CI workflow conflicts (keep both main+develop branch triggers)
- Remove .planning/ files deleted in develop's public release alignment
- Add README portfolio upgrade

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Theme.Layout does not exist — use Theme.Spacing.md for horizontal
padding and Theme.Spacing.xl for bottom padding.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
- Add AppSettings.didSeedSystemFormulas field missing from model
- Fix SectionCardEmphasis type reference in KefirBatchPresentation
- Remove non-existent yeastConversion: param from generateBake call;
  apply conversion to transient formula weights instead
- Add missing onSaved: param to FormulaEditorView call sites
- Regenerate xcodeproj to include KnowledgeGlossaryIndex and
  GlossaryLinkedText files missing from sources

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
The merge conflict resolution incorrectly used --theirs (origin/main)
instead of --ours (develop) for all Swift source files, reverting them
to an older version. Restore all affected files from 2230b15.

Build verified passing.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
- Enhanced the SVG logo by restructuring styles and adding a clipPath for better rendering.
- Renamed the "Avanzate" section to "Note" in BakeCreationView for clarity.
- Improved layout and spacing in BakeCreationView, including adjustments to data rows and dividers for better visual hierarchy.
- Updated YeastType short titles for consistency in terminology.
- Refined text styles in TodayStarterReminderRow and TodayView for improved readability.
Set documentation and automation for contributors to target develop.
Add pull_request_target workflow that comments and closes PRs to main
opened by users other than lorentsob. Default branch on GitHub is main.

Made-with: Cursor
Resolve README/CONTRIBUTING merge; keep Italian CONTRIBUTING and full Contributing section in README.

Made-with: Cursor
…iews

- Changed "Fasi della ricetta" in BakeDetailView for better context.
- Corrected "fase non piu attiva" to "fase non più attiva" in BakeStepCardView for grammatical accuracy.
- Removed period from "I tuoi batch attivi." in FermentationsView subtitle for consistency.
- Updated notification message in KefirBatchManageSheet to "Rinnovo registrato" for clarity.
- Adjusted subtitles in KefirHubView and StarterView for improved readability.
- Simplified message in TodayView for a more concise user experience.
- Enhanced KefirBatchState titles for better understanding of batch statuses.
- Refined reminder messages in BakeReminderPlanner and KefirReminderPlanner for clarity and consistency.
The self-hosted runner moved to a new Mac without xcpretty; with
pipefail the build step failed on 'command not found'. Fall back to
plain output when xcpretty is missing.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- Splash plays the BatchLogoLoading video (static logo with Reduce Motion)
- New app icon set; fix 1024 marketing icon filename case
- Add AppLogoPrimary and updated logo SVGs
- Add Remotion source used to render the loading animation

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- RecipeYeastAdaptationService adapts doses and procedure text when
  switching to commercial yeast; scheduler uses converted dough weight
- DescriptionBulletList renders step descriptions as bullet lists
- UI refinements in bakes, formulas, fermentations, kefir and starter
- Tests for commercial yeast adaptation

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The 2026-04-09 merge ce73c95 (resolving PR #22 conflicts) reverted
knowledge.json to a pre-Phase 23 version, dropping five guides and all
glossary aliases, and removed the 'Pan Brioche (lievito di birra)'
system formula. Glossary linking and alias search were silently empty.

Restore both from 0d51d09, keeping later edits to the pizza formula.
Unit tests: 57 XCTest + 80 Swift Testing now pass (18+1 failed before).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Copilot AI balanced review requested due to automatic review settings November 24, 2026 11:02
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 24, 2026 •

Copy link
Copy Markdown
Codex Review Summary: ✅ Completed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-24T11:04:27.401931Z 9731460 PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has insufficient remaining quota. Try requesting a review at a lower effort level.

@lorentsob
lorentsob merged commit caffe25 into main Nov 24, 2026
4 checks passed

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 9731460acc

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment on lines +208 to +213
sections[sectionIndex].items = sections[sectionIndex].items.map { item in
if referencesSourdough(item) {
replacedYeast = true
return yeastLine
}
return adaptText(item, conversion: conversion, targetYeastType: targetYeastType)

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Reintegrate starter flour and water into ingredient quantities

When converting a sourdough recipe, this mapping replaces the starter with commercial yeast but leaves every flour and water quantity unchanged. For the bundled “Pizza in giornata”, the resulting ingredient list still instructs users to use 600 g flour and 360 ml water after removing the 100 g starter, whereas the conversion and bake metrics include approximately 650 g flour and 410 g water. Following the displayed recipe therefore produces a different hydration and dough quantity from the planned bake. Update both the recipe ingredient payload and step ingredients to include the flour and water formerly supplied by the starter.

Useful? React with 👍 / 👎.

Comment on lines +348 to +350
starter: conversionForBake == nil ? selectedStarter : nil,
notes: notes,
yeastConversion: conversionForBake

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Adapt commercial recipe instructions before changing their schedule

For an already-commercial recipe, convertedSourdoughFormula is false, so the original ingredient quantities and procedure are retained even though conversionForBake now changes the bake's yeast percentage and fermentation durations. For example, creating the bundled “Pan Brioche (lievito di birra)” with the default medium profile schedules a six-hour bulk fermentation and calculates 9 g fresh yeast, while its ingredient list still specifies 6 g and its bulk-step instructions say two hours. Apply the selected profile consistently to the commercial recipe's ingredients and instructions before passing its conversion to the scheduler.

Useful? React with 👍 / 👎.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants