Open clacladev opened 9 years ago
The "WebKit Threading Violation" seems weird. Does that happen when you run your app outside of instruments every once in a while?
Unfortunately, Instruments and UI Automation is still not very stable. File a bug with Apple at http://bugreport.apple.com and include these log files and let them know you're using this script. Every bug report helps prioritize things.
Yes, it happens when I run it from terminal.
I've noted that it happens when is switching from a simulated device to another. If I am running just on one device it's unlikely it happens.
I meant, does it happen if you run it while just using the app normally (run from Springboard, not just from the terminal)? Regardless, this sounds like an issue within Apple's profiling toolchain. Instruments sometimes just loses connection with the frontmost app, too. The Instruments team is still working out kinks to make it robust. There's nothing that these screen shot scripts can do from the outside. We have to wait for the toolchain.
Please file a bug about this and update the thread with any details if you can. Thanks!
It happens only when running the script. So when the script switch from a device type to another, probably as you said lose connection and the error is thrown.
Anyway, thanks for your answer and support. I will fill the bug report with Apple.
Have great work and thanks again for the script. Cheers
I'm having the exact same problem. Only way to 'solve' it, is to wait for a few seconds and try to run it again. I'm currently working on a fix for that issue. I think it has nothing to do with Webkit itself, that's just a warning from a different problem.
@ccarnino Sorry to just advertise another open source project, but Snapshot solves exactly this problem.
Take a look at the gif: Instruments failed again... trying again
. That's when Snapshot
detects this error and tries again.
In case you want to implement this fix in ui-screen-shooter
check out runner.rb:87
It's enough to re-run this one test after a few seconds delay.
Thanks Felix for the advice. I will try this for sure to see if the overall process works better.
Cheers
-- Claudio Carnino Co-founder of Fanchimp.com About me on TuguLab.org
"We want the world and we want it now" The Doors
On 15 November 2014 at 12:27:29, Felix Krause (notifications@github.com) wrote:
In case you want to implement this fix in ui-screen-shootercheck out runner.rb:87
It's enough to re-run this one test after a few seconds delay.
— Reply to this email directly or view it on GitHub.
I added this crude code myself. Seems to work... not fully tested yet though.
until "$DIR"/unix_instruments.sh
-w "$simulator" \
-D "$trace_results_dir/trace" \
-t "$tracetemplate" \
$bundle_dir \
-e UIARESULTSPATH "$trace_results_dir" \
-e UIASCRIPT "$automation_script" \
-AppleLanguages "($language)" \
-AppleLocale "$language" \
$* ; do
echo Instruments failed to start up... retrying in 2 seconds
sleep 2
done `
Thanks to this post: http://serverfault.com/questions/80862/bash-script-repeat-command-if-it-returns-an-error
Hi Jonathan, thanks for this great script. I really appreciate your work.
I have only one problem. Half of the time when running the script I get the error:
After few tries, I've understood that resetting the simulator and re-running the script it works fine.
Then problem is that it's unpredictable, so I have to reset the simulator a lot of times. Do you have any idea why this is happening?
I have Xcode 6.1 with an app that run exclusively on iOS 8.1.
Thanks