Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

Not tracking coding activity #48

Closed
zchee opened this issue Apr 23, 2017 · 7 comments
Closed

Not tracking coding activity #48

zchee opened this issue Apr 23, 2017 · 7 comments

Comments

@zchee
Copy link

zchee commented Apr 23, 2017

Current master(df845c3) branch can't catch the code activity.
I do not yet debug, but test on eb862c8 works fine.

@alanhamlett
Copy link
Member

alanhamlett commented Apr 23, 2017

Can you upgrade to latest master again, then turn on debug mode with :WakaTimeDebugEnable?

The error message will be printed to either Vim Status Bar, or ~/.wakatime.log so also run this Terminal command:
tail -f ~/.wakatime.log

The logs will only be generated once every 10 seconds, because heartbeats are cached in Vim for performance.

@alanhamlett alanhamlett changed the title no catch activity Not tracking coding activity Apr 23, 2017
@zchee
Copy link
Author

zchee commented Apr 23, 2017

@alanhamlett OK, will do.
Just FYI, yesterday's activity is 0 hour, but wakatime Dashboard displayed today's (until now, in JST) activity is 1.5 hour.

@alanhamlett
Copy link
Member

With debug mode enabled you should see the error message printed to the Vim Status Bar or to ~/.wakatime.log very soon after editing/saving a file in Vim.

@zchee
Copy link
Author

zchee commented Apr 24, 2017

@alanhamlett Just post error message only, not yet debug vim-wakatime source.
Also, not tested whether the get the activity.

hash: 5b22d4c

~/.wakatime.log

.
.
.
{"now": "2017/04/24 15:49:09 +0900", "version": "8.0.0", "plugin": "vim/704 vim-wakatime/5.0.0", "time": 1747.434533, "caller": "/Users/zchee/.cache/nvim/dein/.cache/init.vim/.dein/plugin/packages/wakatime/main.py", "lineno": 68, "file": "/Users/zchee/go/src/github.com/zchee/nvim-go/src/nvim-go/command/build.go", "level": "DEBUG", "message": "Sending heartbeat to api at https://api.wakatime.com/api/v1/heartbeats"}
{"now": "2017/04/24 15:49:09 +0900", "version": "8.0.0", "plugin": "vim/704 vim-wakatime/5.0.0", "time": 1747.434533, "caller": "/Users/zchee/.cache/nvim/dein/.cache/init.vim/.dein/plugin/packages/wakatime/main.py", "lineno": 103, "file": "/Users/zchee/go/src/github.com/zchee/nvim-go/src/nvim-go/command/build.go", "level": "DEBUG", "message": "{'dependencies': ['\"github.com/pkg/errors\"', '\"os\"', '\"context\"', '\"time\"', '\"nvim-go/nvimutil\"', '\"log\"', '\"os/exec\"', '\"path/filepath\"', '\"nvim-go/config\"', '\"bytes\"', '\"github.com/neovim/go-client/nvim\"'], 'time': 1747.434533, 'project': 'nvim-go', 'type': 'file', 'language': 'Go', 'branch': 'context-cancellation', 'entity': '/Users/zchee/go/src/github.com/zchee/nvim-go/src/nvim-go/command/build.go', 'lines': 133}"}
{"now": "2017/04/24 15:49:10 +0900", "version": "8.0.0", "plugin": "vim/704 vim-wakatime/5.0.0", "time": 1747.434533, "caller": "/Users/zchee/.cache/nvim/dein/.cache/init.vim/.dein/plugin/packages/wakatime/main.py", "lineno": 200, "file": "/Users/zchee/go/src/github.com/zchee/nvim-go/src/nvim-go/command/build.go", "level": "ERROR", "message": "{'response_code': 400, 'response_content': '{\\n  \"errors\": {\\n    \"time\": [\\n      \"Number must be between 1388534400 and 99999999999.\"\\n    ]\\n  }\\n}\\n'}"}
{"now": "2017/04/24 15:49:15 +0900", "version": "8.0.0", "plugin": "vim/704 vim-wakatime/5.0.0", "time": 1751.498276, "caller": "/Users/zchee/.cache/nvim/dein/.cache/init.vim/.dein/plugin/packages/wakatime/main.py", "lineno": 68, "is_write": true, "file": "/Users/zchee/go/src/github.com/zchee/nvim-go/src/nvim-go/command/build.go", "level": "DEBUG", "message": "Sending heartbeat to api at https://api.wakatime.com/api/v1/heartbeats"}
{"now": "2017/04/24 15:49:15 +0900", "version": "8.0.0", "plugin": "vim/704 vim-wakatime/5.0.0", "time": 1751.498276, "caller": "/Users/zchee/.cache/nvim/dein/.cache/init.vim/.dein/plugin/packages/wakatime/main.py", "lineno": 103, "is_write": true, "file": "/Users/zchee/go/src/github.com/zchee/nvim-go/src/nvim-go/command/build.go", "level": "DEBUG", "message": "{'lines': 133, 'dependencies': ['\"nvim-go/config\"', '\"os/exec\"', '\"nvim-go/nvimutil\"', '\"log\"', '\"os\"', '\"context\"', '\"path/filepath\"', '\"time\"', '\"bytes\"', '\"github.com/pkg/errors\"', '\"github.com/neovim/go-client/nvim\"'], 'project': 'nvim-go', 'type': 'file', 'language': 'Go', 'is_write': True, 'branch': 'context-cancellation', 'entity': '/Users/zchee/go/src/github.com/zchee/nvim-go/src/nvim-go/command/build.go', 'time': 1751.498276}"}
{"now": "2017/04/24 15:49:15 +0900", "version": "8.0.0", "plugin": "vim/704 vim-wakatime/5.0.0", "time": 1751.498276, "caller": "/Users/zchee/.cache/nvim/dein/.cache/init.vim/.dein/plugin/packages/wakatime/main.py", "lineno": 200, "is_write": true, "file": "/Users/zchee/go/src/github.com/zchee/nvim-go/src/nvim-go/command/build.go", "level": "ERROR", "message": "{'response_code': 400, 'response_content': '{\\n  \"errors\": {\\n    \"time\": [\\n      \"Number must be between 1388534400 and 99999999999.\"\\n    ]\\n  }\\n}\\n'}"}

~/.wakatime.cfg
comment-out my options for tiny environment.

[settings]
debug=true
api_key = xxxxxx  # hide
# hidefilenames = false
# ignore =
#   ^COMMIT_EDITMSG$
#   ^TAG_EDITMSG$
#   ^PULLREQ_EDITMSG$
#   MERGE_MSG$
#   TAG_EDITMSG$
# include =
#   .*
# offline = true
# timeout = 30
# projects/foo = new project name

# vim:ft=dosini

EDIT: If use eb862c8, not displayed Number must be between 1388534400 and 99999999999 error on debug=false.

@alanhamlett
Copy link
Member

Just updated the plugin, can you try with the latest version?

@zchee
Copy link
Author

zchee commented Apr 24, 2017

@alanhamlett I'll try latest commit later. thanks quickly!!

@zchee
Copy link
Author

zchee commented Apr 25, 2017

@alanhamlett It seems to fixed on 5b52ce4
I was checked tracking of my yesterday's activity. Works fine.
Thanks quickly!

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

No branches or pull requests

2 participants