mendhak / waveshare-epaper-display

At-a-glance dashboard for Raspberry Pi with a Waveshare ePaper 7.5 Inch HAT. Date/Time, Weather, Alerts, Google/Outlook Calendar
https://code.mendhak.com/raspberrypi-epaper-dashboard/
449 stars 66 forks source link

cairosvg: error: no such option: --output-width #30

Closed DominicBoisvert closed 2 years ago

DominicBoisvert commented 2 years ago

Hi,

With cairoSVG (pyhton3-cairosvg package), I got the following error message: cairosvg: error: no such option: --output-width

I changed "--output-width" to "-W" and "--output-height" to "-H" (line 26 of the run.sh file).

The error message is gone, and the display is good.

mendhak commented 2 years ago

Thanks for reporting that, did you install cairosvg using apt or pip? What version appears when you run cairosvg --version ?

Mine is 2.5.0 installed via apt

I wonder if the arguments are for newer (or older) versions of cairosvg maybe.

mendhak commented 2 years ago

Strangely for me when I use -W and -H the image that's generated is the wrong dimensions and doesn't display on the epaper screen (it errors with 'wrong dimensions').

I had to use --output-width and --output-height to get it working.

DominicBoisvert commented 2 years ago

Thanks for the quick return.

The package was python3-cairosvg, installed via apt (Raspbian Buster). The version was 1.0.20.

I removed the package (via apt) and installed it with pip3. Now it shows version 2.5.2, and it's working with either combination of --output-width and --output-height or -W and -H.

DominicBoisvert commented 2 years ago

Installing cairosvg (version 2.5.2) with pip3 solved the issue.