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

CherryPy error #12

Closed
kevincberry opened this issue Sep 14, 2016 · 7 comments
Closed

CherryPy error #12

kevincberry opened this issue Sep 14, 2016 · 7 comments

Comments

@kevincberry
Copy link

I'm encountering a CherryPy error when attempting to authenticate with FitBit's api

`root@sync:/home/fitbit-googlefit-master/auth# python3 auth_fitbit.py 227YZF 7951c07a5b033aedff38ec6002703684
[14/Sep/2016:20:27:07] ENGINE Listening for SIGTERM.
[14/Sep/2016:20:27:07] ENGINE Listening for SIGUSR1.
[14/Sep/2016:20:27:07] ENGINE Listening for SIGHUP.
[14/Sep/2016:20:27:07] ENGINE Bus STARTING
CherryPy Checker:
The Application mounted at '' has an empty config.

[14/Sep/2016:20:27:07] ENGINE Started monitor thread '_TimeoutMonitor'.
[14/Sep/2016:20:27:07] ENGINE Started monitor thread 'Autoreloader'.
[14/Sep/2016:20:27:12] ENGINE Error in 'start' listener <bound method Server.start of <cherrypy._cpserver.Server object at 0x7effd5aeba58>>
Traceback (most recent call last):
File "/usr/local/lib/python3.5/dist-packages/cherrypy/process/wspbus.py", line 205, in publish
output.append(listener(_args, *_kwargs))
File "/usr/local/lib/python3.5/dist-packages/cherrypy/_cpserver.py", line 168, in start
ServerAdapter.start(self)
File "/usr/local/lib/python3.5/dist-packages/cherrypy/process/servers.py", line 170, in start
wait_for_free_port(*self.bind_addr)
File "/usr/local/lib/python3.5/dist-packages/cherrypy/process/servers.py", line 439, in wait_for_free_port
raise IOError("Port %r not free on %r" % (port, host))
OSError: Port 8080 not free on '127.0.0.1'

[14/Sep/2016:20:27:12] ENGINE Shutting down due to error in start listener:
Traceback (most recent call last):
File "/usr/local/lib/python3.5/dist-packages/cherrypy/process/wspbus.py", line 243, in start
self.publish('start')
File "/usr/local/lib/python3.5/dist-packages/cherrypy/process/wspbus.py", line 223, in publish
raise exc
cherrypy.process.wspbus.ChannelFailures: OSError("Port 8080 not free on '127.0.0.1'",)

[14/Sep/2016:20:27:12] ENGINE Bus STOPPING
[14/Sep/2016:20:27:12] ENGINE HTTP Server cherrypy._cpwsgi_server.CPWSGIServer(('127.0.0.1', 8080)) already shut down
[14/Sep/2016:20:27:12] ENGINE Stopped thread '_TimeoutMonitor'.
[14/Sep/2016:20:27:12] ENGINE Stopped thread 'Autoreloader'.
[14/Sep/2016:20:27:12] ENGINE Bus STOPPED
[14/Sep/2016:20:27:12] ENGINE Bus EXITING
[14/Sep/2016:20:27:12] ENGINE Bus EXITED
`

Is my suspicion that the problem is somewhere outside the fitbit-googlefit app correct? Should I be looking at my server configuration instead of the app to find the problem?

@pkpio
Copy link
Owner

pkpio commented Sep 15, 2016

@kevincberry , Are you trying to run the authentication scripts on a headless server?

I would advise to do the authentication on a system with a display and transfer the credentials manually to your server if you prefer to use it from there.

@kevincberry
Copy link
Author

Yes, I'm running it on a Digital Ocean server running Ubuntu.

Should I not be doing that?

On Wed, Sep 14, 2016, 9:07 PM Praveen Kumar Pendyala <
notifications@github.com> wrote:

@kevincberry https://github.com/kevincberry , Are you trying to run the
authentication scripts on a headless server?


You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
#12 (comment),
or mute the thread
https://github.com/notifications/unsubscribe-auth/AFe6Tz__VvePhYDz8tRrsd04KCbU-yq_ks5qqJo5gaJpZM4J9NWX
.

@pkpio
Copy link
Owner

pkpio commented Sep 18, 2016

@kevincberry , I run it on a Digital Ocean droplet too - in fact I have setup a cron job to sync daily for a couple of weeks now.

However, the one-time authentication requires a browser with a display - hence locally and transfer the credentials.

@kevincberry
Copy link
Author

I'm relatively new to working within a command line environment. Can you
give some more guidance on how to do this in a local environment?

On Sun, Sep 18, 2016, 4:50 AM Praveen Kumar Pendyala <
notifications@github.com> wrote:

@kevincberry https://github.com/kevincberry , I run it on a Digital
Ocean droplet too - in fact I have setup a cron job to sync daily for a
couple of weeks now.

However, the one-time authentication requires a browser with a display -
hence locally and transfer the credentials.


You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
#12 (comment),
or mute the thread
https://github.com/notifications/unsubscribe-auth/AFe6T1UX3aiV2Llo-UU9Meq2q1C2F0lmks5qrPtLgaJpZM4J9NWX
.

@pkpio
Copy link
Owner

pkpio commented Sep 18, 2016

It works similar to how you set it up on Digital ocean. Just follow the Setup instructions on your local PC.

If you are using Windows, may be try this inside a Virtual box with Linux VM.

@kevincberry
Copy link
Author

Great, I've got sorted it out now.

Thank you!

@pkpio
Copy link
Owner

pkpio commented Sep 20, 2016

Good to know it's working for you 😄

@pkpio pkpio closed this as completed Sep 20, 2016
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