google / gf180mcu-pdk

PDK for GlobalFoundries' 180nm MCU bulk process technology (GF180MCU).
https://gf180mcu-pdk.rtfd.io
Apache License 2.0
352 stars 54 forks source link

Fix PDF generation failure on blank SVG files. #84

Closed cbalint13 closed 1 year ago

cbalint13 commented 1 year ago

In continuation of #82 & #83 this fix broken PDF generation as of last log.

Cc @proppy

Thanks, ~Cristian.

proppy commented 1 year ago

Silently discards blank SVG conversions (there are many blanks).

@mithro do you know if that's expected? should we log those in a separate bug?

cbalint13 commented 1 year ago

Silently discards blank SVG conversions (there are many blanks).

@mithro do you know if that's expected? should we log those in a separate bug?

@proppy , @mithro

My investigation:


Here is such a blank SVG to have a look (using convert CLI tool):

convert /home/cbalint/work/GITHUB/gf180mcu/docs/digital/standard_cells/gf180mcu_fd_sc_mcu7t5v0/cells/endcap/gf180mcu_fd_sc_mcu7t5v0__endcap.schematic.svg test.png
convert: negative or zero image size `/home/cbalint/work/GITHUB/gf180mcu/docs/digital/standard_cells/gf180mcu_fd_sc_mcu7t5v0/cells/endcap/gf180mcu_fd_sc_mcu7t5v0__endcap.schematic.svg' @ error/image.c/SetImageExtent/2698.
convert: no decode delegate for this image format `/home/cbalint/work/GITHUB/gf180mcu/docs/digital/standard_cells/gf180mcu_fd_sc_mcu7t5v0/cells/endcap/gf180mcu_fd_sc_mcu7t5v0__endcap.schematic.svg' @ error/svg.c/RenderRSVGImage/534.
convert: no images defined `test.png' @ error/convert.c/ConvertImageCommand/3229.

But it pass and resulted test.png is fine (have legit size and etc) with the -quiet bypass.


mithro commented 1 year ago

We should create a GitHub issue to fix the SVGs with no drawings inside (either removing them or adding the proper contents).