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.
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.
We definitely want this removed for low-deps but what about high?
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.
Hmm. Removing this wouldn't work for high deps if we added a new feature to Twig & Live components at the same time, which use each other. In that case, the Live component would install the stable Twig Component, which wouldn't include the still-unreleased new Twig component feature.
The same could technically be true for low deps... but it's likely much more less common and this would work fine. The edge-case I'm talking about is (same as above) if we added a new feature to Twig + Live components that rely on each other. Then, assuming the current stable release is 2.0, we change LiveComponent to rely on TwigComponent 2.1. That'll fail, because 2.1 isn't released, etc, etc.
This is why the complex solution in symfony/symfony exists. WDYT?
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.
Ok, so definitely run this script for high deps.
Not sure how to handle your second point. This does seem valid - some of the things we discussed recently (embedded components) would do this.
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.
Yea, the "complex solution" in symfony/symfony looks... complex to me 🙃. But i think it's also the only true solution. Consider #248: you remembered to bump the composer.json file there. But if you had forgotten, the tests would still pass. The "real" solution is to, when testing live-component, to download its real dependencies... except if the version specified in composer.json is the next, unreleased version (e.g. like 2.1, which you've correctly specified). In that case, I think symfony/symfony basically "patches" in the twig-component code from the PR as version "2.1".