Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

[DomCrawler] fix HTML5 parser integration #31257

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

Merged
merged 1 commit into from
May 9, 2019

Conversation

nicolas-grekas
Copy link
Member

Q A
Branch? master
Bug fix? yes
New feature? no
BC breaks? no
Deprecations? no
Tests pass? yes
Fixed tickets -
License MIT
Doc PR -

Spotted while reviewing #30892
The current logic is context-dependent: by changing the order of calls, you can get different behaviors.

@stof
Copy link
Member

stof commented Apr 26, 2019

I don't understand which issue you are trying to solve here.

We cannot add content multiple time (as all nodes have to belong to the same document), and calling ->html() before adding content does not make sense and will not reach this code anyway.

src/Symfony/Component/DomCrawler/Crawler.php Show resolved Hide resolved
@nicolas-grekas nicolas-grekas modified the milestones: next, 4.3 Apr 30, 2019
@nicolas-grekas
Copy link
Member Author

nicolas-grekas commented May 5, 2019

I don't understand which issue you are trying to solve here.

The code makes little sense either: one should not have to know how the overall class works to understand local details. I'm making the code have a better locality so one can reason about it in a simpler way.

@nicolas-grekas nicolas-grekas changed the base branch from master to 4.3 May 9, 2019 14:02
@nicolas-grekas nicolas-grekas merged commit ba83bda into symfony:4.3 May 9, 2019
nicolas-grekas added a commit that referenced this pull request May 9, 2019
This PR was merged into the 4.3 branch.

Discussion
----------

[DomCrawler] fix HTML5 parser integration

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | -
| License       | MIT
| Doc PR        | -

Spotted while reviewing #30892
The current logic is context-dependent: by changing the order of calls, you can get different behaviors.

Commits
-------

ba83bda [DomCrawler] fix HTML5 parser integration
@nicolas-grekas nicolas-grekas deleted the dow-html5 branch May 21, 2019 08:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants
Morty Proxy This is a proxified and sanitized view of the page, visit original site.