GaretJax / lancet

Command line utility to streamline various development activities.
MIT License
9 stars 5 forks source link

ValueError #13

Closed vxsx closed 9 years ago

vxsx commented 9 years ago
± % lancet workon 145                                                                                                                                                                                                                                           !12674 17:51:13
 ✓  Retrieved issue PRJ-145: redacted
 ✓  Issue assigned to you
 ✓  Issue status set to "In Progress"
 ✓  Checked out working branch based on "master"
 ✗  ValueError: Expecting value: line 1 column 1 (char 0)
Traceback (most recent call last):
  File "/Users/divio/.local/bin/lancet", line 11, in <module>
    sys.exit(main())
  File "/Users/divio/.local/venvs/lancet/lib/python3.4/site-packages/click/core.py", line 610, in __call__
    return self.main(*args, **kwargs)
  File "/Users/divio/.local/venvs/lancet/lib/python3.4/site-packages/click/core.py", line 590, in main
    rv = self.invoke(ctx)
  File "/Users/divio/.local/venvs/lancet/lib/python3.4/site-packages/click/core.py", line 936, in invoke
    return _process_result(sub_ctx.command.invoke(sub_ctx))
  File "/Users/divio/.local/venvs/lancet/lib/python3.4/site-packages/click/core.py", line 782, in invoke
    return ctx.invoke(self.callback, **ctx.params)
  File "/Users/divio/.local/venvs/lancet/lib/python3.4/site-packages/click/core.py", line 416, in invoke
    return callback(*args, **kwargs)
  File "/Users/divio/.local/venvs/lancet/lib/python3.4/site-packages/lancet/cli.py", line 252, in workon
    lancet.timer.start(issue)
  File "/Users/divio/.local/venvs/lancet/lib/python3.4/site-packages/lancet/harvest.py", line 31, in wrapper
    return func(self, *args, **kwargs)
  File "/Users/divio/.local/venvs/lancet/lib/python3.4/site-packages/lancet/harvest.py", line 164, in start
    assert 'message' in r.json()
  File "/Users/divio/.local/venvs/lancet/lib/python3.4/site-packages/requests/models.py", line 799, in json
    return json.loads(self.text, **kwargs)
  File "/usr/local/Cellar/python3/3.4.2_1/Frameworks/Python.framework/Versions/3.4/lib/python3.4/json/__init__.py", line 318, in loads
    return _default_decoder.decode(s)
  File "/usr/local/Cellar/python3/3.4.2_1/Frameworks/Python.framework/Versions/3.4/lib/python3.4/json/decoder.py", line 343, in decode
    obj, end = self.raw_decode(s, idx=_w(s, 0).end())
  File "/usr/local/Cellar/python3/3.4.2_1/Frameworks/Python.framework/Versions/3.4/lib/python3.4/json/decoder.py", line 361, in raw_decode
    raise ValueError(errmsg("Expecting value", s, err.value)) from None
ValueError: Expecting value: line 1 column 1 (char 0)

not sure if this is relevant, but worked on the issue the day before - was okay, created timer correctly. today there is not yet a timer for it - this happens

vxsx commented 9 years ago

So after some debugging with @GaretJax we realized that the problem was in the ~/.lancet config file, where harvest url was with http:// and not https://. It should always be https://<company>.harvestapp.com

Closing this.