-
-
06 Jan 2016 08:02:40 UTC
- Distribution: Proc-ChildError
- Module version: 0.04
- Source (raw)
- Browse (raw)
- Changes
- Homepage
- How to Contribute
- Repository
- Issues
- Testers (9989 / 1 / 7)
- Kwalitee
Bus factor: 1- 100.00% Coverage
- License: perl_5
- Perl: v5.8.0
- Activity
24 month- Tools
- Download (13.4KB)
- MetaCPAN Explorer
- Permissions
- Subscribe to distribution
- Permalinks
- This version
- Latest version
++ed by:1 non-PAUSE user- Dependencies
- none
- Reverse dependencies
- CPAN Testers List
- Dependency graph
NAME
Proc::ChildError - Explain process child error
VERSION
This document describes version 0.04 of Proc::ChildError (from Perl distribution Proc-ChildError), released on 2016-01-06.
FUNCTIONS
explain_child_error([\%opts, ]$child_error, $os_error) => STR
Produce a string description of an error number.
$child_error
defaults to$?
if not specified.$os_error
defaults to$!
if not specified.The algorithm is taken from perldoc -f system. Some sample output:
failed to execute: No such file or directory (-1) died with signal 15, with coredump exited with value 3
An options hashref can be specified as the first argument to add information. Currently known keys:
prog => str
Program name/path, to include in error messages:
/usr/bin/foo failed to execute: Permission denied (-1) foo died with signal 15, with coredump /usr/bin/foo exited with value 3
SEE ALSO
Process::Status provides a lightweight OO interface for
$?
. I recommend this module now over Proc::ChildError.IPC::System::Simple provides a replacement for Perl's
system()
, with the difference that it will print a diagnostic error message similar to whatProc::ChildError
provides. You only need to douse IPC::System::Simple qw(system)
and usesystem()
as usual. Recommended.HOMEPAGE
Please visit the project's homepage at https://metacpan.org/release/Proc-ChildError.
SOURCE
Source repository is at https://github.com/perlancar/perl-Proc-ChildError.
BUGS
Please report any bugs or feature requests on the bugtracker website https://rt.cpan.org/Public/Dist/Display.html?Name=Proc-ChildError
When submitting a bug or request, please include a test-file or a patch to an existing test-file that illustrates the bug or desired feature.
AUTHOR
perlancar <perlancar@cpan.org>
COPYRIGHT AND LICENSE
This software is copyright (c) 2016 by perlancar@cpan.org.
This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.
Module Install Instructions
To install Proc::ChildError, copy and paste the appropriate command in to your terminal.
cpanm Proc::ChildError
perl -MCPAN -e shell install Proc::ChildError
For more information on module installation, please visit the detailed CPAN module installation guide.