Skip to content
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

refactor: update node toolchain to provider File objects instead of paths #3727

Closed
wants to merge 1 commit into from

Conversation

gregmagolan
Copy link
Collaborator

@gregmagolan gregmagolan commented Apr 1, 2024

BREAKING CHANGES intended for rules_nodejs 7.0 and rules_js 2.0.

To-date the node toolchain has provided paths (strings) to node and npm. This complicates downstream usage as they need to convert these paths depending on they are used (between execpath and rootpath for example). This change configures the toolchain to instead provide File objects for node and the npm entry point script so downsteam uses can choose to get either the .path or .short_path as needed.

Does this PR introduce a breaking change?

  • Yes
  • No

@gregmagolan gregmagolan force-pushed the nodejs_toolchain_improvements branch 2 times, most recently from 0fe2279 to 9792ad3 Compare April 1, 2024 01:11
@gregmagolan gregmagolan marked this pull request as ready for review April 1, 2024 01:14
@gregmagolan gregmagolan force-pushed the nodejs_toolchain_improvements branch 18 times, most recently from 8629f53 to b6b8b8f Compare April 1, 2024 05:08
@gregmagolan
Copy link
Collaborator Author

Tested this on rules_js 2.0 branch: aspect-build/rules_js#1557.

@gregmagolan gregmagolan force-pushed the nodejs_toolchain_improvements branch from b6b8b8f to d28957a Compare April 1, 2024 21:35
@gregmagolan gregmagolan marked this pull request as draft April 2, 2024 05:22
@alexeagle
Copy link
Collaborator

I think a 7.0 of rules_nodejs is very undesirable. Breaking changes low in the depgraph have always been a major hassle for us and don't work well for users. It would need a lot of devrel care and attention that we don't have much time for.
Can we avoid it?

@gregmagolan
Copy link
Collaborator Author

Replaced by #3736 which maintains backward compat

@gregmagolan gregmagolan closed this Apr 2, 2024
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.

2 participants