fix: handle RuntimeLevel.Upgrading in CanAutoPublish#484
Conversation
Greptile SummaryThis PR bumps the minimum Umbraco 17 requirement to 17.4.0 and fixes
Confidence Score: 5/5Safe to merge; the The core logic change — allowlisting src/Articulate.Tests/Migrations/ArticulateMigrationPlanExecutedHandlerTests.cs — consider adding a Important Files Changed
Flowchart%%{init: {'theme': 'neutral'}}%%
flowchart TD
A[Notification fired\nMigrationPlansExecuted\nor ImportedPackage] --> B[CanAutoPublish]
B --> C{NET10_0_OR_GREATER?}
C -- Yes --> D{RuntimeLevel is\nRun or Upgrading?}
C -- No --> E{RuntimeLevel is\nRun?}
D -- No --> F[return false\nskip publish]
D -- Yes --> G{AutoPublishOnStartup\nenabled?}
E -- No --> F
E -- Yes --> G
G -- No --> F
G -- Yes --> H[return true\nproceed to publish]
H --> I{Which notification?}
I -- MigrationPlansExecuted --> J{HasMigrationRun?}
I -- ImportedPackage --> K{installedRoots.Count > 0?}
J -- No --> F
J -- Yes --> L[PublishArticulateRoots\nGetAllArticulateRoots\nForceRepublish filter]
K -- No --> F
K -- Yes --> M[PublishArticulateRoots\nInstalledRoots only\nAll filter for new roots]
Reviews (9): Last reviewed commit: "fix: restore package_json_file for pnpm ..." | Re-trigger Greptile |
|
Still relevant, |
|
This branch was developed on top of pr/17.4 locally because RuntimeLevel.Upgrading support requires the newer 17.3+ API. |
There was a problem hiding this comment.
Pull request overview
Note
Copilot was unable to run its full agentic suite in this review.
This PR updates Articulate’s Umbraco 17 baseline to 17.4.0, refreshes several dependency/tooling versions, and adjusts auto-publish behavior/logging around migrations/package imports.
Changes:
- Bump minimum Umbraco 17 requirement from 17.2.2 to 17.4.0 across docs, build props, and Docker defaults.
- Update dependencies/tooling (FileSignatures, Markdig, pnpm, test SDK) and remove OpenMcdf references.
- Broaden runtime levels that allow post-migration auto-publish and reduce log noise by shifting many messages to Debug.
Reviewed changes
Copilot reviewed 17 out of 18 changed files in this pull request and generated 7 comments.
Show a summary per file
| File | Description |
|---|---|
| umbraco-marketplace-readme.md | Updates Umbraco 17 minimum version to 17.4.0. |
| src/Articulate/Migrations/ArticulateMigrationPlanExecutedHandler.cs | Adjusts auto-publish gating by runtime level and changes log levels. |
| src/Articulate/Articulate.csproj | Updates NuGet package versions; removes OpenMcdf reference. |
| src/Articulate.Web/Client/package.json | Updates pnpm packageManager version. |
| src/Articulate.Web/Articulate.Web.csproj | Mirrors dependency updates/removal from core project. |
| src/Articulate.Tests/Migrations/ArticulateMigrationPlanExecutedHandlerTests.cs | Adds net10-only test for RuntimeLevel.Upgrading behavior. |
| src/Articulate.Tests/Articulate.Tests.csproj | Updates test SDK; removes OpenMcdf reference. |
| src/Articulate.Tests.Website/Articulate.Tests.Website.csproj | Removes OpenMcdf reference. |
| global.json | Updates .NET SDK selection/roll-forward strategy. |
| docker-compose.yml | Updates default Umbraco CMS version range to start at 17.4.0. |
| build/docker-site/ArticulateDockerSite.csproj | Removes OpenMcdf reference. |
| RELEASE_NOTES.md | Updates documented minimum Umbraco 17 version. |
| README.md | Updates documented minimum Umbraco 17 version. |
| Dockerfile | Updates base images and default Umbraco version range. |
| Directory.Build.props | Updates Umbraco 17 package range; removes OpenMcdf version property. |
| .github/workflows/build.yml | Updates GH Actions versions and .NET/pnpm setup behavior. |
| .devcontainer/Dockerfile | Updates pnpm version used in devcontainer. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
- bump Markdig 0.45.0 (match Umbraco 17.4.0) - bump FileSignatures 7.1 (updates transitive dependency OpenMcdf to 3.1.4) - bump Microsoft.NET.Test.Sdk 18.4.0 - bump pnpm 11.4.0 and reinstall dependencies - bump GitHub actions to latest - amend dotnet version to dynamically match newest feature band
- Change CanAutoPublish guard from 'is not RuntimeLevel.Run' to 'is RuntimeLevel.Boot or RuntimeLevel.BootFailed or RuntimeLevel.Unknown' so Umbraco 17's new RuntimeLevel.Upgrading does not block auto-publish after unattended install, without breaking Umbraco 16 where the enum value does not exist. - Add diagnostic logging showing RuntimeLevel and AutoPublishOnStartup values to aid future debugging.
Change initial CanAutoPublish log to Debug to reduce info noise and clarify when auto-publish checks run. Replace the previous Boot/BootFailed/Unknown check with an explicit allowlist (RuntimeLevel.Run, Install, Upgrade) so migration/publish tasks are only considered in valid runtime scenarios. Update log message wording and add a comment explaining the rationale.
…aco 17.3+ - reduce information log noise
Migration plans run at Run for normal/manual path's, or Upgrading for unattended - `RuntimeLevel.Upgrading` added in Umbraco 17.3
path
- bump Markdig 0.45.0 (match Umbraco 17.4.0) - bump FileSignatures 7.1 (updates transitive dependency OpenMcdf to 3.1.4) - bump Microsoft.NET.Test.Sdk 18.4.0 - bump pnpm 11.4.0 and reinstall dependencies - bump GitHub actions to latest - amend dotnet version to dynamically match newest feature band
Depends on #488 (needs Umbraco 17.4 for RuntimeLevel.Upgrading).