-
Notifications
You must be signed in to change notification settings - Fork 11.1k
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
[5.4.19] Breaking change in Container::build #19122
Comments
Please explain more why you think that commit broke your code |
Because manually reverting that change (moving the line back into the original place) makes my test work again, both on 5.4.19 and 5.4.22 (latest). |
@sisve - if you replace your |
@laurencei I've tested gist you've provided. It didn't fixed issue in jsvalidation package. |
This happens because Not working: if (isset($this->instances[$abstract]) && ! $needsContextualBuild) {
array_pop($this->with);
return $this->instances[$abstract];
} Working: if (isset($this->instances[$abstract]) && ! $needsContextualBuild) {
return $this->instances[$abstract];
} |
@a-kokarev really? The very first line of the gist I listed above sets the
array - so I don't see how it could be empty?
Did you copy and paste the entire function?
|
@laurencei Yes, I've copied entire function. |
@laurencei, @a-komarev Have you tried the test I provided in the issue? I've give you exact code I can use to reproduce the issue, and haven't seen any response regarding if it's a faulty reproduction, if no one else has the issue and it's something in my end, etc. At the moment I'm asked to explain why I some code broke something, but I believe that I've already proven that something broke (and I also believe I am very sure what caused it). If my test can reproduce the issue, then it can probably also verify the fix. That means we can get this solved quickly instead of waiting around for others to confirm that the guessed fix in a separate branch somewhere did or did not fix the issue. So, can anyone confirm that this indeed a breaking change, or is the test that I think can reproduce it wrong? |
@a-komarev - does the package work with 5.4.16? Can you please test and
advise?
@sisve - I plan on testing your code etc when I get home in a few hours.
I'll report back then with more info.
|
@laurencei Yes, tested it right now. It's working on 5.4.16 |
Ok - so I've done some testing. The changes in 5.4.19 do result in the above, but I think it might actually stem from 5.4.16 and were just hidden. I'll keep working on it and give some results back shortly... |
Ok - I've done a PR and Taylor has accepted it. That should hopefully have fixed the issues in this thread? Please confirm if you still run into any issues... |
No issues in the jsvalidation package with your fix! Great job @laurencei ! |
As mentioned on Slack, #19161 fixed my issues too. Rejoice! |
Description:
The commit ebe568c causes the provided tests to fail in 5.4.19. The test works in 5.4.18.
Steps To Reproduce:
Result:
The text was updated successfully, but these errors were encountered: