Description
On Thu, Sep 09, 2021 at 03:07:46AM -0700, Nicholas Clark wrote:
xs_handshake() makes two different comparisons that on failure are reported
as "got handshake key %p, needed %p", with opaque hexadecimal values.
Personally I'd go further. This message most often appears when modules
built with one version of perl are loaded by a different perl binary. This
is a fairly common occurrence (e.g. if PERL5LIB is set), and the message
is horrible. It's going on about a 'handshake' having the wrong hex key,
and just scares the user without saying anything useful.
Personally I think the error message should:
-
remove any mention of 'handshake' (it makes it sound like some sort of
network error); -
should be a lot more verbose, suggesting (where relevant) that its
likely a mismatch between perl version/build and module build, and
displaying (where relevant) the @inc path and relevant PERL env vars.
So, a bit like how we improved the 'module not found' error:Can't locate Foo/Bar.pm in @inc (you may need to install the Foo::Bar
module) @.*** contains: ....). -
If the hex values have any further useful info, they should be
symbolically decoded if possible.
--
In my day, we used to edit the inodes by hand. With magnets.
Originally posted by @iabyn in #19111 (comment)