As shown in stackdump_1.txt (attached), CommitBuild explodes trying to write out a file that contains data that is not valid UTF8, because after dzil 5, ->content dynamically decodes based on the value of ->encoding, which, if not specified, defaults to UTF-8.
So, after using the [Encoding] plugin to specify the given file is in fact, bytes, not utf8 data, ->content then explodes because ->content cannot be decoded from a file that is encoded in bytes.
stackdump_2.txt (attached) shows the error given after telling dzil that the file is bytes.
I believe all that is necessary is :
- my ( $name, $content ) = ( $file->name, $file->content );
+ my ( $name, $content ) = ( $file->name, $file->encoded_content );
in CommitBuild.pm and things should return to working on Dzil 5.
[DZ] beginning to build GraphViz2-Gentoo-Dependency
[DZ] guessing dist's main_module is lib/GraphViz2/Gentoo/Dependency.pm
[DZ] extracting distribution abstract from lib/GraphViz2/Gentoo/Dependency.pm
[@Author::KENTNL/GithubMeta] A remote named 'origin' was specified, but does not appear to exist.
[@Author::KENTNL/GithubMeta] skipping meta.resources.repository creation
[Name] couldn't find abstract in lib/GraphViz2/Gentoo/Dependency/AssocCache.pm
[Name] couldn't find abstract in lib/GraphViz2/Gentoo/Dependency/Phase.pm
[Name] couldn't find abstract in lib/GraphViz2/Gentoo/Dependency/IdCache.pm
[@Author::KENTNL/ReadmeAnyFromPod] Override README.mkdn in root
[DZ] writing GraphViz2-Gentoo-Dependency in GraphViz2-Gentoo-Dependency-0.001000
Could not decode UTF-8 example/gv2.dot.xz; encoded_content set by @Author::KENTNL/Git::GatherDir (Dist::Zilla::Plugin::Git::GatherDir line 81); error was: utf8 "\xFD" does not map to Unicode at /home/kent/perl5/perlbrew/perls/perl-5.19.3/lib/site_perl/5.19.3/x86_64-linux/Encode.pm line 175.
at /home/kent/perl5/perlbrew/perls/perl-5.19.3/lib/site_perl/5.19.3/Dist/Zilla/Role/File.pm line 79.
Dist::Zilla::Role::File::_throw(Dist::Zilla::File::OnDisk=HASH(0x2d51540), "decode UTF-8", "utf8 \"\\xFD\" does not map to Unicode at /home/kent/perl5/perlb"...) called at /home/kent/perl5/perlbrew/perls/perl-5.19.3/lib/site_perl/5.19.3/Dist/Zilla/Role/File.pm line 71
Dist::Zilla::Role::File::catch {...} ("utf8 \"\\xFD\" does not map to Unicode at /home/kent/perl5/perlb"...) called at /home/kent/perl5/perlbrew/perls/perl-5.19.3/lib/site_perl/5.19.3/Try/Tiny.pm line 106
Try::Tiny::try(CODE(0x69e6928), Try::Tiny::Catch=REF(0x68e8e68)) called at /home/kent/perl5/perlbrew/perls/perl-5.19.3/lib/site_perl/5.19.3/Dist/Zilla/Role/File.pm line 71
Dist::Zilla::Role::File::_decode(Dist::Zilla::File::OnDisk=HASH(0x2d51540), "\x{fd}7zXZ\x{0}\x{0}\x{4}\x{e6}\x{d6}\x{b4}F\x{2}\x{0}!\x{1} \x{0}\x{0}\x{0}\x{9}\x{88}\x{a5}v\x{e0}d\x{bf}\x{16}d\x{2}\x{0}2\x{1b}\x{1c}Y\x{1a}\x{d6}\x{7}\x{ff}\x{fa}<\x{1}\x{8f}\x{ec}\x{81}+\x{c}\x{9c}\x{93}5\x{85}\x{fb}d\x{e3}\x{98}\x{db}\x{de}u\x{e8}\x{98}\x{fe}"...) called at /home/kent/perl5/perlbrew/perls/perl-5.19.3/lib/site_perl/5.19.3/Dist/Zilla/Role/MutableFile.pm line 44
Dist::Zilla::Role::MutableFile::content(Dist::Zilla::File::OnDisk=HASH(0x2d51540)) called at /home/kent/perl5/perlbrew/perls/perl-5.19.3/lib/site_perl/5.19.3/Dist/Zilla/Plugin/Git/CommitBuild.pm line 117
Dist::Zilla::Plugin::Git::CommitBuild::_commit_build(Dist::Zilla::Plugin::Git::CommitBuild=HASH(0x51798f0), HASH(0x60a2aa0), "build/%b", "Build results of %h (on %b)") called at /home/kent/perl5/perlbrew/perls/perl-5.19.3/lib/site_perl/5.19.3/Dist/Zilla/Plugin/Git/CommitBuild.pm line 97
Dist::Zilla::Plugin::Git::CommitBuild::after_build(Dist::Zilla::Plugin::Git::CommitBuild=HASH(0x51798f0), HASH(0x60a2aa0)) called at /home/kent/perl5/perlbrew/perls/perl-5.19.3/lib/site_perl/5.19.3/Dist/Zilla/Dist/Builder.pm line 291
Dist::Zilla::Dist::Builder::build_in(Dist::Zilla::Dist::Builder=HASH(0x2dbc948), undef) called at /home/kent/perl5/perlbrew/perls/perl-5.19.3/lib/site_perl/5.19.3/Dist/Zilla/Dist/Builder.pm line 315
Dist::Zilla::Dist::Builder::ensure_built_in(Dist::Zilla::Dist::Builder=HASH(0x2dbc948)) called at /home/kent/perl5/perlbrew/perls/perl-5.19.3/lib/site_perl/5.19.3/Dist/Zilla/Dist/Builder.pm line 305
Dist::Zilla::Dist::Builder::ensure_built(Dist::Zilla::Dist::Builder=HASH(0x2dbc948)) called at /home/kent/perl5/perlbrew/perls/perl-5.19.3/lib/site_perl/5.19.3/Dist/Zilla/Dist/Builder.pm line 342
Dist::Zilla::Dist::Builder::build_archive(Dist::Zilla::Dist::Builder=HASH(0x2dbc948)) called at /home/kent/perl5/perlbrew/perls/perl-5.19.3/lib/site_perl/5.19.3/Dist/Zilla/App/Command/build.pm line 30
Dist::Zilla::App::Command::build::execute(Dist::Zilla::App::Command::build=HASH(0x22de878), Getopt::Long::Descriptive::Opts::__OPT__::2=HASH(0x2408500), ARRAY(0xbe3068)) called at /home/kent/perl5/perlbrew/perls/perl-5.19.3/lib/site_perl/5.19.3/App/Cmd.pm line 282
App::Cmd::execute_command(Dist::Zilla::App=HASH(0x183c4e8), Dist::Zilla::App::Command::build=HASH(0x22de878), Getopt::Long::Descriptive::Opts::__OPT__::2=HASH(0x2408500)) called at /home/kent/perl5/perlbrew/perls/perl-5.19.3/lib/site_perl/5.19.3/App/Cmd.pm line 210
App::Cmd::run("Dist::Zilla::App") called at /home/kent/perl5/perlbrew/perls/perl-5.19.3/bin/dzil line 15