ssloop | ssloop is a super simple event loop | Pub Sub library
kandi X-RAY | ssloop Summary
kandi X-RAY | ssloop Summary
ssloop is a super simple event loop
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
- Start the queue
- Call a handler
- Wait for the given timeout
- Return time in seconds
- Remove a handler
- Get the mode of a given fd
- Update a file descriptor
- Add a file descriptor
- Add a timeout
- Modify a fd
- Control control events
- Remove a file descriptor
- Update the mode of a handler
- Modify a file descriptor
ssloop Key Features
ssloop Examples and Code Snippets
Community Discussions
Trending Discussions on ssloop
QUESTION
I'm struggling to troubleshoot a strange problem I've been having since starting to use Sikuli over multiple projects. I've been using the IDE and later tried to branch out due to having strange things happening with code. If I were to debug code earlier with popups, I can save the code, even restart my pc, even check the code in other text editors but the now non-existent popups (and old code) sometimes, well, pop up. In the end normally I end up ditching original files, and having to sometimes strangely comment out lines and re-add them one at a time (even though in the grand scale of things the end script was the same as before i did all that). I'm at a real loss for words.
It's making me struggle to differentiate between bad code and something going wrong elsewhere. Does anyone know what might cause this "phantom code"? Because I'm really at a loss.
And i would like advice as to what's going wrong with the while i < (inputvariable). I can't figure out what might be going wrong at all, am i over looking something?
I'm running all scripts through Sikuli IDE at the moment. I did want to learn how to write scripts and include sikuli hoping i could package it neatly but i couldn't seem to wrap my head around it.
For the while loop, where it's being compared to "SSLoops" i can't see why it's not breaking out of the loop when the criteria is met. (prints out above and beyond the number.)
I've had to do strange workarounds such as commenting out whole sections of code, trying to get it to work, and then slowly one by one reintroduce it till it matched the old script entirely. If I copied the script to a new file to make a cleaner copy, in hopes that if there is some sort of caching issue(?) it'd resolve, but I'd normally have to tinker around with it again.
...ANSWER
Answered 2019-Apr-02 at 15:55Your problem: input()
returns a string like so "4"
you then compare it using
while i < SSLoops:
which is always True
and hence the loop does not end.
using
SSLoops = int(input("How many times would you like to run Super Smash?"))
will solve your problem.
Be aware: this will crash if the given input cannot be converted to an integer value.
Suggestion: debug prints should look like so: print "SSLoops =", SSLoops
so the output is better readable.
RaiMan from SikuliX (greetings to your cat ;-)
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install ssloop
You can use ssloop like any standard Python library. You will need to make sure that you have a development environment consisting of a Python distribution including header files, a compiler, pip, and git installed. Make sure that your pip, setuptools, and wheel are up to date. When using pip it is generally recommended to install packages in a virtual environment to avoid changes to the system.
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page