Closed geoffharcourt closed 3 years ago
It looks like the widths are not being passed to @percy/core
. When I ran with debugging:
Options: {:name=>"Mobile: Student Views Direct Instruction Lesson", :widths=>[411]}
--
| [percy:core] --------- (30174ms)
| [percy:core] Handling snapshot: (1ms)
| [percy:core] -> name: Mobile: Student Views Direct Instruction Lesson (0ms)
| [percy:core] -> url: http://127.0.0.1:35035/students/student_lessons/1 (0ms)
| [percy:core] -> widths: 1370px (0ms)
| [percy:core] -> minHeight: 1024px (0ms)
| [percy:core] -> enableJavaScript: false (0ms)
| [percy:core] -> discovery: {} (0ms)
| [percy:core] -> clientInfo: percy-capybara/5.0.0.pre.4 (0ms)
| [percy:core] -> environmentInfo: capybara/3.35.3 ruby/2.7.3 (0ms)
| [percy:core] -> domSnapshot:
🤦🏼♂️ Oh boy, thanks for raising this issue! When rewriting the SDK I totally forgot to actually pass the options to the running Percy server. #170 fixes it! Sorry about that
Thanks for the update!
@Robdel12 we tested with this and were able to successfully migrate. Thanks for resolving this issue!
Excellent news! Super happy to hear that 😃
Hello Percy team,
We tried to upgrade to 5.0.0.pre.4 today, but all of our mobile-only snapshots were rendering with our default width. Here's our config file (I removed the Percy CSS since it's noisy and shouldn't be relevant):
We added a logging statement to check our options before we took the snapshot (so one line above the snapshot call itself) in our CI process:
All 20 of our mobile snapshots were taken at 1370px width instead of 411px despite this call (we have a helper method that sets up mobile options, so it's the same call everywhere). Can you help us figure out what's happening?