Skip to content

Commit 33c2050

Browse files
Discover historical baselines without restricting configured prefix characters
Use suffix matching only for candidate discovery and retain exact release, module-version asset and immutable source checks before baseline completeness. (cherry picked from commit 0281a03)
1 parent 33efec4 commit 33c2050

2 files changed

Lines changed: 3 additions & 1 deletion

File tree

‎.github/actions/Resolve-PSModuleVersion/README.md‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,8 @@ Only one exact source/context claim with matching raw package bytes can select a
2424

2525
An unpublished shared-only claim still stops Plan for original-job retry, even after a later source completes another version. A new source checks baseline completeness using the actual historical tag and release, not a tag reconstructed with the current configured prefix. Recovery and new claims still require exact configured-prefix binding; ambiguous historical baselines stop explicitly.
2626

27+
Historical prefixes may contain digits, with or without a separator. A matching version suffix only discovers a candidate tag; exact release metadata, matching module/version asset and immutable tag source must establish baseline completeness. Numeric suffixes alone never establish ownership.
28+
2729
| Failure | Safe behavior |
2830
| --- | --- |
2931
| Gallery-only package has missing, foreign, or legacy proof | Stop version resolution; do not reuse the package or invent a fallback number. |

‎.github/actions/Resolve-PSModuleVersion/src/Resolve-PSModuleVersion.Helpers.psm1‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -847,7 +847,7 @@ function Get-PSModuleGalleryRecoveryVersion {
847847
}
848848
$tag = $reference.ref.Substring('refs/tags/'.Length)
849849
if ($null -ne $galleryVersion -and -not $tag.StartsWith('PSModule-Publication/', [StringComparison]::Ordinal) -and
850-
$tag -cmatch "^\D*$([regex]::Escape($galleryVersion))$") {
850+
$tag.EndsWith($galleryVersion, [StringComparison]::Ordinal)) {
851851
$null = $baselineTags.Add($tag)
852852
}
853853
$isCoordinate = $tag.StartsWith($coordinatePrefix, [StringComparison]::Ordinal)

0 commit comments

Comments
 (0)