Added
This commit is contained in:
@@ -0,0 +1,36 @@
|
||||
From 21a92b08d30cd4758fefe1706eb96af30082cb7b Mon Sep 17 00:00:00 2001
|
||||
From: Kent Fredric <kentnl@gentoo.org>
|
||||
Date: Sat, 8 Aug 2020 05:25:21 +1200
|
||||
Subject: Fix INC traversal breakage with non-string objects in INC
|
||||
|
||||
As `$root` is a Path object, and because there are defined mechanisms
|
||||
for handling objects in `@INC` traversal, this object being added to
|
||||
`@INC` can cause panics when the perl interpreter tries to call a method
|
||||
that doesn't exist, violating the API.
|
||||
|
||||
And this in turn makes various authordeps appear missing when they're
|
||||
present, due to suppression of the error occurring from the above.
|
||||
|
||||
Forcing stringification of the path object mitigates this issue.
|
||||
|
||||
Bug: https://github.com/rjbs/Dist-Zilla/issues/660
|
||||
---
|
||||
lib/Dist/Zilla/Util/AuthorDeps.pm | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/lib/Dist/Zilla/Util/AuthorDeps.pm b/lib/Dist/Zilla/Util/AuthorDeps.pm
|
||||
index cbca1c7..603d67b 100644
|
||||
--- a/lib/Dist/Zilla/Util/AuthorDeps.pm
|
||||
+++ b/lib/Dist/Zilla/Util/AuthorDeps.pm
|
||||
@@ -113,7 +113,7 @@ sub extract_author_deps {
|
||||
: do {
|
||||
my $m = $_;
|
||||
! eval {
|
||||
- local @INC = @INC; push @INC, $root;
|
||||
+ local @INC = @INC; push @INC, "$root";
|
||||
# This will die if module is missing
|
||||
Module::Runtime::require_module($m);
|
||||
my $v = $vermap->{$m};
|
||||
--
|
||||
2.28.0
|
||||
|
||||
Reference in New Issue
Block a user