Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Static content: index.html of watcher: aw-watcher-utilization not found! #8

Closed
erngab opened this issue Jan 2, 2023 · 8 comments
Closed
Assignees

Comments

@erngab
Copy link

erngab commented Jan 2, 2023

Windows 10

  1. Unzip as aw-watcher-utilization folder.
  2. Move the folder to "C:\Program Files (x86)\ActivityWatch" directory.
  3. I go to the "C:\Users\ernga\AppData\Local\activitywatch\activitywatch\aw-qt" directory.
  4. To aw-qt.toml file I add the aw-watcher-utilization.
[aw-qt]
autostart_modules = ["aw-server", "aw-watcher-afk", "aw-watcher-window", "aw-watcher-utilization"]

[aw-qt-testing]
autostart_modules = ["aw-server", "aw-watcher-afk", "aw-watcher-window", "aw-watcher-utilization"]

In ActivityWatch I add Custom Visualization
Watcher name: aw-watcher-utilization
Visualisation title: Utilization

It doesn't start, text appears in its place:
Static content: index.html of watcher: aw-watcher-utilization not found!

Log file in aw-watcher-utilization folder:

2023-01-02 13:37:01 [INFO ]: aw-watcher-utilization started  (aw_watcher_utilization.watcher:26)
2023-01-02 13:37:02 [INFO ]: Connection to aw-server established by aw-watcher-utilization  (aw_client.client:419)
@MarshMello0
Copy link

I'm currently struggling with this as well. Did you happen to find a way to set it up @erngab?

@erngab
Copy link
Author

erngab commented Jan 12, 2023

I haven't found a solution.

@Alwinator
Copy link
Owner

@erngab @MarshMello0 The static content of aw-watcher-utilization will probably not work with the current version because it was my PoC implementation of how the "custom-visualization" feature could look like. Afterward, the ActivityWatch team changed some things before merging it.

See the feature request: ActivityWatch/activitywatch#453
And the pull request: ActivityWatch/aw-server#83

To summarize: Instead of having a URL/GET Variable that includes the data, you need to use the Activity Watch Client and only get the timespan from the URL parameters.

Unfortunately, I had no time to implement the new version for aw-watcher-utilization, however, that would be a nice and simple pull request, if you have time. :) I would love to merge it!

You can find a working example of a custom visualization here
(PR of visualization: ActivityWatch/aw-watcher-input#12)

@BLACK4585
Copy link

Is there a chance this gets implemented sometime?

@Alwinator Alwinator self-assigned this Aug 29, 2023
@Alwinator
Copy link
Owner

@BLACK4585 I will try to find time in the next few days.

@Alwinator
Copy link
Owner

@erngab @MarshMello0 @BLACK4585

Good news!

I've successfully implemented visualizations for aw-watcher-utilization. (b6449bd)

You can now follow my guide on how to set them up for you. Make sure you have the new v1.2.0 version installed.

Unfortunately, for now, there is only the cpu_percent visualization because I cannot add more before this PR is merged: ActivityWatch/aw-webui#475

@ErikBjare Feel free to use my watcher as an example. I tried to keep the visualization as simple as possible by only using plain HTML. (Instead of setting up a whole project with Vue or Webpack)

img

@ErikBjare
Copy link

@Alwinator Excellent work! I decided to mention it in the docs: ActivityWatch/docs@369bcb8

@Alwinator
Copy link
Owner

@ErikBjare That's a great idea, thanks! :)

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants