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

locking pid file failure still returns 0 #12

Closed
objcode opened this issue Sep 30, 2011 · 2 comments
Closed

locking pid file failure still returns 0 #12

objcode opened this issue Sep 30, 2011 · 2 comments

Comments

@objcode
Copy link
Contributor

objcode commented Sep 30, 2011

When starting gservice, if the pidfile lock fails gservice still returns 0. This should be an error return.

Traceback (most recent call last):
File "/usr/local/python/bin/gservice", line 8, in
load_entry_point('gservice==0.2.0', 'console_scripts', 'gservice')()
File "/usr/local/python/lib/python2.7/site-packages/gservice-0.2.0-py2.7.egg/gservice/runner.py", line 22, in main
Runner().do_action()
File "/usr/local/python/lib/python2.7/site-packages/gservice-0.2.0-py2.7.egg/gservice/runner.py", line 255, in do_action
getattr(self, func)(_args, *_kwargs)
File "/usr/local/python/lib/python2.7/site-packages/gservice-0.2.0-py2.7.egg/gservice/runner.py", line 247, in _start
super(Runner, self)._start()
File "/usr/local/python/lib/python2.7/site-packages/python_daemon-1.6-py2.7.egg/daemon/runner.py", line 124, in _start
self.daemon_context.open()
File "/usr/local/python/lib/python2.7/site-packages/python_daemon-1.6-py2.7.egg/daemon/daemon.py", line 346, in open
self.pidfile.enter()
File "build/bdist.linux-i686/egg/lockfile/init.py", line 226, in enter
File "/usr/local/python/lib/python2.7/site-packages/python_daemon-1.6-py2.7.egg/daemon/pidfile.py", line 42, in acquire
super(TimeoutPIDLockFile, self).acquire(timeout, _args, *_kwargs)
File "build/bdist.linux-i686/egg/lockfile/pidlockfile.py", line 85, in acquire
lockfile.LockTimeout

@progrium
Copy link
Owner

Right. We want to catch LockTimeout and display a friendly [ERROR] message and return 1 (or something)

@objcode
Copy link
Contributor Author

objcode commented Sep 30, 2011

deleting this.

@objcode objcode closed this as completed Sep 30, 2011
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