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.

aw-watcher-afk/aw-watcher-window can not connect to the aw-server

See original GitHub issue
  • I am on the latest ActivityWatch version.
  • I have searched the issues of this repo and believe that this is not a duplicate.
  • OS version and name: Windows 10 Home Edition, version 10.0.18363.900
  • ActivityWatch version: 0.9.2

Describe the bug

aw-watcher-afk and aw-watcher-window can not connect to the aw-server. The aw-server is running and the browser extension can connect to it. Also, there can not query the activity summary of period after this problem happened, but the Timeline view can still show current event log.

To Reproduce

Maybe shutdown the computer casually can cause this problem.

Expected behavior

aw-watcher-* work regularly and the Activity view of the Dashboard can query current summary.

Documentation

The Activity view: 图片 The Timeline view: 图片

Below is the recent aw-server’s logs:

2020-06-17 12:58:22 [INFO ]: Using storage method: peewee  (aw_server.main:26)
2020-06-17 12:58:22 [INFO ]: Starting up...  (aw_server.main:31)
2020-06-17 12:58:22 [INFO ]: Using database file: C:\Users\user\AppData\Local\activitywatch\activitywatch\aw-server\peewee-sqlite.v2.db  (aw_datastore.storages.peewee:90)
2020-06-17 12:58:22 [INFO ]:  * Running on http://localhost:5600/ (Press CTRL+C to quit)  (werkzeug:122)
2020-06-17 12:58:22 [INFO ]: Received heartbeat after pulse window, inserting as new event. (bucket: aw-watcher-web-firefox)  (aw_server.api:228)
2020-06-17 12:58:25 [INFO ]: Received heartbeat after pulse window, inserting as new event. (bucket: aw-watcher-web-firefox)  (aw_server.api:228)
2020-06-17 14:25:23 [WARNING]: Gap was of negative duration but could be safely merged (-50.146s). This message will only show once per batch.  (aw_transform.flood:46)
2020-06-17 14:25:23 [WARNING]: Gap was of negative duration but could be safely merged (-5259.732s). This message will only show once per batch.  (aw_transform.flood:46)
2020-06-17 14:25:23 [WARNING]: Gap was of negative duration and could NOT be safely merged (-5259.732s). This warning will only show once per batch.  (aw_transform.flood:50)
2020-06-17 14:25:23 [WARNING]: Gap was of negative duration but could be safely merged (-561.55s). This message will only show once per batch.  (aw_transform.flood:46)
2020-06-17 14:25:23 [WARNING]: Gap was of negative duration but could be safely merged (-539.827s). This message will only show once per batch.  (aw_transform.flood:46)
2020-06-17 14:25:23 [WARNING]: Gap was of negative duration but could be safely merged (-715.669s). This message will only show once per batch.  (aw_transform.flood:46)
2020-06-17 14:25:23 [WARNING]: Gap was of negative duration but could be safely merged (-1827.031s). This message will only show once per batch.  (aw_transform.flood:46)
2020-06-17 14:25:23 [WARNING]: Gap was of negative duration but could be safely merged (-1715.477s). This message will only show once per batch.  (aw_transform.flood:46)
2020-06-17 14:25:24 [WARNING]: Gap was of negative duration but could be safely merged (-0.01s). This message will only show once per batch.  (aw_transform.flood:46)
2020-06-17 14:25:24 [WARNING]: Gap was of negative duration but could be safely merged (-1639.936s). This message will only show once per batch.  (aw_transform.flood:46)
2020-06-17 14:25:24 [WARNING]: Gap was of negative duration and could NOT be safely merged (-1.397s). This warning will only show once per batch.  (aw_transform.flood:50)

and aw-qt’s logs:

2020-06-17 12:58:21 [INFO ]: Starting module aw-server  (aw_qt.manager:49)
2020-06-17 12:58:21 [INFO ]: Starting module aw-watcher-window  (aw_qt.manager:49)
2020-06-17 12:58:21 [INFO ]: Starting module aw-watcher-afk  (aw_qt.manager:49)
2020-06-17 12:58:21 [INFO ]: Creating trayicon...  (aw_qt.trayicon:140)

and aw-watcher-afk’s logs:

