wakatime / micro-wakatime

Micro editor plugin for automatic time tracking and metrics generated from your programming activity.
https://wakatime.com/micro
22 stars 4 forks source link

Micro fails to start #2

Closed muety closed 3 years ago

muety commented 3 years ago

I tried to install the plugin, but micro fails to start then, giving the folllowing error.

Plugin wakatime: wakatime:157: attempt to call a non-function object
stack traceback:
  wakatime:157: in function 'downloadCli'
  wakatime:37: in function 'checkCli'
  wakatime:26: in main chunk
  [G]: ?
Press enter to continue

log.txt

2020/11/22 14:29:09 Micro started
2020/11/22 14:29:09 initializing WakaTime v1.0.0
2020/11/22 14:29:09 downloading wakatime-cli from https://wakatime-cli.s3-us-west-2.amazonaws.com/linux-x86-64/wakatime-cli.zip
2020/11/22 14:29:11 WakaTime initialized

Info

Yesterday, I installed the plugin on my other machine (Fedora 33) with the same version of micro and it works fine. However, on that machine I was already using Wakatime with other IDEs, while on the above (Debian) machine, Wakatime was not installed upfront.

hcbt commented 3 years ago

I'm having the same problem. This might be related to #1 . While I compiled micro with the implemented patches for that problem this is a new issue I've faced.

gandarez commented 3 years ago

Fixes applied please update wakatime plugin using micro-editor.

> plugin update wakatime
hcbt commented 3 years ago

Still does not work. Gives exactly the same error as before.

Plugin wakatime: wakatime:157: attempt to call a non-function object
stack traceback:
    wakatime:157: in function 'downloadCli'
    wakatime:37: in function 'checkCli'
    wakatime:26: in main chunk
    [G]: ?
gandarez commented 3 years ago

Please make sure you updated correctly by checking the first line of wakatime.lua file. You must see VERSION = 1.0.1. I can't reproduce anymore the error on my side.

awk 'NR==1 {print; exit}' ~/.config/micro/plug/wakatime/wakatime.lua
muety commented 3 years ago

Same thing here.

$ awk 'NR==1 {print; exit}' ~/.config/micro/plug/wakatime/wakatime.lua
VERSION = "1.0.1"

However, issue still occurs.

gandarez commented 3 years ago

@muety have you built micro from source?

muety commented 3 years ago

@muety have you built micro from source?

Yes.

gandarez commented 3 years ago

New version has been released could you please try it out? v1.0.2

muety commented 3 years ago

I'm sorry, still the same problem 😕 Can I help you debug this any further?

$ micro -plugin install wakatime
Downloading "wakatime" (1.0.2) from "https://github.com/wakatime/micro-wakatime/archive/1.0.2.zip"
One or more plugins installed.
gandarez commented 3 years ago

Thanks for you patience. There was a misspelling on calling os lib. Please update it and try again.

muety commented 3 years ago

It works! Thanks!