Skip Menu |

This queue is for tickets about the MooseX-Daemonize CPAN distribution.

Report information
The Basics
Id: 83055
Status: resolved
Priority: 0/
Queue: MooseX-Daemonize

People
Owner: Nobody in particular
Requestors: CALDRIN [...] cpan.org
Cc:
AdminCc:

Bug Information
Severity: Important
Broken in: (no value)
Fixed in: (no value)



Subject: unexpected chdir to $self->basedir
MooseX::Daemonize changes the working directory of the daemon unconditionally. It does change it to $self->basedir which defaults to '/'. Since basedir is not documented users usually will not be able to influence the chdir and therefore be stuck with a daemon that can not access files with relatives paths. I think the best way would be to remove the chdir completely. A user who wants it can easily put it into his own code while a user who does not want it would need to set $self->basedir to Cwd->getcwd, a much more uncomfortable solution. Also, I don't see any good reason for a chdir to / at all. If you don't agree and would rather keep the chdir I suggest to at least document the basedir attribute especially in the example.
Changing the behaviour of basedir and its default would break backcompat and could cause some existing programs to fail, so I've added documentation. thanks for the report! v0.16 will be released shortly.