Annoying experience with pygal

Recently,I have been learning pygal according to the book.And I installed the pygal as the book said,this is my code:

pip install --user pygal==1.7

But ,when I try to use it and ran this code:

hist.render_to_file('1.svg') 

It failed,and threw the exception:

I was annoyed and upset for days.
And I try to solved it by asking in many place,but nobody answered me.

Until today’s morning,when I go to stackoverflow ,I found someone answered my question.By his help,I have solved it successfully!Thanks to him~~~

This is the link:
https://stackoverflow.com/questions/45520049/pygal-valueerror-invalid-pi-name-bxml?noredirect=1#comment78034432_45520049

My problem is that the version of pygal is too low to work with python3.5.
So,I uninstall the old version:

pip uninstall pygal

And the install the newest version by this way:

pip install --user pygal==2.4 

Finally ,It works properly!!!

Annoying experience with pygal_第1张图片

(I am a Chinese,but there is a problem with the input method in ubuntu,so I use English.And my English is poor,If there’re some mistakes,please ignore it~)

你可能感兴趣的:(pygal)