serp-spider / search-engine-google

:spider: Google client for SERPS
https://serp-spider.github.io
Other
168 stars 61 forks source link

Recent map upgrade issue ? #94

Closed mike-kostov closed 6 years ago

mike-kostov commented 6 years ago

URL that fails to parse

https://google.bg/search?q=%D0%BD%D0%B5%D0%B4%D0%B2%D0%B8%D0%B6%D0%B8%D0%BC%D0%B8+%D0%B8%D0%BC%D0%BE%D1%82%D0%B8+%D0%BF%D0%BE%D0%B4+%D0%BD%D0%B0%D0%B5%D0%BC&num=50

My Composer packages version

guzzlehttp/psr7 1.4.2 PSR-7 message implementation that also provides common utility methods psr/http-message 1.0.1 Common interface for HTTP messages serps/core v0.2.6 Search engine scrapper serps/http-client-curl v0.2.2 CURL client for SERPS serps/search-engine-google v0.2.4 Google Rules and client for SERPS symfony/css-selector v3.4.6 Symfony CssSelector Component

I am parsing the natural results with ->getRealPosition() Errors I get.

Notice: Undefined property: Serps\Core\Dom\NullDomNode::$parentNode in serp/vendor/serps/search-engine-google/src/Parser/Evaluated/Rule/Natural/Map.php on line 98 and also

Fatal error: Call to a member function getNodeValue() on null in serp/vendor/serps/search-engine-google/src/Parser/Evaluated/Rule/Natural/Map.php on line 98

gsouf commented 6 years ago

Hi @mike-kostov Yes there was as you can see in the latest changelog.

The new map section section became a bit more complex than before. I'm investigating.

gsouf commented 6 years ago

That should be fixed with version 0.2.5