Closed lelecanfora closed 2 years ago
This is a version error with Python. Try installing python 3.8 on your environment with the command : conda install -c anaconda python=3.8
This can still cause problems, but it's scope has been limited. The development version of bw2data
explicitly uses pickle version 4, so this can only occur if you are using bw2data
stable (i.e. Brightway 2 instead of 2.5), and running an environment with Python < 3.8 and another environment with Python >= 3.8. Brightway version 2 uses the highest available pickle protocol, which would then be 4/5 respectively.
So, you can easily avoid this issue by using Python >= 3.8 only, or using Brightway 2.5 (development, but stable enough for production use).
I'm on Ubuntu Linux 21.04 and I've installed this version of Anaconda: Anaconda3-2021.05-Linux-x86_64.sh
This is the procedure I've used to install Conda and Brightway2:
conda create -n brightway2 python=3.6
source activate brightway2
conda install -y -q -c conda-forge -c cmutel -c haasad brightway2 jupyter
as described here: https://2.docs.brightway.dev/installation.html
Inside a notebook I try:
import brightway2 as bw
and this is the output: