[FIXED] Losing Server Connection

I’m starting to see this error :
Exception: Connection to server failed at [A_Main.Main, line 75]

from this code :

def timer_keepalive_tick(self, **event_args):
    lbl_pingstamp.text = anvil.server.call('keepalive_ping')

which calls this server function :

@anvil.server.callable
def keepalive_ping():
  return str(datetime.now())

I didn’t have the presence of mind to check the JS console before restarting, but I have a post-it note to remind me now.

The last couple of times it has failed, the session had been alive (and idle save for the pings) for many hours and I had just successfully run a non-trivial server function call that takes 20 odd seconds. It died about 5 minutes after that whilst sitting idle.

I suspect bigger issue are afoot.

15 mins back, my logged in via google anvil app logged me out, which its never done before.
and now wont let me log back in.
published app fails google auth, but dev console version works ok.

anyone else confirm?

We did reset a piece of infrastructure this morning, which is probably what reset your session and might have caused momentary connection failure.

Google authentication not working would be a much more serious problem. All our tests are working - can you send me a link to an application that’s failing?

(If the published version of your app is failing, and the dev version is working, what happens if you temporarily revert your dev version to the published version in the Version History dialog? [don’t worry, you can always move it back!] Does it work then?)

1 Like

I’ve had confirmation from a work colleague that he’s seeing the same behaviour too.

On the question of versions, I hadn’t made any development changes. I was simply using the published app, when it logged me out with a timeout message.

Can you send me a link to an application that’s failing? (Privately is OK.)

Update: This is now fixed. Apologies for the issue there!

Yay. Seems to be back again :slight_smile: