Skip to content
This repository has been archived by the owner on Sep 2, 2023. It is now read-only.

Out-of-Band Meeting Proposal #399

Closed
guybedford opened this issue Oct 11, 2019 · 19 comments
Closed

Out-of-Band Meeting Proposal #399

guybedford opened this issue Oct 11, 2019 · 19 comments

Comments

@guybedford
Copy link
Contributor

Since yesterday's meeting it turns out we were able to work around the async bootstrap issues with a more conservative approach that gets all the tests passing on the experimental modules unflagging PR.

This means that if we can find consensus on requirements for release, there is a window for us to still meet the Node.js 12 LTS release which is on the 21st of October, two days before our next meeting.

In order for us to discuss this possibility, I'd like to propose we arrange an out-of-band meeting early next week. I've created a Doodle to find a shared time for this meeting here -https://doodle.com/poll/a4nvpv6tqf7cnu9g. Please fill this out when you can.

The resolutions from last meeting have now been implemented. I'd like to ask you all to please put some serious consideration to where we are on modules, and any considerations or feedback you have concerning a shippable implementation. It feels like we are very close here, but if we do not have consensus to release there will be other opportunities in future as well - lets see how discussion goes!

@ljharb
Copy link
Member

ljharb commented Oct 11, 2019

I'll reiterate the concern I continue to have - that without a way to support dual modules (both pre-module node + post-module node; and a way to do require('x') and import from 'x' in post-module node) immediately upon unflagging, we'll be doing a great disservice to the community.

My preference would be to hold off unflagging until we've figured out how to achieve it - one of our original use cases from the document.

@GeoffreyBooth
Copy link
Member

Without a way to support dual modules (both pre-module node + post-module node; and a way to do require('x') and import from 'x' in post-module node) immediately upon unflagging, we’ll be doing a great disservice to the community.

Missing the LTS window and not shipping support for ES modules for another year or more also does a great disservice to the community.

We all wanted a better solution for dual packages. I was one of the champions of that effort. Ultimately the best I or anyone could do was require('x') and import from 'x/module', or vice versa require('x/commonjs') and import from 'x', and I wrote the docs explaining and recommending that approach. With "exports" we at least get friendly paths on both sides.

I consider the “ignore the hazard” solution (if you can call it that) to be off the table; it just won’t find approval from core. That leaves “require of ESM” as the last remaining potential solution for making require('x')/import from 'x' a reality. And require of ESM is still achievable; it can ship after unflagging, just as loaders can, and might need to ship in 13 anyway if it creates any breaking changes for CommonJS.

In the meantime people will presumably use the 'x/module' approach, and that’s fine if slightly verbose, and that’ll continue to work in 13 and beyond. I think most members of the community would prefer we unflag now with that limitation rather than wait, especially since there’s no guarantee that we’ll ever find a better solution; it’s hardly a certainty that either core might yield on the hazard or that require of ESM will be implemented in a way that core will accept. If there was a promising solution on the table that had consensus and we just needed time to implement it, sure, I might see holding off unflagging in the hope that we can make that happen; but like you write, this has been a top use case from the beginning and this is the best we’ve been able to come up with after literally years of study.

Conversely, unflagging will draw a lot of new attention to modules in Node, and we might get some new contributors with fresh ideas—maybe someone even implements require of ESM (or some new solution) in a way that it can slip into a later 12.x version.

@ljharb
Copy link
Member

ljharb commented Oct 11, 2019

When you say "from core", who in core is opposed to "ignore the hazard"?

@GeoffreyBooth
Copy link
Member

When you say “from core”, who in core is opposed to “ignore the hazard”?

@MylesBorins, for one. And as both the leader of this group and a member of the TSC I would expect a lot of TSC members would defer to his judgment on this. So sure, if you can convince him, you stand a chance; but the more we’ve been researching it the more firm he’s gotten.

@ljharb
Copy link
Member

ljharb commented Oct 11, 2019

I think it would be worth getting an opinion from the TSC on "ignore the hazard".

@MylesBorins
Copy link
Contributor

MylesBorins commented Oct 11, 2019 via email

@ljharb
Copy link
Member

ljharb commented Oct 11, 2019

@MylesBorins sure. but if there's pressure to unflag in the modules group (ie, full consensus isn't the goal) then why are we holding back solutions just because they lack full consensus?

Let me ask a different way. Let's say the modules group as a whole decides that "ignore the hazard" is acceptable. What solutions seem to be currently available that would allow for dual require/import of a specifier?

@Fishrock123
Copy link
Contributor

Is there a summary of the issue this refers to?

@GeoffreyBooth
Copy link
Member

GeoffreyBooth commented Oct 11, 2019

Is there a summary of the issue this refers to?

@Fishrock123 Please see #371 and https://github.com/jkrems/singleton-issue. Potential solutions are discussed in https://github.com/nodejs/modules/blob/master/doc/plan-for-new-modules-implementation.md#phase-4-further-improvements-after-unflagging under the “Dual CommonJS/ESM packages” bullet.

@GeoffreyBooth
Copy link
Member

GeoffreyBooth commented Oct 11, 2019

Let’s say the modules group as a whole decides that “ignore the hazard” is acceptable.

Currently, at least, this isn’t the case. Besides me and @MylesBorins and @guybedford (and @jkrems?) publicly opposed, this was discussed in the 2019-08-28 and 2019-09-11 meetings and there didn’t seem to be much support within our group for ignoring the hazard.

@mcollina
Copy link
Member

I think the ship has sailed to hit the v12 LTS milestone. I'm not keen on unflagging an experimental feature right before we hit the LTS mark. We can definitely land it after the LTS mark, and I think we should land it in Node v13 (keeping the warning).

@guybedford
Copy link
Contributor Author

#400 sounds like a sensible plan forward here.

It would still be useful to have an out-of-band meeting to be able to determine what we want to ship in the 12 LTS though.

We're currently a few short on quorum responses for the Doodle - please reply there if you haven't already.

@guybedford
Copy link
Contributor Author

*what we want to ship flagged I mean here

@targos
Copy link
Member

targos commented Oct 11, 2019

@guybedford it's too late for that anyway. Today's release is the one that will transition to LTS

@GeoffreyBooth
Copy link
Member

Shipping an LTS release on a Friday? That’s bold . . .

@targos
Copy link
Member

targos commented Oct 11, 2019

You misunderstood me. LTS releases must have their commits bake into a Current release for two weeks. 12.x LTS starts in two weeks. So today's current release has everything that will be in the first 12.x LTS (except the commit that changes the release type)

@guybedford
Copy link
Contributor Author

@targos I wasn't aware there was an LTS cutoff two weeks before, I guess we will have to apply further changes to the next minor then? Or can further --experimental-modules changes land on patch releases?

The goal here would be to be able to say "12 LTS --experimental-modules" is the current recommended implementation. But if we've already missed the cutoff for such a thing then certainly there is no need for an out-of-band meeting.

@MylesBorins
Copy link
Contributor

MylesBorins commented Oct 11, 2019 via email

@guybedford
Copy link
Contributor Author

Ok, in that case, there is no need for an out-of-band meeting then and we can treat the Node 12 case as a possible backport. It is a shame not to have met the deadline - myself and @bmeck have been working on this modules branch for nearly 3 years now. I hope we don't let this drag on for much more than the current 4 years since ES6 for landing modules in Node.js.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

7 participants