NRCan / CanFlood

Flood Risk modelling toolbox for Canada
MIT License
29 stars 7 forks source link

Inventory Compiler Crash - Pandas and Qvariant Object Issue #10

Closed blairscriven closed 3 years ago

blairscriven commented 3 years ago

QGIS ver 3.16.10 CanFlood ver 1.0.2 Python ver 3.9.5 Pandas ver 1.3.0 PyQt5 ver 5.15.4 Numpy ver 1.20.2 xlrd ver 1.2.0 xlsxwriter ver 1.2.6 scipy ver 1.6.2 openpyxl ver 3.0.6

I was following along with the first tutorial in the CanFlood user manual, using the tut1 data and when i got to the Inventory Compiler in the CanFlood Build Toolset (pg. 68), I hit the "Store" button and I got the following Python Error:

CanFlood_issue

It seems like there is an issue with the to_replace parameter in Pandas, where it cannot except a Qvariant object in more recent versions of Pandas. Initially, I was using Pandas 1.3.0 (the latest version) and I so I tried to reinstall two older versions (1.2.3 and 1.1.3) but I got the same issue.

cefect commented 3 years ago

It looks like you're running some custom QGIS install.

Check your PyQT5 and pandas version against the requirements

I suggest trying the standalone QGIS 3.16.6 installer and seeing if that resolves your issue

blairscriven commented 3 years ago

Hey so I installed QGIS 3.16.6 and it worked! Not only did the inventory compiler work, but I was able to finish the first tutorial and run through tutorials 2a,b and c successfully. Thanks a lot!