skrapeit / skrape.it

A Kotlin-based testing/scraping/parsing library providing the ability to analyze and extract data from HTML (server & client-side rendered). It places particular emphasis on ease of use and a high level of readability by providing an intuitive DSL. It aims to be a testing lib, but can also be used to scrape websites in a convenient fashion.
https://docs.skrape.it
MIT License
805 stars 59 forks source link

[BUG] Android support not working #166

Closed christian-draeger closed 2 years ago

christian-draeger commented 2 years ago

Describe the bug Current Fetcher implementation is based on ktor clients apache http client which makes trouble on Android.

Expected behavior Library should work on Android as it do on server.

Additional context Switching fetcher implementation to use ktor client over okhttp should lead to first class android support but still supporting server side

Eric provided a hint on the kotlin slack that he could prove swapping the fetcher impl to okhttp will make the android issues go away Screenshot_20211002-210408.jpg

We need to swap implementations of http fetcher and async fetcher to use okhttp

eric-labelle commented 2 years ago

I was really busy the last few weeks. I'll try to open a draft PR for your review as soon as I get back to it.

christian-draeger commented 2 years ago

Big thanks in advance @eric-labelle

dshetyo commented 2 years ago

Any updates on this?Is this lib working fine on andoid?

christian-draeger commented 2 years ago

HttpFetcher should work (as shown in the project examples), BrowserFetcher will hopefully be fixed for Android due to #180 within the next few days