Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

AttributeError: module 'pyarrow.lib' has no attribute 'ListViewType'

Tags:

pyarrow

------------------------------------------------------------
AttributeError                            Traceback (most recent call last)
Cell In[67], line 2
      1 import pandas as pd
----> 2 import pyarrow.parquet as pq
      3 import pyarrow.lib as _lib
      4 import pyarrow as pa

File /opt/anaconda3/lib/python3.11/site-packages/pyarrow/parquet/__init__.py:20
      1 # Licensed to the Apache Software Foundation (ASF) under one
      2 # or more contributor license agreements.  See the NOTICE file
      3 # distributed with this work for additional information
   (...)
     17 
     18 # flake8: noqa
---> 20 from .core import *

File /opt/anaconda3/lib/python3.11/site-packages/pyarrow/parquet/core.py:33
     30 import pyarrow as pa
     32 try:
---> 33     import pyarrow._parquet as _parquet
     34 except ImportError as exc:
     35     raise ImportError(
     36         "The pyarrow installation is not built with support "
     37         f"for the Parquet file format ({str(exc)})"
     38     ) from None

File /opt/anaconda3/lib/python3.11/site-packages/pyarrow/_parquet.pyx:1, in init pyarrow._parquet()

AttributeError: module 'pyarrow.lib' has no attribute 'ListViewType'

I have tried to install or unistall pyarrow and upgrade pyarrow

like image 809
Percival Shimange Avatar asked Aug 07 '26 05:08

Percival Shimange


1 Answers

I have same issue, downgrade pyarrow==15.0.2 fixed it for me, I guess this will work as a stopgap until the datasets lib are fixed.

pip install pyarrow==15.0.2

ref: https://github.com/huggingface/datasets/issues/6985

like image 197
WangSung Avatar answered Aug 10 '26 16:08

WangSung



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!