in reply to Re: Dynamically creat Packages
in thread Dynamically create Packages

Add this line, after the eval "use $package" statement. (Note: You did add a use strict and use English to your script right?).

warn "use error: " . $EVAL_ERROR . "\n";

It should complain twice about not being able to find the package. Once for each call. If you add a third call it would complain a third time, etc... Each eval statement is kinda slow. If there are a large enough transactions it can slow the system significantly.

What kyle was suggesting is spoofing the load in the %INC variable so I only have it complain once and eval once for a given package. Does that help?