in reply to Constructing a hash

You didn't declare all the variables: %Hash, $key. Your error message on line 3 is missing the closing quote. You didn't use Data::Dumper (for Dumper). Check the return value (and $! if it fails) of the second open call.

And then, at least, you should see an error message, or a file with at least an empty hash in it.

Oh, and you probably want to chomp each line.

Is there a reason why you're not seeing existing error messages, for example for the current failed compilation? Because that's what it looks like to me.