You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When using wicked_pdf_stylesheet_link_tag, if the assets are precompiled or otherwise referenced via URL, WickedPDF tries to fetch the asset from remote URL using read_from_uri method in WickedPdf::WickedPdfHelper::Assets. This method calls Net::HTTP.get(URI(uri)) which does not fail if the status code is different than 200, resulting in a broken PDF if either the server responding to the request (for ex. 502 error) or the asset (404) is unavailable without ever informing the user.
Expected or desired behavior
If the remote asset is not available, WickedPDF should throw an exception. This could be configurable to avoid breaking change.
System specifications
wicked_pdf gem version: 2.6.3
The text was updated successfully, but these errors were encountered:
Issue description
When using
wicked_pdf_stylesheet_link_tag
, if the assets are precompiled or otherwise referenced via URL, WickedPDF tries to fetch the asset from remote URL usingread_from_uri
method inWickedPdf::WickedPdfHelper::Assets
. This method callsNet::HTTP.get(URI(uri))
which does not fail if the status code is different than 200, resulting in a broken PDF if either the server responding to the request (for ex. 502 error) or the asset (404) is unavailable without ever informing the user.Expected or desired behavior
If the remote asset is not available, WickedPDF should throw an exception. This could be configurable to avoid breaking change.
System specifications
wicked_pdf gem version: 2.6.3
The text was updated successfully, but these errors were encountered: