jborean93 / PowerShell-Yayaml

A YAML parser and writer that uses an Assembly Load Context on PowerShell 7+
MIT License
31 stars 2 forks source link

Provide workaround for import problems #12

Closed jborean93 closed 11 months ago

jborean93 commented 12 months ago

When a user imports this module more than once with -Force PowerShell will fail to populate the ExportedCommands breaking the module. This provides a workaround to avoid this issue until the problem is fixed in PowerShell https://github.com/PowerShell/PowerShell/issues/20710.

Fixes: https://github.com/jborean93/PowerShell-Yayaml/issues/11

codecov[bot] commented 12 months ago

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Comparison is base (13ee077) 93.03% compared to head (93b8269) 93.03%.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #12 +/- ## ======================================== Coverage 93.03% 93.03% ======================================== Files 15 15 Lines 1048 1407 +359 Branches 181 181 ======================================== + Hits 975 1309 +334 - Misses 47 70 +23 - Partials 26 28 +2 ``` | [Flag](https://app.codecov.io/gh/jborean93/PowerShell-Yayaml/pull/12/flags?src=pr&el=flags&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Jordan+Borean) | Coverage Δ | | |---|---|---| | [PS_7.2_x64_Linux](https://app.codecov.io/gh/jborean93/PowerShell-Yayaml/pull/12/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Jordan+Borean) | `93.03% <ø> (+<0.01%)` | :arrow_up: | | [PS_7.2_x64_Windows](https://app.codecov.io/gh/jborean93/PowerShell-Yayaml/pull/12/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Jordan+Borean) | `∅ <ø> (∅)` | | | [PS_7.3_x64_Linux](https://app.codecov.io/gh/jborean93/PowerShell-Yayaml/pull/12/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Jordan+Borean) | `93.03% <ø> (+<0.01%)` | :arrow_up: | | [PS_7.3_x64_Windows](https://app.codecov.io/gh/jborean93/PowerShell-Yayaml/pull/12/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Jordan+Borean) | `?` | | Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Jordan+Borean#carryforward-flags-in-the-pull-request-comment) to find out more.

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.