Skip to content
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(core): Refresh transplanted views at insertion point only #35968

Closed
wants to merge 1 commit into from

Conversation

atscott
Copy link
Contributor

@atscott atscott commented Mar 9, 2020

Only refresh transplanted views at the insertion location in Ivy.
This change fixes several issues:

@atscott atscott force-pushed the containsdirtyproposal branch 7 times, most recently from 2820401 to cde7f9e Compare March 10, 2020 19:37
@matsko matsko added the area: core Issues related to the framework runtime label Mar 10, 2020
@ngbot ngbot bot added this to the needsTriage milestone Mar 10, 2020
@atscott
Copy link
Contributor Author

atscott commented Mar 10, 2020

presubmit - failures seem to be pre-existing by comparing to recent clean run

global also seems to look good when compared to recent run

I've also confirmed that this PR fixes the 3 of 4 test failures that were suspected to have been caused by transplanted view CD differences between Ivy and VE (I think one is actually a different issues after investigation).

@atscott atscott force-pushed the containsdirtyproposal branch 3 times, most recently from ae78b21 to d723859 Compare March 10, 2020 23:18
@atscott atscott marked this pull request as ready for review March 11, 2020 16:43
@atscott atscott added action: review The PR is still awaiting reviews from at least one requested reviewer target: patch This PR is targeted for the next patch release labels Mar 11, 2020
@atscott atscott force-pushed the containsdirtyproposal branch 2 times, most recently from 895d6bd to 2ba4f43 Compare March 11, 2020 21:12
@atscott atscott force-pushed the containsdirtyproposal branch 9 times, most recently from f292ace to cc1ded8 Compare April 17, 2020 20:51
Copy link
Contributor

@kara kara left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@atscott atscott force-pushed the containsdirtyproposal branch 2 times, most recently from 828d6ab to 7a258a7 Compare April 28, 2020 00:20
@pkozlowski-opensource pkozlowski-opensource removed their request for review April 28, 2020 20:14
@atscott atscott removed the request for review from IgorMinar April 28, 2020 22:00
@atscott atscott added action: merge The PR is ready for merge by the caretaker and removed action: review The PR is still awaiting reviews from at least one requested reviewer labels Apr 28, 2020
@AndrewKushnir AndrewKushnir added the action: presubmit The PR is in need of a google3 presubmit label Apr 29, 2020
@AndrewKushnir
Copy link
Contributor

AndrewKushnir commented Apr 29, 2020

FYI, I've started global presubmit (with Ivy) and will update this thread with the results as soon as I get them.

@AndrewKushnir
Copy link
Contributor

FYI, global presubmit went well.

@atscott could you please rebase this PR and resolve conflicts?

@AndrewKushnir AndrewKushnir added action: cleanup The PR is in need of cleanup, either due to needing a rebase or in response to comments from reviews and removed action: presubmit The PR is in need of a google3 presubmit labels Apr 29, 2020
Only refresh transplanted views at the insertion location in Ivy.
Previously, Ivy would check transplanted views at both the insertion and
declaration points. This is achieved by adding a marker to the insertion
tree when we encounter a transplanted view that needs to be refreshed at
its declaration. We use this marker as an extra indication that we still
need to descend and refresh those transplanted views at their insertion
locations even if the insertion view and/or its parents are not dirty.

This change fixes several issues:

  * Transplanted views refreshed twice if both insertion and declaration
  are dirty. This could be an error if the insertion component changes
  result in data not being available to the transplanted view because it
  is slated to be removed.
  * CheckAlways transplanted views not refreshed if shielded by
  non-dirty OnPush (fixes angular#35400)
  * Transplanted views still refreshed when insertion tree is detached
  (fixes angular#21324)
@AndrewKushnir AndrewKushnir removed the action: cleanup The PR is in need of cleanup, either due to needing a rebase or in response to comments from reviews label Apr 29, 2020
AndrewKushnir pushed a commit that referenced this pull request Apr 29, 2020
Only refresh transplanted views at the insertion location in Ivy.
Previously, Ivy would check transplanted views at both the insertion and
declaration points. This is achieved by adding a marker to the insertion
tree when we encounter a transplanted view that needs to be refreshed at
its declaration. We use this marker as an extra indication that we still
need to descend and refresh those transplanted views at their insertion
locations even if the insertion view and/or its parents are not dirty.

This change fixes several issues:

  * Transplanted views refreshed twice if both insertion and declaration
  are dirty. This could be an error if the insertion component changes
  result in data not being available to the transplanted view because it
  is slated to be removed.
  * CheckAlways transplanted views not refreshed if shielded by
  non-dirty OnPush (fixes #35400)
  * Transplanted views still refreshed when insertion tree is detached
  (fixes #21324)

PR Close #35968
@angular-automatic-lock-bot
Copy link

This issue has been automatically locked due to inactivity.
Please file a new issue if you are encountering a similar or related problem.

Read more about our automatic conversation locking policy.

This action has been performed automatically by a bot.

@angular-automatic-lock-bot angular-automatic-lock-bot bot locked and limited conversation to collaborators May 30, 2020
profanis pushed a commit to profanis/angular that referenced this pull request Sep 5, 2020
…r#35968)

Only refresh transplanted views at the insertion location in Ivy.
Previously, Ivy would check transplanted views at both the insertion and
declaration points. This is achieved by adding a marker to the insertion
tree when we encounter a transplanted view that needs to be refreshed at
its declaration. We use this marker as an extra indication that we still
need to descend and refresh those transplanted views at their insertion
locations even if the insertion view and/or its parents are not dirty.

This change fixes several issues:

  * Transplanted views refreshed twice if both insertion and declaration
  are dirty. This could be an error if the insertion component changes
  result in data not being available to the transplanted view because it
  is slated to be removed.
  * CheckAlways transplanted views not refreshed if shielded by
  non-dirty OnPush (fixes angular#35400)
  * Transplanted views still refreshed when insertion tree is detached
  (fixes angular#21324)

PR Close angular#35968
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
action: merge The PR is ready for merge by the caretaker area: core Issues related to the framework runtime cla: yes target: patch This PR is targeted for the next patch release
Projects
None yet
6 participants