question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Update `check_connection` method

See original GitHub issue

In two python example provided in the repository we can observe a similar pattern for the connection checking:

    startup_sec = 1
    while not viz.check_connection() and startup_sec > 0:
        time.sleep(0.1)
        startup_sec -= 0.1
    assert viz.check_connection(), 'No connection could be formed quickly'

I wonder whether this could not be integrated directly to check_connection method without asking the user to write such loop.

What do you think ?

Thanks

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:8 (8 by maintainers)

github_iconTop GitHub Comments

1reaction
vfdev-5commented, Aug 30, 2018

@JackUrb tested the master and have no more problems with runing the demo.py as reported in the previous comment.

I looked the PR, looks good to me 😃

0reactions
JackUrbcommented, Aug 31, 2018

Implemented in #460

Read more comments on GitHub >

github_iconTop Results From Across the Web

SqlServerType.IConnectionValidator.CheckConnection Method
In this article ... Checks if successfully opened connection should be returned to the calling application Throws NotSupportedException exception ...
Read more >
Error: Activating connection failed, check connection settings ...
1. [core-ssh ~]$ ha network update wlan0 --ipv4-method static --ipv4-address 192.168.0.89/24 Error: Activating connection ...
Read more >
Roku Won't Connect to Internet (SOLVED) - YouTube
Here are some simple methods to fix your internet or WiFi if it isn't connecting to your Roku stick. If you are still...
Read more >
How to Fix "Check Your Connection and Try Again" in Google ...
If you keep seeing "Check your connection and try again" in the Play Store, Google Assistant, or other apps, try the following methods...
Read more >
Reading network state | Android Developers
However, the synchronous ConnectivityManager methods do not tell your app about anything happening after a call, so they don't enable you to update...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found