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
Fix multi-entry with cross-require #1268
Conversation
Some that come to mind (don't know which already exist):
|
Re: the "slow" stream, actually I guess you could just do: var stream = through2();
stream.write("whatever");
b.require(stream);
b.require('./whatever');
stream.end(); |
Thanks! Those test ideas make sense. I'll write those up before continuing on a refactor, but we should merge this in as a stopgap though. |
FWIW I still have the concerns I voiced in #1248 (comment), #1248 (comment). |
@jmm So to summarize your concerns:
We just need decisions, right? Because it's not a technical problem - it's easy to code up. How do we decide? Is it our place to decide? And are you ok if I merge this to fix the immediate problem? |
Right.
I think it's fruitful for collaborators or any interested parties to discuss it, but if it's not clear cut what should happen I suppose @substack would need to make the call.
Ultimately it's your decision as you don't need my approval. Until these issues get legitimately dealt with I think it would make more sense to revert to the previous situation, where the CLI pseudo-resolved the paths. It's important to keep in mind that #1248 changed the resolution behavior of the API. Maybe the previous resolution behavior was an accident, maybe not, but I think we should try to minimize churn until those questions are deliberately decided. Right now we're chasing our tails with these kinds of changes. It wouldn't surprise me if these changes, while fixing one problem, cause other unexpected problems, even beyond the already noted change to resolution behavior. |
405f708
to
785fe15
Compare
Fix multi-entry with cross-require
Fixes #1266. I broke it in #1248. What was happening was that I was setting
row.file
too late, androw.id
was not getting the full path. The example in #1266 would've worked via the CLI before #1248, but not via the API. This PR fixes that.@jmm I really want to merge the refactor of
b.require
from https://gist.github.com/zertosh/e66a3e96afc45228f02b (taking these changes into account). What tests do you think are missing before we can do it w/o fear of major breakage?