Skip to content

v5: Fix MolarFlow per-hour abbreviations#1683

Merged
angularsen merged 1 commit into
maintenance/v5from
agl-codex/fix-molar-flow-hour-abbreviations-v5
Jul 17, 2026
Merged

v5: Fix MolarFlow per-hour abbreviations#1683
angularsen merged 1 commit into
maintenance/v5from
agl-codex/fix-molar-flow-hour-abbreviations-v5

Conversation

@angularsen

Copy link
Copy Markdown
Owner

Motivation

Backport of #1682 for the v5 maintenance branch.

Issue #1663 reports that the generated abbreviations for MolarFlow per-hour units are shifted by one kilo prefix:

  • MolarFlowUnit.MolePerHour formats/parses as kmol/h
  • MolarFlowUnit.KilomolePerHour formats/parses as kkmol/h

The root cause is that MolePerHour has Prefixes: [ "Kilo" ], but its base abbreviation in MolarFlow.json was already written as kmol/h. The prefix generator then prepended another k for the generated KilomolePerHour unit.

Changes

  • Change MolePerHour abbreviation from kmol/h to mol/h.
  • Regenerate MolarFlow resources and generated tests.
  • Generated abbreviations now match the other molar-flow units:
    • MolePerHour: mol/h
    • KilomolePerHour: kmol/h

Validation

  • dotnet run --project CodeGen -p:NuGetAudit=false
  • dotnet test UnitsNet.Tests -f net48 --filter "FullyQualifiedName~MolarFlowTests" -p:NuGetAudit=false
  • dotnet test UnitsNet.Tests -f net9.0 -p:NuGetAudit=false

Note: plain restore/codegen on this maintenance branch is currently blocked by an unrelated NuGet audit warning for NuGet.Protocol 6.12.1, so validation used NuGetAudit=false to avoid changing dependencies in this bugfix PR.

Fixes #1663.

@angularsen
angularsen marked this pull request as ready for review July 17, 2026 17:03
@angularsen
angularsen merged commit 332218e into maintenance/v5 Jul 17, 2026
1 check passed
@angularsen
angularsen deleted the agl-codex/fix-molar-flow-hour-abbreviations-v5 branch July 17, 2026 17:04
@angularsen

Copy link
Copy Markdown
Owner Author

mergify Bot pushed a commit to TekuSP/framework-dotnet that referenced this pull request Jul 20, 2026
Bump UnitsNet and UnitsNet.NumberExtensions (#44)

Updated [UnitsNet](https://github.com/angularsen/UnitsNet) from 5.75.0 to 5.75.1.

<details>
<summary>Release notes</summary>

_Sourced from [UnitsNet's releases](https://github.com/angularsen/UnitsNet/releases)._

## 5.75.1

## What's Changed
* Deprecating the Multiply/Divide methods for the Temperature by @​lipchev in angularsen/UnitsNet#1589
* Making the methods from UnitMath that exist in System.Linq as [Obsolete] by @​lipchev in angularsen/UnitsNet#1593
* Deprecating the Dimensions property in favor of QuantityInfo.BaseDimensions (v5) by @​lipchev in angularsen/UnitsNet#1610
* v5: Fix MolarFlow per-hour abbreviations by @​angularsen in angularsen/UnitsNet#1683


**Full Changelog**: angularsen/UnitsNet@UnitsNet/5.75.0...UnitsNet/5.75.1

Commits viewable in [compare view](angularsen/UnitsNet@UnitsNet/5.75.0...UnitsNet/5.75.1).
</details>

Updated [UnitsNet.NumberExtensions](https://github.com/angularsen/UnitsNet) from 5.75.0 to 5.75.1.

<details>
<summary>Release notes</summary>

_Sourced from [UnitsNet.NumberExtensions's releases](https://github.com/angularsen/UnitsNet/releases)._

## 5.75.1

## What's Changed
* Deprecating the Multiply/Divide methods for the Temperature by @​lipchev in angularsen/UnitsNet#1589
* Making the methods from UnitMath that exist in System.Linq as [Obsolete] by @​lipchev in angularsen/UnitsNet#1593
* Deprecating the Dimensions property in favor of QuantityInfo.BaseDimensions (v5) by @​lipchev in angularsen/UnitsNet#1610
* v5: Fix MolarFlow per-hour abbreviations by @​angularsen in angularsen/UnitsNet#1683


**Full Changelog**: angularsen/UnitsNet@UnitsNet/5.75.0...UnitsNet/5.75.1

Commits viewable in [compare view](angularsen/UnitsNet@UnitsNet/5.75.0...UnitsNet/5.75.1).
</details>

Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)


</details>
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