-
Notifications
You must be signed in to change notification settings - Fork 109
Revert azure-pipelines-task-lib to 2.12.2 to mitigate shelljs bundling issue #539
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
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2340396 to
bc485c0
Compare
awschristou
approved these changes
Jan 22, 2024
This was referenced Aug 1, 2024
hayemaxi
added a commit
to hayemaxi/aws-toolkit-azure-devops
that referenced
this pull request
Nov 25, 2024
Requires a hacky patch to fix shell.js, which doesn't support bundlers. Mitigates the issue described in aws#539 Credit to ivanduplenskikh: https://github.com/ivanduplenskikh/aws-toolkit-azure-devops/pull/1 Co-authored-by: Ivan Duplenskikh <ivanduplenskikh>
5 tasks
hayemaxi
added a commit
to hayemaxi/aws-toolkit-azure-devops
that referenced
this pull request
Nov 25, 2024
Requires a hacky patch to fix shell.js, which doesn't support bundlers. Mitigates the issue described in aws#539 Credit to ivanduplenskikh: https://github.com/ivanduplenskikh/aws-toolkit-azure-devops/pull/1 Co-authored-by: Ivan Duplenskikh <ivanduplenskikh>
hayemaxi
added a commit
to hayemaxi/aws-toolkit-azure-devops
that referenced
this pull request
Nov 25, 2024
Requires a hacky patch to fix shell.js, which doesn't support bundlers. Mitigates the issue described in aws#539 Credit to ivanduplenskikh: https://github.com/ivanduplenskikh/aws-toolkit-azure-devops/pull/1 Co-authored-by: Ivan Duplenskikh <ivanduplenskikh>
hayemaxi
added a commit
to hayemaxi/aws-toolkit-azure-devops
that referenced
this pull request
Nov 25, 2024
Requires a hacky patch to fix shell.js, which doesn't support bundlers. Mitigates the issue described in aws#539 Credit to ivanduplenskikh: https://github.com/ivanduplenskikh/aws-toolkit-azure-devops/pull/1 Co-authored-by: Ivan Duplenskikh <ivanduplenskikh>
hayemaxi
added a commit
to hayemaxi/aws-toolkit-azure-devops
that referenced
this pull request
Nov 25, 2024
Requires a hacky patch to fix shell.js, which doesn't support bundlers. Mitigates the issue described in aws#539 Addresses aws#566 Credit to ivanduplenskikh: https://github.com/ivanduplenskikh/aws-toolkit-azure-devops/pull/1 Co-authored-by: Ivan Duplenskikh <ivanduplenskikh>
hayemaxi
added a commit
to hayemaxi/aws-toolkit-azure-devops
that referenced
this pull request
Nov 25, 2024
Use Node 20 using microsoft guidance: https://learn.microsoft.com/en-us/azure/devops/extend/develop/add-build-task?view=azure-devops#q-how-can-i-upgrade-my-custom-task-to-the-latest-node Keep Node 10 as a fallback. Adding support requires a hacky patch to fix shell.js, which doesn't support bundlers. Mitigates the issue described in aws#539 Addresses aws#566 Credit to ivanduplenskikh: https://github.com/ivanduplenskikh/aws-toolkit-azure-devops/pull/1 Co-authored-by: Ivan Duplenskikh <[email protected]>
hayemaxi
added a commit
to hayemaxi/aws-toolkit-azure-devops
that referenced
this pull request
Nov 25, 2024
Use Node 20 using microsoft guidance: https://learn.microsoft.com/en-us/azure/devops/extend/develop/add-build-task?view=azure-devops#q-how-can-i-upgrade-my-custom-task-to-the-latest-node Keep Node 10 as a fallback. Adding support requires a hacky patch to fix shell.js, which doesn't support bundlers. Mitigates the issue described in aws#539 Addresses aws#566 Credit to ivanduplenskikh: https://github.com/ivanduplenskikh/aws-toolkit-azure-devops/pull/1 Co-authored-by: Ivan Duplenskikh <[email protected]>
hayemaxi
added a commit
to hayemaxi/aws-toolkit-azure-devops
that referenced
this pull request
Nov 25, 2024
Use Node 20 using microsoft guidance: https://learn.microsoft.com/en-us/azure/devops/extend/develop/add-build-task?view=azure-devops#q-how-can-i-upgrade-my-custom-task-to-the-latest-node Keep Node 10 as a fallback. Adding support requires a hacky patch to fix shell.js, which doesn't support bundlers. Mitigates the issue described in aws#539 Addresses aws#566 Credit to ivanduplenskikh: https://github.com/ivanduplenskikh/aws-toolkit-azure-devops/pull/1 Co-authored-by: Ivan Duplenskikh <[email protected]>
hayemaxi
added a commit
to hayemaxi/aws-toolkit-azure-devops
that referenced
this pull request
Nov 25, 2024
Use Node 20 using microsoft guidance: https://learn.microsoft.com/en-us/azure/devops/extend/develop/add-build-task?view=azure-devops#q-how-can-i-upgrade-my-custom-task-to-the-latest-node Keep Node 10 as a fallback. Adding support requires a hacky patch to fix shell.js, which doesn't support bundlers. Mitigates the issue described in aws#539 Addresses aws#566 Credit to ivanduplenskikh: https://github.com/ivanduplenskikh/aws-toolkit-azure-devops/pull/1 Co-authored-by: Ivan Duplenskikh <[email protected]>
hayemaxi
added a commit
to hayemaxi/aws-toolkit-azure-devops
that referenced
this pull request
Nov 25, 2024
Use Node 20 using microsoft guidance: https://learn.microsoft.com/en-us/azure/devops/extend/develop/add-build-task?view=azure-devops#q-how-can-i-upgrade-my-custom-task-to-the-latest-node Keep Node 10 as a fallback. Adding support requires a hacky patch to fix shell.js, which doesn't support bundlers. Mitigates the issue described in aws#539 Addresses aws#566 Credit to ivanduplenskikh: https://github.com/ivanduplenskikh/aws-toolkit-azure-devops/pull/1 Co-authored-by: Ivan Duplenskikh <[email protected]>
hayemaxi
added a commit
to hayemaxi/aws-toolkit-azure-devops
that referenced
this pull request
Nov 25, 2024
Use Node 20 using microsoft guidance: https://learn.microsoft.com/en-us/azure/devops/extend/develop/add-build-task?view=azure-devops#q-how-can-i-upgrade-my-custom-task-to-the-latest-node Keep Node 10 as a fallback. Adding support requires a hacky patch to fix shell.js, which doesn't support bundlers. Mitigates the issue described in aws#539 Addresses aws#566 Credit to ivanduplenskikh: https://github.com/ivanduplenskikh/aws-toolkit-azure-devops/pull/1 Co-authored-by: Ivan Duplenskikh <[email protected]>
hayemaxi
added a commit
to hayemaxi/aws-toolkit-azure-devops
that referenced
this pull request
Nov 25, 2024
Use Node 20 using microsoft guidance: https://learn.microsoft.com/en-us/azure/devops/extend/develop/add-build-task?view=azure-devops#q-how-can-i-upgrade-my-custom-task-to-the-latest-node Keep Node 10 as a fallback. Adding support requires a hacky patch to fix shell.js, which doesn't support bundlers. Mitigates the issue described in aws#539 Addresses aws#566 Credit to ivanduplenskikh: https://github.com/ivanduplenskikh/aws-toolkit-azure-devops/pull/1 Co-authored-by: Ivan Duplenskikh <[email protected]>
hayemaxi
added a commit
to hayemaxi/aws-toolkit-azure-devops
that referenced
this pull request
Nov 25, 2024
Use Node 20 using microsoft guidance: https://learn.microsoft.com/en-us/azure/devops/extend/develop/add-build-task?view=azure-devops#q-how-can-i-upgrade-my-custom-task-to-the-latest-node Keep Node 10 as a fallback. Adding support requires a hacky patch to fix shell.js, which doesn't support bundlers. Mitigates the issue described in aws#539 Addresses aws#566 Credit to ivanduplenskikh: https://github.com/ivanduplenskikh/aws-toolkit-azure-devops/pull/1 Co-authored-by: Ivan Duplenskikh <[email protected]>
hayemaxi
added a commit
to hayemaxi/aws-toolkit-azure-devops
that referenced
this pull request
Nov 25, 2024
Use Node 20 using microsoft guidance: https://learn.microsoft.com/en-us/azure/devops/extend/develop/add-build-task?view=azure-devops#q-how-can-i-upgrade-my-custom-task-to-the-latest-node Keep Node 10 as a fallback. Adding support requires a hacky patch to fix shell.js, which doesn't support bundlers. Mitigates the issue described in aws#539 Addresses aws#566 Credit to ivanduplenskikh: https://github.com/ivanduplenskikh/aws-toolkit-azure-devops/pull/1 Co-authored-by: Ivan Duplenskikh <[email protected]>
hayemaxi
added a commit
to hayemaxi/aws-toolkit-azure-devops
that referenced
this pull request
Nov 25, 2024
Addresses aws#566. Use Node 20 using microsoft guidance: https://learn.microsoft.com/en-us/azure/devops/extend/develop/add-build-task?view=azure-devops#q-how-can-i-upgrade-my-custom-task-to-the-latest-node Keep Node 10 as a fallback. However, we are still building the node10 with esbuild to ensure backwards compatibility. In the future, we can consider building for a higher node version only. Adding support requires a hacky patch to fix shell.js, which doesn't support bundlers. Mitigates the issue described in aws#539 Credit to ivanduplenskikh: https://github.com/ivanduplenskikh/aws-toolkit-azure-devops/pull/1 Co-authored-by: Ivan Duplenskikh <[email protected]>
hayemaxi
added a commit
to hayemaxi/aws-toolkit-azure-devops
that referenced
this pull request
Dec 2, 2024
Addresses aws#566. Use Node 20 using microsoft guidance: https://learn.microsoft.com/en-us/azure/devops/extend/develop/add-build-task?view=azure-devops#q-how-can-i-upgrade-my-custom-task-to-the-latest-node Keep Node 10 as a fallback. However, we are still building the node10 with esbuild to ensure backwards compatibility. In the future, we can consider building for a higher node version only. Adding support requires a hacky patch to fix shell.js, which doesn't support bundlers. Mitigates the issue described in aws#539 Credit to ivanduplenskikh: https://github.com/ivanduplenskikh/aws-toolkit-azure-devops/pull/1 Co-authored-by: Ivan Duplenskikh <[email protected]>
hayemaxi
added a commit
that referenced
this pull request
Dec 3, 2024
Addresses #566. Use Node 20 using microsoft guidance: https://learn.microsoft.com/en-us/azure/devops/extend/develop/add-build-task?view=azure-devops#q-how-can-i-upgrade-my-custom-task-to-the-latest-node Keep Node 10 as a fallback. However, we are still building the node10 with esbuild to ensure backwards compatibility. In the future, we can consider building for a higher node version only. Adding support requires a hacky patch to fix shell.js, which doesn't support bundlers. Mitigates the issue described in #539 Credit to ivanduplenskikh: https://github.com/ivanduplenskikh/aws-toolkit-azure-devops/pull/1 Co-authored-by: Ivan Duplenskikh <[email protected]>
This pull request was closed.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
Background
This is a follow-up pr to fix the issue in #522.
Mark shelljs as external for esbuild bundling attempted to address this issue, but was not a successful solution for all of our tasks, as some of our tasks need the commands present in ShellJS.
Problem
This issue emerged with the bump of
azure-pipelines-task-libdependency in: #473.Problem detailed in the open issue on
azure-pipelines-task-librepo: Cannot use JS bundler because of shelljs dependency.Essentially, the toolkit takes a dependency on
azure-pipelines-task-libwhich takes an additional dependency on ShellJS. Our toolkit uses the esbuild JS Bundler to build the extension. This fails to bundle ShellJS because it uses dynamic require statements (problematic ShellJS code) instead of explicit require statements, which prevents bundlers from correctly analyzing the dependencies.ShellJS has no plans to accommodate these explicit requires statements
Solution
Before making any larger scale changes, let's get
azure-pipelines-task-libback to its last known healthy state (working version we used for last release). This PR addresses that.Future
azure-pipelines-task-libupdatesWhenever we next bump the
azure-pipelines-task-libmajor version, we'll need to keep an eye on updates to microsoft/azure-pipelines-task-lib#942 for any new fixes or workarounds. Current known workarounds involve forking the ShellJS repository, making the necessary changes to ShellJS, and overriding the ShellJS dependency inpackage.jsonwith the forked version.requiresstatementsTesting
node <path-to-task>) to confirm output matches expectationsChecklist
npm run newChangeLicense
By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.