wakapi
wakapi copied to clipboard
VSCode "WakaTime Error" in statusbar, does not collect stats
related: #153
$ uname -a
Darwin M1.local 23.3.0 Darwin Kernel Version 23.3.0: Wed Dec 20 21:30:44 PST 2023; root:xnu-10002.81.5~7/RELEASE_ARM64_T6000 arm64 arm Darwin
latest entry in ~/.config/wakatime/wakatime.log
:
{"caller":"cmd/run.go:158","func":"cmd.Run","level":"warning","message":"one of the following parameters has to be provided: --config-read, --config-write, --entity, --offline-count, --print-offline-heartbeats, --sync-offline-activity, --today, --today-goal, --useragent, --version","now":"2024-04-21T22:24:54+03:00","os/arch":"darwin/arm64","version":"v1.90.0"}
vscode developer tools:
workbench.desktop.main.js:655 ERR [Extension Host] [WakaTime][ERROR] Error: Command failed: /Users/kipras/.wakatime/wakatime-cli-darwin-arm64 --entity /Users/kipras/projects/turbo-schedule/common/src/util/findTopK.ts --plugin "vscode/1.86.2 vscode-wakatime/24.2.0" --lineno 4 --cursorpos 26 --lines-in-file 30 --alternate-project turbo-schedule --project-folder /Users/kipras/projects/turbo-schedule
workbench.desktop.main.js:149 [Extension Host] [WakaTime][ERROR] Error: Command failed: /Users/kipras/.wakatime/wakatime-cli-darwin-arm64 --entity /Users/kipras/projects/turbo-schedule/common/src/util/findTopK.ts --plugin "vscode/1.86.2 vscode-wakatime/24.2.0" --lineno 4 --cursorpos 26 --lines-in-file 30 --alternate-project turbo-schedule --project-folder /Users/kipras/projects/turbo-schedule
S @ workbench.desktop.main.js:149
workbench.desktop.main.js:149 [Extension Host] [WakaTime][WARN] Working offline (102); Check your /Users/kipras/.wakatime/wakatime.log file for more details
S @ workbench.desktop.main.js:149
This looks like a problem related to the wakatime-cli, rather than Wakapi, so perhaps file an issue with them? Nevertheless, can you show the contents of your .wakatime.cfg
(with API key redacted), please?
[settings]
# Your Wakapi server URL or 'https://wakapi.dev/api' when using the cloud server
api_url = http://localhost:10006/api
# Your Wakapi API key (get it from the web interface after having created an account)
api_key = REDACTED
$ ./.wakatime/wakatime-cli --version
v1.90.0
could it be that something changed in the vscode extension, and the cli didn't update?
- https://github.com/wakatime/vscode-wakatime/blob/master/CHANGELOG.md#2450-2024-04-10
- https://github.com/wakatime/vscode-wakatime/issues/388
- https://github.com/wakatime/vscode-wakatime/issues/346
Is it working for editors other than VSCode? Also, maybe try to temporarily create an account at official wakatime.com and see if it works there. I highly suspect it's an issue with the CLI, though. I'd say file an issue there.
I ran the exact command that had failed for you on my machine and it worked fine, with latest CLI version, but different OS specs, though:
$ uname -a
Linux ferdinand.desktop 6.8.6-200.fc39.x86_64 #1 SMP PREEMPT_DYNAMIC Sat Apr 13 15:14:23 UTC 2024 x86_64 GNU/Linux
Any updates on this?
hmm, it looks like wakatime in vscode just started working again. not sure what happened.. probably can close this
https://github.com/wakatime/vscode-wakatime/blob/master/CHANGELOG.md#2450-2024-04-10
24.5.0 (2024-04-10)
- Modify api_key_vault_cmd to match wakatime-cli.
i think this was it.