-
Notifications
You must be signed in to change notification settings - Fork 266
fix: Add TypeForwardedTo attribute to forward other moved interfaces #1340
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR adds backwards compatibility with version 21 by forwarding types that were moved to a separate assembly in version 22. It enables third-party dependencies built with version 21 to automatically resolve interfaces to their new location in Testably.Abstractions.FileSystem.Interface.dll
when they try to access them from the old location in TestableIO.System.IO.Abstractions.dll
.
- Adds TypeForwardedTo attributes for all moved interfaces to enable automatic type resolution
- Maintains existing IFileSystem forward declaration from previous work
- Provides seamless compatibility for transitive dependencies using version 21
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
This is addressed in release v22.0.16. |
Updated [System.IO.Abstractions](https://github.com/TestableIO/System.IO.Abstractions) from 22.0.15 to 22.0.16. <details> <summary>Release notes</summary> _Sourced from [System.IO.Abstractions's releases](https://github.com/TestableIO/System.IO.Abstractions/releases)._ ## 22.0.16 ## What's Changed * chore(deps): update dependency system.text.json to 9.0.7 by @renovate[bot] in TestableIO/System.IO.Abstractions#1306 * chore(deps): update dependency awexpect to 2.18.1 by @renovate[bot] in TestableIO/System.IO.Abstractions#1307 * chore(deps): update dependency dotnet-sdk to v9.0.302 by @renovate[bot] in TestableIO/System.IO.Abstractions#1308 * chore(deps): update dependency awexpect to 2.19.0 by @renovate[bot] in TestableIO/System.IO.Abstractions#1309 * chore(deps): update dependency awexpect to 2.19.1 by @renovate[bot] in TestableIO/System.IO.Abstractions#1310 * chore(deps): update dependency awexpect.testably to 0.11.0 by @renovate[bot] in TestableIO/System.IO.Abstractions#1311 * chore(deps): update dependency dotnet-sdk to v9.0.303 by @renovate[bot] in TestableIO/System.IO.Abstractions#1314 * chore(deps): update dependency awexpect to 2.20.0 by @renovate[bot] in TestableIO/System.IO.Abstractions#1315 * chore(deps): update dependency awexpect to 2.21.0 by @renovate[bot] in TestableIO/System.IO.Abstractions#1316 * chore(deps): update dependency system.text.json to 9.0.8 by @renovate[bot] in TestableIO/System.IO.Abstractions#1317 * chore(deps): update dependency dotnet-sdk to v9.0.304 by @renovate[bot] in TestableIO/System.IO.Abstractions#1318 * chore(deps): update actions/download-artifact action to v5 by @renovate[bot] in TestableIO/System.IO.Abstractions#1319 * chore(deps): update dependency nunit.analyzers to 4.10.0 by @renovate[bot] in TestableIO/System.IO.Abstractions#1320 * chore(deps): update dependency nunit to 4.4.0 by @renovate[bot] in TestableIO/System.IO.Abstractions#1321 * chore(deps): update dependency nunit3testadapter to 5.1.0 by @renovate[bot] in TestableIO/System.IO.Abstractions#1322 * chore(deps): update actions/checkout action to v5 by @renovate[bot] in TestableIO/System.IO.Abstractions#1323 * chore(deps): update dependency awexpect to 2.21.1 by @renovate[bot] in TestableIO/System.IO.Abstractions#1324 * docs: Add comprehensive documentation about relationship with Testably.Abstractions by @Copilot in TestableIO/System.IO.Abstractions#1326 * docs: Create comprehensive GitHub Copilot instructions for System.IO.Abstractions development by @Copilot in TestableIO/System.IO.Abstractions#1328 * chore(deps): update dependency awexpect to 2.22.0 by @renovate[bot] in TestableIO/System.IO.Abstractions#1331 * chore(deps): update actions/setup-dotnet action to v5 by @renovate[bot] in TestableIO/System.IO.Abstractions#1332 * chore(deps): update dependency awexpect to 2.23.0 by @renovate[bot] in TestableIO/System.IO.Abstractions#1334 * chore(deps): update dependency system.text.json to 9.0.9 by @renovate[bot] in TestableIO/System.IO.Abstractions#1333 * chore(deps): update dependency dotnet-sdk to v9.0.305 by @renovate[bot] in TestableIO/System.IO.Abstractions#1335 * chore(deps): update dependency awexpect.testably to 0.12.0 by @renovate[bot] in TestableIO/System.IO.Abstractions#1336 * fix: Add TypeForwardedTo attribute to forward IFileSystem usage to its new… by @borisf94 in TestableIO/System.IO.Abstractions#1338 * fix: use `dotnet nuget` to push packages by @vbreuss in TestableIO/System.IO.Abstractions#1339 * fix: Add TypeForwardedTo attribute to forward other moved interfaces by @borisf94 in TestableIO/System.IO.Abstractions#1340 ## New Contributors * @Copilot made their first contribution in TestableIO/System.IO.Abstractions#1326 * @borisf94 made their first contribution in TestableIO/System.IO.Abstractions#1338 **Full Changelog**: TestableIO/System.IO.Abstractions@v22.0.15...v22.0.16 Commits viewable in [compare view](TestableIO/System.IO.Abstractions@v22.0.15...v22.0.16). </details> [](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores) 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 merge` will merge this PR after your CI passes on it - `@dependabot squash and merge` will squash and merge this PR after your CI passes on it - `@dependabot cancel merge` will cancel a previously requested merge and block automerging - `@dependabot reopen` will reopen this PR if it is closed - `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually - `@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> Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Updated [System.IO.Abstractions](https://github.com/TestableIO/System.IO.Abstractions) from 22.0.15 to 22.0.16. <details> <summary>Release notes</summary> _Sourced from [System.IO.Abstractions's releases](https://github.com/TestableIO/System.IO.Abstractions/releases)._ ## 22.0.16 ## What's Changed * chore(deps): update dependency system.text.json to 9.0.7 by @renovate[bot] in TestableIO/System.IO.Abstractions#1306 * chore(deps): update dependency awexpect to 2.18.1 by @renovate[bot] in TestableIO/System.IO.Abstractions#1307 * chore(deps): update dependency dotnet-sdk to v9.0.302 by @renovate[bot] in TestableIO/System.IO.Abstractions#1308 * chore(deps): update dependency awexpect to 2.19.0 by @renovate[bot] in TestableIO/System.IO.Abstractions#1309 * chore(deps): update dependency awexpect to 2.19.1 by @renovate[bot] in TestableIO/System.IO.Abstractions#1310 * chore(deps): update dependency awexpect.testably to 0.11.0 by @renovate[bot] in TestableIO/System.IO.Abstractions#1311 * chore(deps): update dependency dotnet-sdk to v9.0.303 by @renovate[bot] in TestableIO/System.IO.Abstractions#1314 * chore(deps): update dependency awexpect to 2.20.0 by @renovate[bot] in TestableIO/System.IO.Abstractions#1315 * chore(deps): update dependency awexpect to 2.21.0 by @renovate[bot] in TestableIO/System.IO.Abstractions#1316 * chore(deps): update dependency system.text.json to 9.0.8 by @renovate[bot] in TestableIO/System.IO.Abstractions#1317 * chore(deps): update dependency dotnet-sdk to v9.0.304 by @renovate[bot] in TestableIO/System.IO.Abstractions#1318 * chore(deps): update actions/download-artifact action to v5 by @renovate[bot] in TestableIO/System.IO.Abstractions#1319 * chore(deps): update dependency nunit.analyzers to 4.10.0 by @renovate[bot] in TestableIO/System.IO.Abstractions#1320 * chore(deps): update dependency nunit to 4.4.0 by @renovate[bot] in TestableIO/System.IO.Abstractions#1321 * chore(deps): update dependency nunit3testadapter to 5.1.0 by @renovate[bot] in TestableIO/System.IO.Abstractions#1322 * chore(deps): update actions/checkout action to v5 by @renovate[bot] in TestableIO/System.IO.Abstractions#1323 * chore(deps): update dependency awexpect to 2.21.1 by @renovate[bot] in TestableIO/System.IO.Abstractions#1324 * docs: Add comprehensive documentation about relationship with Testably.Abstractions by @Copilot in TestableIO/System.IO.Abstractions#1326 * docs: Create comprehensive GitHub Copilot instructions for System.IO.Abstractions development by @Copilot in TestableIO/System.IO.Abstractions#1328 * chore(deps): update dependency awexpect to 2.22.0 by @renovate[bot] in TestableIO/System.IO.Abstractions#1331 * chore(deps): update actions/setup-dotnet action to v5 by @renovate[bot] in TestableIO/System.IO.Abstractions#1332 * chore(deps): update dependency awexpect to 2.23.0 by @renovate[bot] in TestableIO/System.IO.Abstractions#1334 * chore(deps): update dependency system.text.json to 9.0.9 by @renovate[bot] in TestableIO/System.IO.Abstractions#1333 * chore(deps): update dependency dotnet-sdk to v9.0.305 by @renovate[bot] in TestableIO/System.IO.Abstractions#1335 * chore(deps): update dependency awexpect.testably to 0.12.0 by @renovate[bot] in TestableIO/System.IO.Abstractions#1336 * fix: Add TypeForwardedTo attribute to forward IFileSystem usage to its new… by @borisf94 in TestableIO/System.IO.Abstractions#1338 * fix: use `dotnet nuget` to push packages by @vbreuss in TestableIO/System.IO.Abstractions#1339 * fix: Add TypeForwardedTo attribute to forward other moved interfaces by @borisf94 in TestableIO/System.IO.Abstractions#1340 ## New Contributors * @Copilot made their first contribution in TestableIO/System.IO.Abstractions#1326 * @borisf94 made their first contribution in TestableIO/System.IO.Abstractions#1338 **Full Changelog**: TestableIO/System.IO.Abstractions@v22.0.15...v22.0.16 Commits viewable in [compare view](TestableIO/System.IO.Abstractions@v22.0.15...v22.0.16). </details> [](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores) 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 merge` will merge this PR after your CI passes on it - `@dependabot squash and merge` will squash and merge this PR after your CI passes on it - `@dependabot cancel merge` will cancel a previously requested merge and block automerging - `@dependabot reopen` will reopen this PR if it is closed - `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually - `@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> Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
) Updated [System.IO.Abstractions.TestingHelpers](https://github.com/TestableIO/System.IO.Abstractions) from 22.0.15 to 22.0.16. <details> <summary>Release notes</summary> _Sourced from [System.IO.Abstractions.TestingHelpers's releases](https://github.com/TestableIO/System.IO.Abstractions/releases)._ ## 22.0.16 ## What's Changed * chore(deps): update dependency system.text.json to 9.0.7 by @renovate[bot] in TestableIO/System.IO.Abstractions#1306 * chore(deps): update dependency awexpect to 2.18.1 by @renovate[bot] in TestableIO/System.IO.Abstractions#1307 * chore(deps): update dependency dotnet-sdk to v9.0.302 by @renovate[bot] in TestableIO/System.IO.Abstractions#1308 * chore(deps): update dependency awexpect to 2.19.0 by @renovate[bot] in TestableIO/System.IO.Abstractions#1309 * chore(deps): update dependency awexpect to 2.19.1 by @renovate[bot] in TestableIO/System.IO.Abstractions#1310 * chore(deps): update dependency awexpect.testably to 0.11.0 by @renovate[bot] in TestableIO/System.IO.Abstractions#1311 * chore(deps): update dependency dotnet-sdk to v9.0.303 by @renovate[bot] in TestableIO/System.IO.Abstractions#1314 * chore(deps): update dependency awexpect to 2.20.0 by @renovate[bot] in TestableIO/System.IO.Abstractions#1315 * chore(deps): update dependency awexpect to 2.21.0 by @renovate[bot] in TestableIO/System.IO.Abstractions#1316 * chore(deps): update dependency system.text.json to 9.0.8 by @renovate[bot] in TestableIO/System.IO.Abstractions#1317 * chore(deps): update dependency dotnet-sdk to v9.0.304 by @renovate[bot] in TestableIO/System.IO.Abstractions#1318 * chore(deps): update actions/download-artifact action to v5 by @renovate[bot] in TestableIO/System.IO.Abstractions#1319 * chore(deps): update dependency nunit.analyzers to 4.10.0 by @renovate[bot] in TestableIO/System.IO.Abstractions#1320 * chore(deps): update dependency nunit to 4.4.0 by @renovate[bot] in TestableIO/System.IO.Abstractions#1321 * chore(deps): update dependency nunit3testadapter to 5.1.0 by @renovate[bot] in TestableIO/System.IO.Abstractions#1322 * chore(deps): update actions/checkout action to v5 by @renovate[bot] in TestableIO/System.IO.Abstractions#1323 * chore(deps): update dependency awexpect to 2.21.1 by @renovate[bot] in TestableIO/System.IO.Abstractions#1324 * docs: Add comprehensive documentation about relationship with Testably.Abstractions by @Copilot in TestableIO/System.IO.Abstractions#1326 * docs: Create comprehensive GitHub Copilot instructions for System.IO.Abstractions development by @Copilot in TestableIO/System.IO.Abstractions#1328 * chore(deps): update dependency awexpect to 2.22.0 by @renovate[bot] in TestableIO/System.IO.Abstractions#1331 * chore(deps): update actions/setup-dotnet action to v5 by @renovate[bot] in TestableIO/System.IO.Abstractions#1332 * chore(deps): update dependency awexpect to 2.23.0 by @renovate[bot] in TestableIO/System.IO.Abstractions#1334 * chore(deps): update dependency system.text.json to 9.0.9 by @renovate[bot] in TestableIO/System.IO.Abstractions#1333 * chore(deps): update dependency dotnet-sdk to v9.0.305 by @renovate[bot] in TestableIO/System.IO.Abstractions#1335 * chore(deps): update dependency awexpect.testably to 0.12.0 by @renovate[bot] in TestableIO/System.IO.Abstractions#1336 * fix: Add TypeForwardedTo attribute to forward IFileSystem usage to its new… by @borisf94 in TestableIO/System.IO.Abstractions#1338 * fix: use `dotnet nuget` to push packages by @vbreuss in TestableIO/System.IO.Abstractions#1339 * fix: Add TypeForwardedTo attribute to forward other moved interfaces by @borisf94 in TestableIO/System.IO.Abstractions#1340 ## New Contributors * @Copilot made their first contribution in TestableIO/System.IO.Abstractions#1326 * @borisf94 made their first contribution in TestableIO/System.IO.Abstractions#1338 **Full Changelog**: TestableIO/System.IO.Abstractions@v22.0.15...v22.0.16 Commits viewable in [compare view](TestableIO/System.IO.Abstractions@v22.0.15...v22.0.16). </details> [](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores) 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 merge` will merge this PR after your CI passes on it - `@dependabot squash and merge` will squash and merge this PR after your CI passes on it - `@dependabot cancel merge` will cancel a previously requested merge and block automerging - `@dependabot reopen` will reopen this PR if it is closed - `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually - `@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> Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Following #1338
This PR adds TypeForwardedToAttribute to fix a problem where a transitive dependency on ver 21 can't find interfaces that were moved to a separate assembly in version 22.
Using the attribute, allows third parties that are built with ver 21 to be redirected to Testably.Abstractions.FileSystem.Interface.dll when trying to resolve the interface in its old location: TestableIO.System.IO.Abstractions.dll
This change adds backwards compatibility with ver 21.
Users of ver 22 are not affected in any way.