2020-06-17 12:58:21 [INFO ]: aw-watcher-afk started  (aw_watcher_afk.afk:53)
2020-06-17 12:58:22 [WARNING]: Not connected to server, 13906 requests in queue  (aw_client.client:380)
2020-06-17 12:58:32 [WARNING]: Not connected to server, 13906 requests in queue  (aw_client.client:380)
2020-06-17 12:58:42 [WARNING]: Not connected to server, 13907 requests in queue  (aw_client.client:380)
2020-06-17 12:58:53 [WARNING]: Not connected to server, 13908 requests in queue  (aw_client.client:380)
2020-06-17 12:59:03 [WARNING]: Not connected to server, 13909 requests in queue  (aw_client.client:380)
2020-06-17 12:59:13 [WARNING]: Not connected to server, 13909 requests in queue  (aw_client.client:380)
2020-06-17 12:59:23 [WARNING]: Not connected to server, 13910 requests in queue  (aw_client.client:380)
2020-06-17 12:59:33 [WARNING]: Not connected to server, 13911 requests in queue  (aw_client.client:380)
2020-06-17 12:59:43 [WARNING]: Not connected to server, 13912 requests in queue  (aw_client.client:380)

and aw-watcher-window’s logs:

2020-06-17 12:58:21 [INFO ]: aw-watcher-window started  (aw_watcher_window.main:40)
2020-06-17 12:58:22 [WARNING]: Not connected to server, 11839 requests in queue  (aw_client.client:380)
2020-06-17 12:58:32 [WARNING]: Not connected to server, 11841 requests in queue  (aw_client.client:380)
2020-06-17 12:58:42 [WARNING]: Not connected to server, 11845 requests in queue  (aw_client.client:380)
2020-06-17 12:58:53 [WARNING]: Not connected to server, 11848 requests in queue  (aw_client.client:380)
2020-06-17 12:59:03 [WARNING]: Not connected to server, 11850 requests in queue  (aw_client.client:380)
2020-06-17 12:59:13 [WARNING]: Not connected to server, 11853 requests in queue  (aw_client.client:380)
2020-06-17 12:59:23 [WARNING]: Not connected to server, 11856 requests in queue  (aw_client.client:380)
2020-06-17 12:59:33 [WARNING]: Not connected to server, 11860 requests in queue  (aw_client.client:380)
2020-06-17 12:59:43 [WARNING]: Not connected to server, 11862 requests in queue  (aw_client.client:380)
2020-06-17 12:59:53 [WARNING]: Not connected to server, 11865 requests in queue  (aw_client.client:380)
2020-06-17 12:59:58 [ERROR]: Exception thrown while trying to get active window: (-2147217385, 'OLE error 0x80041017', None, None)  (aw_watcher_window.main:66)
2020-06-17 12:59:59 [ERROR]: Exception thrown while trying to get active window: (-2147217385, 'OLE error 0x80041017', None, None)  (aw_watcher_window.main:66)
2020-06-17 13:00:00 [ERROR]: Exception thrown while trying to get active window: (-2147217385, 'OLE error 0x80041017', None, None)  (aw_watcher_window.main:66)
2020-06-17 13:00:01 [ERROR]: Exception thrown while trying to get active window: (-2147217385, 'OLE error 0x80041017', None, None)  (aw_watcher_window.main:66)
2020-06-17 13:00:03 [WARNING]: Not connected to server, 11868 requests in queue  (aw_client.client:380)
2020-06-17 13:00:13 [WARNING]: Not connected to server, 11869 requests in queue  (aw_client.client:380)
2020-06-17 13:00:23 [WARNING]: Not connected to server, 11869 requests in queue  (aw_client.client:380)

Additional context

I checked the sqlite database, the event is still in recording and I think it is still heathy.

Issue Analytics

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

github_iconTop GitHub Comments

1reaction
ErikBjarecommented, Jun 25, 2020

You might also be able to fix it by setting the variable NO_PROXY like this: SET NO_PROXY=localhost,127.0.0.1

You could also set it globally, if you want.

0reactions
johan-bjareholtcommented, Jun 25, 2020

@ErikBjare while true, it could be sane to make the default to not respect the http_proxy command as we don’t expect people to want to expose their aw-watchers outside of localhost. We could for example have a config for it in aw-client to toggle it on/off.

Read more comments on GitHub >

github_iconTop Results From Across the Web

"Cannot connect the computer to the server" error message ...
Cannot connect the computer to the server because either another software installation is in progress or, the computer has a restart pending.
Read more >
Classic Recorder error "Could not connect to the server" with ...
Problem. When opening your Knowmia (formerly TechSmith Relay) Classic Recorder the following error occurs: Could not connect to the server. Make ...
Read more >
Device can not connect to the server. - Cisco Community
Hi dear friends. I have Kiosk Device thats connect to the server with 18888 or 18080 port . This device must open given...
Read more >
Work area sync fails and displays a "Still can not connect ... - IBM
Answer. Restart the server daemon or service on the server host. On UNIX, log in as ccm_root and use these commands: ccm_server -stop...
Read more >
Troubleshoot connecting to your instance - AWS Documentation
How can I connect to my Linux instance?. Connect to your instance using the new key pair. Error: User key not recognized by...
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