Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>Same OS? Same version of Perl? Hmm....</p> <p>I've seen this error message when there's an existing file in the path it's trying to create. For example, I try to create the directory <code>foo/bar/bar/foo</code>, but there's a file <code>foo/bar/bar</code>, the <code>mkpath</code> will fail with the error message you said.</p> <p>Is it possible that this was the case? Try this small test program on your computer:</p> <p>Run the following command on both systems:</p> <pre><code>$ perldoc -lm File::Path </code></pre> <p>This will print out the <em>location</em> of the File::Path module that's being included. My suspicion is that you're not executing the File::Path module you think you are.</p> <p>After you determine the actual modules being used, check to see if the two modules agree. Also, while you're at it, do a <code>perl -V</code> (that's a capital <code>V</code>). That will give you a lot of information about your Perl installations including libpath, posix is used. It's very possible that you compiled the Perl with the same source code, but the compile flags differed.</p> <p>Try this test program on both system:</p> <pre><code>use strict; use warnings; use File::Path; open (FOO, "&gt;foo") or die qq(Things really aren't going your way\n); print FOO "THIS\n"; close FOO; if (my $value = mkpath "foo/foo/bar/foo") { print "It worked: $value !\n"; } else { print "It didn't: $value !\n"; } print "And the program continues\n"; </code></pre> <p>This <strong>should</strong> fail because I'm creating a file <code>foo</code> and then trying to make a path <code>foo/boo/bar/foo</code>. In fact, I get the following error:</p> <pre><code>mkdir foo: File exists at ./test.pl line 11 </code></pre> <p>One of these things will give us a clue what's going on.</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload