GithubHelp home page GithubHelp logo

daemons's People

Contributors

alexdelorenzo avatar kevinconway avatar leforestier avatar tai271828 avatar tonytan4ever avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

daemons's Issues

More a question than an issue

Hello, I am glad to have found your package after such a long time looking for something simple to run my Django app command inside as a daemon !

I was wondering if there is a way to use daemonizer decorator to stop the process ?

Can't start killed process

When I killed daemon process "python ShowMe.py" from OS,
I am triyng to start it again

python ShowMe.py start

and getting error

daemon.pid already exist. Cannot start daemon.

but process is dead!

so, I changed in start method

if pid is not None:
    message = "Pidfile %s already exist. Cannot start daemon."

to

if pid is not None and psutil.pid_exists(pid):
    message = "Pidfile %s already exist. Cannot start daemon."

psutil imported from https://github.com/giampaolo/psutil

Stopping daemon fails with AttributeError

On python 3, stopping the daemon raises an AttributeError (the simple daemon example on https://pypi.python.org/pypi/daemons will produce the error).

Traceback (most recent call last):
  File "/home/username/mydaemon.py", line 33, in <module>
    d.stop()
  File "/home/username/.local/lib/python3.5/site-packages/daemons/startstop/simple.py", line 81, in stop
    if "an integer is required" in err.message:
AttributeError: 'TypeError' object has no attribute 'message'

This is because Exception instances in python3 don't have the message attribute. It should probably be replaced with str(err).

How to solve this? ValueError: invalid signal error

I am trying to work with SimulaQron (https://github.com/SoftwareQuTech/SimulaQron) on my Windows. However, when I want to start it (via "simulaqron start") I run into the error "ValueError: invalid signal error". The error seems to result from daemons:
image

Therefore, I tried the example on https://github.com/kevinconway/daemons and this indeed gave the same error:
image
Here foo2.py is the second .py file as indicated in the example, so the one with "if __name__".

It seems to me that the problem is with pidfile. The value for pidfile in d = SleepyDaemon(pidfile=pidfile) is in my case:
C:\Users\Lynn\Documents\Capstone\testdaemon sleepy.pid
(Here, testdaemon is the directory in which the files of the example are stored.)

I am wondering if someone has an idea what is causing this problem. It would be great to fix this so that I (and others) could work with SimulaQron and daemons via Windows.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.