December 1, 2011

152 words 1 min read

Error 400 on SERVER: Puppet::Parser::AST::Resource failed with error ArgumentError: Invalid resource type

At the office I’ve been working to move our operations infrastructure into Puppet. Since I’m fairly new to puppetizing, I’ve been spending a lot of time with puppet. During one of my recent trial runs, I got the following (cryptic) error message:

Error 400 on SERVER: Puppet::Parser::AST::Resource failed with error ArgumentError: Invalid resource type

What. The. Hell?

This strange error message has been reported as

Bug #5368 and the comments help a little bit. I’ll explain in short: You’re trying to call a class that does not exist. Either this means you misspelled the class name where you called it, misspelled the name where you defined it… or in my case… I forgot to include the file where I defined the class.

It’s simple to fix, but really obnoxious when the error messages don’t mean jack squat to you. Hopefully, they’ll fix the bug soon and I can deprecate this blog entry.