Exceptions in Perl, Then and Now

In re-factoring ModExec, I have started with the exceptions. I’m debating how I used to do them. When I first started I used Error qw/:try/ and Error::Simple for exceptions. I still think I will, it looks like it’s still being well-maintained by Shlomi Fish (see here).

I think that the piece I will bite off first is to get some test coverage around my exceptions and add documentation. They’re not much more than what you get with Error::Simple, but there’s some stuff in there for stack dumps and things like that.

Goals for this first pass are:

  1. Pass a `perlcritic -3` for all exception code
  2. Add POD for all exception code
  3. Add a test for at least some of the methods (more tests will be added later)

Before and After

Here are some GitHub links:

Re-factoring Your Old Projects

Once upon a time I maintained a very small, lightweight framework to allow for Perl interfaces to be integrated with directly from client-side JavaScript. I called this framework ModExec. This framework took into account the various security implications which I’m sure are already sounding the klaxons in your brain. I even managed to get this framework into a state where I was proud enough to present it to the Perl Special Interest Group in Lisle, IL in 2006. Man, those were the days… and that was 7 years ago. Continue reading Re-factoring Your Old Projects