Beefy Boxes and Bandwidth Generously Provided by pair Networks
Think about Loose Coupling
 
PerlMonks  

Re^3: Can't locate Test/JSON.pm in @INC

by taint (Chaplain)
on Dec 27, 2013 at 17:49 UTC ( #1068554=note: print w/ replies, xml ) Need Help??


in reply to Re^2: Can't locate Test/JSON.pm in @INC
in thread Can't locate Test/JSON.pm in @INC

That's why I indicated that using a directory relative would make it easier to diagnose/implement.

If both of your custom JSON modules declare

package JSON;
You should, as toolic initially asserted, be able to use
use lib '/abc/xyz';
or
use lib ('/abc/xyz');
then
use JSON; use Test::JSON
because as I noted earlier; the double-colon is a path/directory separator. Meaning; Test::JSON == Test/JSON.

You might also try

use lib '/abc/xyz/';
as that negates the need to preface a slash before your custom modules.

In any case; you must ensure that the path to your custom JSON modules preceeds (is before) your system Perl module path.
That's why you see reference to conflicts within the system's perl, in the latest error you quoted.

--Chris

λɐp ʇɑəɹ⅁ ɐ əʌɐɥ puɐ ʻꜱdləɥ ꜱᴉɥʇ ədoH


Comment on Re^3: Can't locate Test/JSON.pm in @INC
Select or Download Code
Re^4: Can't locate Test/JSON.pm in @INC
by zuverlassig (Novice) on Dec 27, 2013 at 18:05 UTC
    Thanks Chris, that worked! I cant believe what a stupid mistake I was making. And yeah toolic was right.
      Good news. Glad you were able to get it right. :)

      --Chris

      λɐp ʇɑəɹ⅁ ɐ əʌɐɥ puɐ ʻꜱdləɥ ꜱᴉɥʇ ədoH

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1068554]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others exploiting the Monastery: (12)
As of 2014-07-25 19:15 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    My favorite superfluous repetitious redundant duplicative phrase is:









    Results (174 votes), past polls