Skip to content

Add uSync.Files and use it for the folder integrity health check - #1294

Merged
KevinJump merged 5 commits into
v17/mainfrom
feature/usync-files
Nov 23, 2026
Merged

KevinJump merged 5 commits into
v17/mainfrom
feature/usync-files

Conversation

@KevinJump

Copy link
Copy Markdown
Member

Adds uSync.Files, a dependency-free package holding the offline uSync folder checks, and makes the "uSync - Folder Clash check" health check use it.

The same code (same git blobs) runs in uSync.Cli's new files-verify command, which the new pipeline actions (Jumoo/usync-actions) use. Once this package ships, the CLI switches to it, so there is one copy of the rules.

Package

  • uSync.Files targets net10.0 and has no dependencies. It is packed like uSync.Core and added to release.yml, prerelease.yml and dist/build-package.ps1.
  • uSync.BackOffice has a project reference to it, so the BackOffice package now depends on uSync.Files.
  • Tests are in uSync.Files.Tests (NUnit), and all three workflows run them.

Health check changes

  • The id, name and group are unchanged, and no public API was removed.
  • New error results:
    • unresolved merge conflicts, with line numbers, including markers inside CDATA, which still parse as valid XML
    • items of the same type that share an alias but have different keys
    • items that are both deleted and live
  • Behaviour changes:
    • Keys clash only within the same type. Content and PublicAccess sharing a node's key is no longer reported.
    • A file that fails to load because of conflict markers is listed under conflicts, not under invalid XML.

SyncFileService.VerifyFolderAsync is unchanged. It gates imports from uploaded zips, so moving it over would start blocking imports on the new rules.

Tested

  • The Release build exits 0.
  • uSync.Tests 362/362 pass, including 8 new health check tests, and uSync.Files.Tests 33/33 pass.
  • Not yet run on a live site from this branch. Over the Management API, the CLI's healthcheck-group-check -g uSync returned exit 1 for a key clash on uSync 17.6.3. That is the old health check; the same call should be repeated with a package built from this branch.

🤖 Generated with Claude Code

KevinJump and others added 5 commits November 23, 2026 17:50
Copied from the uSync.CommandLine files-verify code so the health check and
the command line share one copy. No Umbraco dependencies (BCL and
System.Xml.Linq only), packed as its own package.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The key clash and invalid config checks now come from uSync.Files, and the
check adds results for merge conflict markers, alias clashes and items that
are both deleted and live. Keys only clash within the same type now, so
Content and PublicAccess sharing a node's key is no longer reported.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

release/17.6.4 uSync 17.6.4 release

Development

Successfully merging this pull request may close these issues.

1 participant