InseeFrLab / pynsee

pynsee package contains tools to easily search and download french data from INSEE and IGN APIs
https://pynsee.readthedocs.io/en/latest/
MIT License
70 stars 10 forks source link

fastparquet : dependency seems to be missing #212

Open hadrilec opened 3 months ago

hadrilec commented 3 months ago

Hello, while running this piece of code:

from pynsee.sirene import search_sirene

# Get a list of hospitals in Paris
df = search_sirene(variable = ["activitePrincipaleUniteLegale",
                               "codePostalEtablissement"],
                   pattern = ["86.10Z", "75*"], kind = "siret")

I got this error:

Unable to find a usable engine; tried using: 'pyarrow', 'fastparquet'.
A suitable version of pyarrow or fastparquet is required for parquet support.
Trying to import the above resulted in these errors:
 - Pandas requires version '10.0.1' or newer of 'pyarrow' (version '8.0.0' currently installed).
 - Missing optional dependency 'fastparquet'. fastparquet is required for parquet support. Use pip or conda to install fastparquet.

After downloading, fastparquet the error disappeared. @tfardet shall we add this package in the dependencies?

tfardet commented 3 months ago

This is strange as the pyarrow dependency is in requirements.txt. My hypothesis would be that you might be using pynsee directly from path (since you need to be able to develop and test in real time) and you did not update the requirements since I added parquet?

There is no need to have fastparquet and pyarrow, so since pyarrow is already listed as a dependency, we should be fine.

tfardet commented 2 months ago

@hadrilec can we close this or do you still think there is an issue?