wakatime / wakatime-cli

Command line interface used by all WakaTime text editor plugins
https://wakatime.com/plugins
BSD 3-Clause "New" or "Revised" License
262 stars 40 forks source link

OpenBSD Cli error: "failed to commit db transaction: function not implemented" #1024

Closed anoduck closed 5 months ago

anoduck commented 5 months ago

Right now, wakatime-cli is throwing errors in the log file. It is safe to assume this is related to #992, but generates a different error response, and was first reported in a previous issue.

Environment:

Notes: I can provide more information about the error at a later moment.

Logs:

{"caller":"cmd/run.go:135","func":"cmd.Run","level":"debug","message":"command: heartbeat","now":"2024-01-29T15:19:11-05:00","os/arch":"openbsd/amd64","version":"<local-build>"} 
{"caller":"cmd/heartbeat/heartbeat.go:77","file":"less","func":"heartbeat.SendHeartbeats","is_write":true,"level":"debug","message":"params: api params: (api key: '<hidden>b6ad', api url: 'https://api.wakatime.com/api/v1', backoff at: '', backoff retries: 0, hostname: 'liberator', key patterns: '[]', plugin: 'wakatime-zsh-plugin/0.2.2', proxy url: '', timeout: 5s, disable ssl verify: false, ssl cert filepath: ''), heartbeat params: (category: 'coding', cursor position: '', entity: 'less', entity type: 'app', num extra heartbeats: 0, guess language: false, is unsaved entity: false, is write: true, language: 'sh', line additions: '', line deletions: '', line number: '', lines in file: '', time: 1706559551.57854, filter params: (exclude: '[]', exclude unknown project: false, include: '[]', include only with project file: false), project params: (alternate: '', branch alternate: '', map patterns: '[]', override: 'Terminal', git submodules disabled: '[]', git submodule project map: '[]'), sanitize params: (hide branch names: '[]', hide project folder: false, hide file names: '[]', hide project names: '[]', project path override: '')), offline params: (disabled: false, print max: 10, queue file: '', num sync max: 1000), status bar params: (hide categories: false, output: 'text')","now":"2024-01-29T15:19:11-05:00","os/arch":"openbsd/amd64","plugin":"wakatime-zsh-plugin/0.2.2","time":1706559551.5785441,"version":"<local-build>"} 
{"caller":"cmd/api/api.go:40","file":"less","func":"api.newClient","is_write":true,"level":"debug","message":"failed to detect local timezone: name not implemented for 'openbsd'","now":"2024-01-29T15:19:11-05:00","os/arch":"openbsd/amd64","plugin":"wakatime-zsh-plugin/0.2.2","time":1706559551.5785441,"version":"<local-build>"} 
{"caller":"pkg/heartbeat/format.go:18","file":"less","func":"heartbeat.initHandleOptions","is_write":true,"level":"debug","message":"execute heartbeat filepath formatting","now":"2024-01-29T15:19:11-05:00","os/arch":"openbsd/amd64","plugin":"wakatime-zsh-plugin/0.2.2","time":1706559551.5785441,"version":"<local-build>"} 
{"caller":"pkg/heartbeat/entity_modify.go:15","file":"less","func":"heartbeat.initHandleOptions","is_write":true,"level":"debug","message":"execute heartbeat entity modifier","now":"2024-01-29T15:19:11-05:00","os/arch":"openbsd/amd64","plugin":"wakatime-zsh-plugin/0.2.2","time":1706559551.5785441,"version":"<local-build>"} 
{"caller":"pkg/filter/filter.go:26","file":"less","func":"heartbeat.initHandleOptions","is_write":true,"level":"debug","message":"execute heartbeat filtering","now":"2024-01-29T15:19:11-05:00","os/arch":"openbsd/amd64","plugin":"wakatime-zsh-plugin/0.2.2","time":1706559551.5785441,"version":"<local-build>"} 
{"caller":"pkg/remote/remote.go:53","file":"less","func":"heartbeat.initHandleOptions","is_write":true,"level":"debug","message":"execute remote file detection","now":"2024-01-29T15:19:11-05:00","os/arch":"openbsd/amd64","plugin":"wakatime-zsh-plugin/0.2.2","time":1706559551.5785441,"version":"<local-build>"} 
{"caller":"pkg/apikey/apikey.go:31","file":"less","func":"heartbeat.initHandleOptions","is_write":true,"level":"debug","message":"execute api key replacing","now":"2024-01-29T15:19:11-05:00","os/arch":"openbsd/amd64","plugin":"wakatime-zsh-plugin/0.2.2","time":1706559551.5785441,"version":"<local-build>"} 
{"caller":"pkg/filestats/filestats.go:24","file":"less","func":"heartbeat.initHandleOptions","is_write":true,"level":"debug","message":"execute filestats detection","now":"2024-01-29T15:19:11-05:00","os/arch":"openbsd/amd64","plugin":"wakatime-zsh-plugin/0.2.2","time":1706559551.5785441,"version":"<local-build>"} 
{"caller":"pkg/language/language.go:25","file":"less","func":"heartbeat.initHandleOptions","is_write":true,"level":"debug","message":"execute language detection","now":"2024-01-29T15:19:11-05:00","os/arch":"openbsd/amd64","plugin":"wakatime-zsh-plugin/0.2.2","time":1706559551.5785441,"version":"<local-build>"} 
{"caller":"pkg/deps/deps.go:38","file":"less","func":"heartbeat.initHandleOptions","is_write":true,"level":"debug","message":"execute dependency detection","now":"2024-01-29T15:19:11-05:00","os/arch":"openbsd/amd64","plugin":"wakatime-zsh-plugin/0.2.2","time":1706559551.5785441,"version":"<local-build>"} 
{"caller":"pkg/project/project.go:143","file":"less","func":"heartbeat.initHandleOptions","is_write":true,"level":"debug","message":"execute project detection for: less","now":"2024-01-29T15:19:11-05:00","os/arch":"openbsd/amd64","plugin":"wakatime-zsh-plugin/0.2.2","time":1706559551.5785441,"version":"<local-build>"} 
{"caller":"pkg/project/filter.go:23","file":"less","func":"heartbeat.initHandleOptions","is_write":true,"level":"debug","message":"execute project filtering","now":"2024-01-29T15:19:11-05:00","os/arch":"openbsd/amd64","plugin":"wakatime-zsh-plugin/0.2.2","time":1706559551.5785441,"version":"<local-build>"} 
{"caller":"pkg/heartbeat/sanitize.go:30","file":"less","func":"heartbeat.initHandleOptions","is_write":true,"level":"debug","message":"execute heartbeat sanitization","now":"2024-01-29T15:19:11-05:00","os/arch":"openbsd/amd64","plugin":"wakatime-zsh-plugin/0.2.2","time":1706559551.5785441,"version":"<local-build>"} 
{"caller":"pkg/remote/remote.go:122","file":"less","func":"heartbeat.initHandleOptions","is_write":true,"level":"debug","message":"execute remote cleanup","now":"2024-01-29T15:19:11-05:00","os/arch":"openbsd/amd64","plugin":"wakatime-zsh-plugin/0.2.2","time":1706559551.5785441,"version":"<local-build>"} 
{"caller":"pkg/offline/offline.go:55","file":"less","func":"heartbeat.SendHeartbeats","is_write":true,"level":"debug","message":"execute offline queue with file /home/vassilios/.wakatime.bdb","now":"2024-01-29T15:19:11-05:00","os/arch":"openbsd/amd64","plugin":"wakatime-zsh-plugin/0.2.2","time":1706559551.5785441,"version":"<local-build>"} 
{"caller":"pkg/backoff/backoff.go:43","file":"less","func":"heartbeat.SendHeartbeats","is_write":true,"level":"debug","message":"execute heartbeat backoff algorithm","now":"2024-01-29T15:19:11-05:00","os/arch":"openbsd/amd64","plugin":"wakatime-zsh-plugin/0.2.2","time":1706559551.5785441,"version":"<local-build>"} 
{"caller":"pkg/api/heartbeat.go:27","file":"less","func":"api.(*Client)","is_write":true,"level":"debug","message":"sending 1 heartbeat(s) to api at https://api.wakatime.com/api/v1/users/current/heartbeats.bulk","now":"2024-01-29T15:19:11-05:00","os/arch":"openbsd/amd64","plugin":"wakatime-zsh-plugin/0.2.2","time":1706559551.5785441,"version":"<local-build>"} 
{"caller":"pkg/api/heartbeat.go:52","file":"less","func":"api.(*Client)","is_write":true,"level":"debug","message":"heartbeats: [{\"branch\":\"\",\"category\":\"coding\",\"entity\":\"less\",\"type\":\"app\",\"is_write\":true,\"language\":\"sh\",\"project\":\"Terminal\",\"time\":1706559551.5785441,\"user_agent\":\"wakatime/\\u003clocal-build\\u003e (openbsd-7.4-amd64) go1.21.6 wakatime-zsh-plugin/0.2.2\"}]","now":"2024-01-29T15:19:11-05:00","os/arch":"openbsd/amd64","plugin":"wakatime-zsh-plugin/0.2.2","time":1706559551.5785441,"version":"<local-build>"} 
{"caller":"cmd/heartbeat/heartbeat.go:62","file":"less","func":"heartbeat.Run","is_write":true,"level":"debug","message":"successfully sent heartbeat(s)","now":"2024-01-29T15:19:11-05:00","os/arch":"openbsd/amd64","plugin":"wakatime-zsh-plugin/0.2.2","time":1706559551.5785441,"version":"<local-build>"} 
{"caller":"cmd/api/api.go:40","file":"less","func":"api.newClient","is_write":true,"level":"debug","message":"failed to detect local timezone: name not implemented for 'openbsd'","now":"2024-01-29T15:19:11-05:00","os/arch":"openbsd/amd64","plugin":"wakatime-zsh-plugin/0.2.2","time":1706559551.5785441,"version":"<local-build>"} 
{"caller":"pkg/offline/offline.go:107","file":"less","func":"offlinesync.SyncOfflineActivity","is_write":true,"level":"debug","message":"execute offline sync with file /home/vassilios/.wakatime.bdb","now":"2024-01-29T15:19:11-05:00","os/arch":"openbsd/amd64","plugin":"wakatime-zsh-plugin/0.2.2","time":1706559551.5785441,"version":"<local-build>"} 
{"caller":"cmd/run.go:341","file":"less","func":"cmd.runCmd","is_write":true,"level":"error","message":"failed to run command: offline sync failed: failed to sync offline heartbeats: failed to fetch heartbeat from offline queue: failed to commit db transaction: function not implemented","now":"2024-01-29T15:19:11-05:00","os/arch":"openbsd/amd64","plugin":"wakatime-zsh-plugin/0.2.2","time":1706559551.5785441,"version":"<local-build>"} 
gandarez commented 5 months ago

I opened an issue with the code maintainer

https://github.com/etcd-io/bbolt/issues/684

anoduck commented 5 months ago

@gandarez That is good! It looks like you have been able to further diagnose the issue, tracing it to a particular model. I greatly appreciate this.

gandarez commented 5 months ago

@anoduck I'm looking for building for OpenBSD manually and distribute to you before releasing any fix. I need your help since you have an OpenBSD up and running. Would you join us at Slack?

https://join.slack.com/t/wakatime/shared_invite/zt-2bz7i7u5e-K6JpRWnS0lu6AdS~UsVxoQ

anoduck commented 5 months ago

I signed up, and am there.

anoduck commented 5 months ago

WooHoo!!!