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): properly execute content queries for root components #54457

Conversation

pkozlowski-opensource
Copy link
Member

Prior to this fix an incorrect view instance (a dynamically created component one instead of the root view) was passed to the content query function. Having incorrect view instance meant that a component instance could not be found.

This is a pre-existing bug, introduction of signal-based queries just surfaced it.

Fixes #54450

Prior to this fix an incorrect view instance (a dynamically created component
one instead of the root view) was passed to the content query function. Having
incorrect view instance meant that a component instance could not be found.

This is a pre-existing bug, introduction of signal-based queries just surfaced it.

Fixes angular#54450
@pkozlowski-opensource pkozlowski-opensource added action: review The PR is still awaiting reviews from at least one requested reviewer area: core Issues related to the framework runtime labels Feb 15, 2024
@ngbot ngbot bot added this to the Backlog milestone Feb 15, 2024
@pkozlowski-opensource pkozlowski-opensource added the target: patch This PR is targeted for the next patch release label Feb 15, 2024
@@ -56,8 +58,6 @@ import {selectIndexInternal} from './advance';
import {ɵɵdirectiveInject} from './di';
import {handleUnknownPropertyError, isPropertyValid, matchingSchemas} from './element_validation';
import {writeToDirectiveInput} from './write_to_directive_input';
import { AttributeMarker } from '../interfaces/attribute_marker';
import { InputFlags } from '../interfaces/input_flags';
Copy link
Member

Choose a reason for hiding this comment

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

Weird that these got reformatted 🤔 not a blocker for the change though.

Copy link
Member Author

Choose a reason for hiding this comment

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

Yeh, I run my editor with organize imports + format on save. So organize imports made it flagged as "changed" and the formatter did the rest :-)

@pkozlowski-opensource pkozlowski-opensource 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 Feb 15, 2024
@AndrewKushnir
Copy link
Contributor

This PR was merged into the repository by commit d9a1a7d.

AndrewKushnir pushed a commit that referenced this pull request Feb 15, 2024
Prior to this fix an incorrect view instance (a dynamically created component
one instead of the root view) was passed to the content query function. Having
incorrect view instance meant that a component instance could not be found.

This is a pre-existing bug, introduction of signal-based queries just surfaced it.

Fixes #54450

PR Close #54457
atscott pushed a commit to atscott/angular that referenced this pull request Feb 16, 2024
…lar#54457)

Prior to this fix an incorrect view instance (a dynamically created component
one instead of the root view) was passed to the content query function. Having
incorrect view instance meant that a component instance could not be found.

This is a pre-existing bug, introduction of signal-based queries just surfaced it.

Fixes angular#54450

PR Close angular#54457
JeanMeche pushed a commit to JeanMeche/angular that referenced this pull request Feb 20, 2024
…lar#54457)

Prior to this fix an incorrect view instance (a dynamically created component
one instead of the root view) was passed to the content query function. Having
incorrect view instance meant that a component instance could not be found.

This is a pre-existing bug, introduction of signal-based queries just surfaced it.

Fixes angular#54450

PR Close angular#54457
JeanMeche pushed a commit to JeanMeche/angular that referenced this pull request Feb 20, 2024
…lar#54457)

Prior to this fix an incorrect view instance (a dynamically created component
one instead of the root view) was passed to the content query function. Having
incorrect view instance meant that a component instance could not be found.

This is a pre-existing bug, introduction of signal-based queries just surfaced it.

Fixes angular#54450

PR Close angular#54457
vladboisa pushed a commit to vladboisa/angular that referenced this pull request Feb 20, 2024
…lar#54457)

Prior to this fix an incorrect view instance (a dynamically created component
one instead of the root view) was passed to the content query function. Having
incorrect view instance meant that a component instance could not be found.

This is a pre-existing bug, introduction of signal-based queries just surfaced it.

Fixes angular#54450

PR Close angular#54457
@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 Mar 17, 2024
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 target: patch This PR is targeted for the next patch release
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Queries as signals]: Signal Queries throws console errors when component is rendered as custom element
3 participants