cli icon indicating copy to clipboard operation
cli copied to clipboard

Base64 encoded SVGs cause error when capturing

Open ajoneil opened this issue 9 months ago • 2 comments

The problem

We have a base64 encoded SVG image on our page, and our tests work when Percy snapshots are not enabled. When enabling them, there is an HTTP request for the serialised image which fails:

     Failure/Error: raise ActionController::RoutingError, "No route matches [#{env['REQUEST_METHOD']}] #{env['PATH_INFO'].inspect}"
     
     ActionController::RoutingError:
       No route matches [GET] "/__serialized__/_51p3niala.svg+xml"

Environment

  • Node version: v18.19.0 LTS
  • @percy/cli version: 1.28.5
  • Version of Percy SDK you’re using: percy-capybara
  • OS version: Debian Bookworm based Docker image (official ruby docker image)
  • Type of shell command-line [interface]: bash

Details

This error only occurs when we upgrade our Percy CLI from 1.27.4 to the latest 1.28.5. Much like #1568, https://github.com/percy/cli/commit/0a48e87d5b5cfaf1d469728e3d6de34171edfe2a appears to be the culprit.

Unfortunately the fix for that issue (#1571) does not work as our Capybara drives Selenium in a different docker image, and so our host is not 127.0.0.1 or localhost but a 192.168. address.

ajoneil avatar Apr 30 '24 05:04 ajoneil

Hi @ajoneil ,

Thank you for bringing this to our attention. Rest assured, we are currently investigating this.

shantanuk-browserstack avatar May 07 '24 10:05 shantanuk-browserstack

This issue is stale because it has been open for more than 14 days with no activity. Remove stale label or comment or this will be closed in 14 days.

github-actions[bot] avatar May 21 '24 19:05 github-actions[bot]

This issue was closed because it has been stalled for 28 days with no activity.

github-actions[bot] avatar Jun 11 '24 19:06 github-actions[bot]

Same issue. I think this rewrite needs to be configurable.

Yama-Tomo avatar Aug 13 '24 09:08 Yama-Tomo

@shantanuk-browserstack any update?

Yama-Tomo avatar Sep 14 '24 03:09 Yama-Tomo