Skip to content

Recommend a range for IOScene that nuget.org accepts - #3

Merged
mahach666 merged 1 commit into
mainfrom
fix/nuget-ioscene-range
Nov 13, 2026
Merged

mahach666 merged 1 commit into
mainfrom
fix/nuget-ioscene-range

Conversation

@mahach666

Copy link
Copy Markdown
Contributor

The range that the README and the contract recommend, [0.N.0, 0.N+1.0-0), cannot be published on nuget.org. This changes it to [0.N.0, 0.N+1.0-0.0).

Why

The release of IfcIO 0.11.0 failed at the push of IfcIO.Scene, which depended on IOScene [0.1.0, 0.2.0-0):

400 (The NuGet package contains an invalid .nuspec file. The errors encountered were:
'The package manifest contains an invalid Version: '0.2.0-0'' ...)

nuget.org checks every bound of a dependency range (NuGetGallery ManifestValidator.ValidateDependencyVersion): a bound with metadata is refused, and a bound that is not SemVer 2.0 (one prerelease label) must match ^\d+(\.\d+){0,3}(-[a-z][0-9a-z-]*)?$, so its label must start with a letter. 0.2.0-0 has one label, 0. 0.2.0-0.0 has two, so it is checked as SemVer 2.0 and accepted, and it still keeps out every 0.2.0 preview except 0.2.0-0, which nuget.org accepts only with build metadata and IOScene does not publish.

What changes

  • README.md: the range, the example PackageReference, the NU5104 note, and one sentence on why the bound has two labels.
  • docs/contract.md, section 5: [0.N.0, 0.N+1.0-0.0), and [1.M.0, 2.0.0-0.0) from 1.0.
  • docs/keys.md: the ifc: formats are fixed from IfcIO.Scene 0.11.1, its first release (nuget.org refused 0.11.0).
  • CHANGELOG.md: Fixed entries under [Unreleased]; the preamble says that a patch adds or fixes, as section 5 of the contract does.

Documentation only. The README inside the published 0.1.0 package keeps the old range until the next release.

Checks

  • A small program with NuGet.Versioning 6.12.1 and the gallery regex refuses [0.1.0, 0.2.0-0) (as nuget.org did) and accepts [0.1.0, 0.2.0-0.0) and [1.0.0, 2.0.0-0.0); [0.1.0, 0.2.0-0.0) is satisfied by 0.1.x and not by 0.2.0-preview.1, -alpha, -rc.1 or 0.2.0.
  • IfcIO and RvtIO pack their adapters with this range, and the new check of their pack-release.ps1 passes (IOExtend/IfcIO and IOExtend/RvtIO PRs).
  • Not run: build and tests (no code changes).

nuget.org refuses a dependency bound such as 0.2.0-0: a bound with one
prerelease label is checked by its legacy rule, under which the label must
start with a letter. The release of IfcIO.Scene 0.11.0 failed on it. The README
and section 5 of the contract now recommend [0.N.0, 0.N+1.0-0.0): two labels
make the bound SemVer 2.0, and it keeps out every preview of the next line
except 0.2.0-0, which IOScene does not publish. The key registry fixes the ifc:
formats from IfcIO.Scene 0.11.1, its first release, and the changelog preamble
says that a patch adds or fixes, as the contract does.
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.

1 participant