Movatterモバイル変換


[0]ホーム

URL:


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

Sign up
Appearance settings

Forbid serializing a Crawler#15906

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
fabpot merged 1 commit intosymfony:2.3fromstof:forbid_serializing_crawler
Sep 27, 2015

Conversation

@stof
Copy link
Member

QA
Bug fix?yes
New feature?no
BC breaks?no
Deprecations?no
Tests pass?yes
Fixed ticketsn/a
LicenseMIT
Doc PRn/a

Unserializing a Crawler instance creates DOM elements in an invalid state, making the Crawler unusable.
While working on#15849, I figured out that DomCrawler actually inheritsSerializable from itsSplObjectStorage parent, and so I tried to serialize and unserialize one. The answer is that it does not work. This is what happens when trying to callparents on it for instance:

Symfony\Component\DomCrawler\Crawler::parents(): Invalid State Error

Unserializing a Crawler instance creates DOM elements in an invalidstate, making the Crawler unusable.
@Tobion
Copy link
Contributor

👍

Status: Reviewed

@fabpot
Copy link
Member

Thank you@stof.

@fabpotfabpot merged commit12733cb intosymfony:2.3Sep 27, 2015
fabpot added a commit that referenced this pull requestSep 27, 2015
This PR was merged into the 2.3 branch.Discussion----------Forbid serializing a Crawler| Q             | A| ------------- | ---| Bug fix?      | yes| New feature?  | no| BC breaks?    | no| Deprecations? | no| Tests pass?   | yes| Fixed tickets | n/a| License       | MIT| Doc PR        | n/aUnserializing a Crawler instance creates DOM elements in an invalid state, making the Crawler unusable.While working on#15849, I figured out that DomCrawler actually inherits ``Serializable`` from its ``SplObjectStorage`` parent, and so I tried to serialize and unserialize one. The answer is that it does not work. This is what happens when trying to call ``parents`` on it for instance:```Symfony\Component\DomCrawler\Crawler::parents(): Invalid State Error```Commits-------12733cb Forbid serializing a Crawler
@stofstof deleted the forbid_serializing_crawler branchSeptember 27, 2015 13:13
This was referencedOct 27, 2015
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment

Reviewers

No reviews

Assignees

No one assigned

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

4 participants

@stof@Tobion@fabpot@carsonbot

[8]ページ先頭

©2009-2025 Movatter.jp