-
-
Notifications
You must be signed in to change notification settings - Fork 3.5k
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
Consider reverting change to EntityCommands calling convention #15521
Comments
The issue he is facing is something that has been solved in There are situations that cannot be resolved per se, which is again the reason NOTE: I am fine to leave it as-is, just worried about the astronomical impact for ??? gains. I mean if it would bring performance benefits or enable something mission critical we couldn't do before, yeah why not... Edit: |
Yeah, I feel like we should revert this change before the release candidate and keep insert_if. |
I'm willing to do the partial revert |
Yes please :) |
@eidloi I'm not sure what you mean, the diff does resolve my example. Can you elaborate on why you think it doesn't? |
An interesting thing about the count of changes in that particular diff is that most of the reassignments were only necessary because the context was It's definitely also possible that the lack of these ergonomics originally have forced workarounds that are now tightly ingrained and hard to refactor away in larger codebases. The cost of that would be unfortunate for folks to have to deal with for sure. |
'twas just a feeling I got looking at the code in the issue. Not mentioning the soundness of the examples in there, I wasn't looking at it too long 'cus it irks me to attempt to use commands in a callback of commands. Just anti-rusty if you ask me. But if you are keen on having this line of methods, maybe an optional extension could be created to provide self-consuming variants and then developers can switch to that if they feel the need. Maybe a |
Here you go: https://github.com/UmbraLuminosa/sickle_ui/compare/migration_attempt_to_0.15?expand=1 |
It's certainly sound, but I get the personal preference on usage there. Trying to ease the pains of heavily nested UI is what got me here, I think trying to push that up out of the callbacks likely makes things a lot harder to manage and maintain. Whether a separate consuming variant is the way, I'll leave that to the folks in charge. 😄 |
Yeah, so aside from the changes that look like they're necessary from other unrelated updates, this looks generally like the tightening I would expect from the ergonomics change. I think the one case of having to re-assign I see in there could be resolved with I am wondering tho if this diff is the entire thing? I thought you'd mentioned something about adding EDIT : Yeah, ok, I dug a bit deeper into the underlying code for those changes and I see kind of what's happening there. It's funny that we're both ending up here trying to make the UI experience easier. |
Yepp :D |
Within the changes in this PR I counted 6 cases where the change to consuming
self
enabled chaining.On the other hand I counted 15 instances where doing re-assignment (
entity_commands = entity_commands.XXX()
) was now necessary.IMO, that's not looking great.
Right, we do have release candidates now. That does ease my worries a bit.
Originally posted by @tim-blackbird in #14897 (comment)
The text was updated successfully, but these errors were encountered: