Closed newuser01986 closed 1 year ago
Is this issue resolved? It is running fine on WSL (Windows Subsystem for Linux) for me without removing the double fork.
See this article for example of os.fork() https://www.geeksforgeeks.org/python-os-fork-method/ When os.fork() is called, a second process is created, and both are running at the same line of code. One is the Parent process and the other is the Child process. However, os.fork() "returns 0 in the child process and child’s process id in the parent process".
I ran on Windows Powershell and got the same issue (with extra logging to explain what is happening on windows)
> python Recordurbate.py start
Recordurbate.py main() - calling Recordurbate.start()
Recordurbate.py bot() - starting daemon
daemon.py daemonize() - calling os.fork()
Recordurbate.py bot() - daemon created
Recordurbate.py main() - error occurred when calling Recordurbate.start()
Recordurbate.py main() - module 'os' has no attribute 'fork'
Propose to change the caught exception type from OSError to Exception
Windows user.
Everything is installed, but "Python recordurbate.py start" does nothing, it just shows the menu. Looking at my logs it creates a rb.log which says "Starting daemon" but that is it. No rb.pid is created.
Deleting the double fork makes it work:
Which makes sense as pid is always greater than 0... would't this just cause it to always exit?
However, I dont see anything happening in the terminal, but videos ARE being downloaded and the log file has more content: Successfully started daemon, pid: 10840