Closed gutonon closed 3 months ago
Hi @gutonon, I ran into the same problem today and fixed it by editing one of the python script files in the gbif ocurrences plugin, using the correction supplied by @hypsug0 above. The problem occurs in line 150 of the file qgis_occurrences_dialog.py. The function setValue takes an integer value input, and the percentage input provided in line 149 is a float value. The solution is to convert the percentage variable from float to integer as indicated by hypsug0. You need to edit line 150 to read: self.progressBar.setValue(int(percent)) In other words, convert the percent float variable to integer so the function self.progressBar.setValue has the required integer input. If you want to fix this yourself on your windows computer you will need to
I expect the plugin maintainers will fix this soon so these manual steps should not be necessary in the future
As an aside, one of my students using an earlier version of qgis had no problem running the current plugin, so this problem may have appeared due to changes in python or in qgis.
Roberto
Thanks a lot @rbcer17 and @gutonon for the very clear description and fix. I indeed plan to fix that soon and publish a new release so not everybody needs to fix that on its machine. Thanks for your patience !
Hi @niconoe , thanks for the prompt response and nice words! I see @hypsug0 submitted earlier a pull request with the proposed fix.
Best, Roberto
Hello, I have also a python error, probably the same.
Since I used this plugin in my bioinformatics class, I am wondering whether anybody knows the latest QGIS version able to use this plugin. I do have still an older 3.10 QGIS version, and this works Or would it be possible to fix is asap, which would allow my students to use the latest QGIS version?
Best regards
2024-07-14T18:46:16 WARNING Traceback (most recent call last): File "C:\Users/bt140047/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\qgisgbifapi\qgis_occurrences_dialog.py", line 201, in load_occurrences self.show_progress(already_loaded_records, count) File "C:\Users/bt140047/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\qgisgbifapi\qgis_occurrences_dialog.py", line 150, in show_progress self.progressBar.setValue(percent) TypeError: setValue(self, value: int): argument 1 has unexpected type 'float'
Great, Thanks for your fast action! Is there a chance to get this part of the code fixed in the python file by using github commit? Best,
Thanks all, I've just released a new version (0.3.4) that should fix the issue!
Can you try updating the plugin and tell me all works well!
Sorry again for the long wait!
Great, it works! Thank you for this plugin and taking care about it! Best,
Hello,
I am having the following problem when running GBIF occurences. I don't know how to solve it.
Thanks.
Gustavo