Closed riojung closed 5 years ago
I wonder that there is way to skip to scrap partner ads? or scraping with partner ads without any issue?
Hm, interesting. That URL looks like 2 concatenated together. I have never seen this error before with this. I'll take a look when I have some free time later this week. Thanks for the detailed description!
ok, thanks @mwpenny
The malformed URL is because the scraper expects URLs on the search results page to be relative to https://www.kijiji.ca (third party ads are not of course). The larger problem is that even if external ad HTML was fetched correctly, the markup would be different than a Kijiji ad and the scraper would fail at that step.
Since third party ad markup is unpredictable, they will not be supported by kijiji-scraper. These ads will be excluded from results returned by search()
.
Please pull the master branch and try again.
Additionally, while looking into this I found that ad titles and post dates were not scraped properly when search()
was used with scrapeResultDetails: false
(Kijiji changed the markup of the search results page slightly). I have fixed that as well.
Awesome! thanks @mwpenny. I will pull the latest code from master and re-test it again.
@riojung Has the issue been resolved for you? I'd like to close this.
@mwpenny yes, this issue is fixed with your commit 3f71a9ab3f9b0b08eef417d932e0632c48e983bd I think you could close this one. thanks for the fix.
I have published the fixed version to NPM.
Hello,
I am having issue of scrapping kijiji job ads with kijiji-scraper. it works well with other type of ads but if there are partner's ads between kijiji ads, it throws exception.
Here is code that I tried:
And here is error for above code: