
Security News
Browserslist-rs Gets Major Refactor, Cutting Binary Size by Over 1MB
Browserslist-rs now uses static data to reduce binary size by over 1MB, improving memory use and performance for Rust-based frontend tools.
Waits for a certain amount of time for an action to complete Designed to wait for a certain length of time, either linearly in 1 second steps, or exponentially, up to a maximum. Returns the output from the function once it completes successfully, along with the time taken to complete the command.
.. note:: If using the expo keyword, the returned elapsed time will be inaccurate as wait_for does not know the exact time that the function returned correctly, only that it returned correctly at last check.
.. code-block:: python
from wait_for import wait_for
class Incrementor(): value = 0
def i_sleep_a_lot(self):
time.sleep(.1)
self.value += 1
return self.value
incman = Incrementor() ec, tc = wait_for(incman.i_sleep_a_lot, fail_condition=0, delay=.05) print("Function output {} in time {} ".format(ec, tc))
FAQs
A waiting based utility with decorator and logger support
We found that wait-for demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 4 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Browserslist-rs now uses static data to reduce binary size by over 1MB, improving memory use and performance for Rust-based frontend tools.
Research
Security News
Eight new malicious Firefox extensions impersonate games, steal OAuth tokens, hijack sessions, and exploit browser permissions to spy on users.
Security News
The official Go SDK for the Model Context Protocol is in development, with a stable, production-ready release expected by August 2025.