ArgumentError- Could not parse PKey- no start line


After updating my net-ssh gem to 2.6.x I started getting this error message from Capistrano:

ArgumentError: Could not parse PKey: no start line

The private key in question was completely fine though, given that it had been working in several other applications, including openssh itself, for quite some time. There seem to be some weird issues with net-ssh 2.6.x and Capistrano at the moment, and so I simply downgraded to v2.5.2 and everything worked fine once again:

gem uninstall net-ssh
gem install net-ssh -v 2.5.2

Keep deploying :)