#1086277 jarchivelib: FTBFS: java.lang.NullPointerException: Cannot invoke "java.io.OutputStream.flush()" because "this.out" is null

#1086277#5
Date:
2024-10-29 18:46:27 UTC
From:
To:
Dear maintainer:

During a rebuild of all packages in unstable, your package failed to build:
--------------------------------------------------------------------------------
[...]
  debian/rules binary
dh binary
    dh_update_autotools_config
    dh_autoreconf
    dh_auto_configure
	mh_patchpoms -plibjarchivelib-java --debian-build --keep-pom-version --maven-repo=/<<PKGBUILDDIR>>/debian/maven-repo
    dh_auto_build
	/usr/lib/jvm/default-java/bin/java -noverify -cp /usr/share/maven/boot/plexus-classworlds-2.x.jar -Dmaven.home=/usr/share/maven -Dmaven.multiModuleProjectDirectory=/<<PKGBUILDDIR>> -Dclassworlds.conf=/etc/maven/m2-debian.conf org.codehaus.plexus.classworlds.launcher.Launcher -s/etc/maven/settings-debian.xml -Ddebian.dir=/<<PKGBUILDDIR>>/debian -Dmaven.repo.local=/<<PKGBUILDDIR>>/debian/maven-repo --batch-mode package -DskipTests -Dnotimestamp=true -Dlocale=en_US
OpenJDK 64-Bit Server VM warning: Options -Xverify:none and -noverify were deprecated in JDK 13 and will likely be removed in a future release.
[INFO] Scanning for projects...
[INFO]
[INFO] ----------------------< org.rauschig:jarchivelib >----------------------
[INFO] Building Java archiving library 1.2.0
[INFO]   from pom.xml
[INFO] -------------------------------[ bundle ]-------------------------------
[INFO]
[INFO] --- maven-resources-plugin:3.3.1:resources (default-resources) @ jarchivelib ---
[WARNING] Using platform encoding (UTF-8 actually) to copy filtered resources, i.e. build is platform dependent!
[INFO] skip non existing resourceDirectory /<<PKGBUILDDIR>>/src/main/resources
[INFO]
[INFO] --- maven-compiler-plugin:3.13.0:compile (default-compile) @ jarchivelib ---
[INFO] Recompiling the module because of changed source code.
[WARNING] File encoding has not been set, using platform encoding UTF-8, i.e. build is platform dependent!
[INFO] Compiling 20 source files with javac [debug target 1.7] to target/classes
Use of target 1.7 is no longer supported, switching to 8
Use of source 1.7 is no longer supported, switching to 8
[WARNING] bootstrap class path not set in conjunction with -source 8
[WARNING] source value 8 is obsolete and will be removed in a future release
[WARNING] target value 8 is obsolete and will be removed in a future release
[WARNING] To suppress warnings about obsolete options, use -Xlint:-options.
[INFO] /<<PKGBUILDDIR>>/src/main/java/org/rauschig/jarchivelib/SevenZArchiver.java: Some input files use or override a deprecated API.
[INFO] /<<PKGBUILDDIR>>/src/main/java/org/rauschig/jarchivelib/SevenZArchiver.java: Recompile with -Xlint:deprecation for details.
[INFO] /<<PKGBUILDDIR>>/src/main/java/org/rauschig/jarchivelib/CommonsArchiver.java: /<<PKGBUILDDIR>>/src/main/java/org/rauschig/jarchivelib/CommonsArchiver.java uses unchecked or unsafe operations.
[INFO] /<<PKGBUILDDIR>>/src/main/java/org/rauschig/jarchivelib/CommonsArchiver.java: Recompile with -Xlint:unchecked for details.
[INFO]
[INFO] --- maven-resources-plugin:3.3.1:testResources (default-testResources) @ jarchivelib ---
[WARNING] Using platform encoding (UTF-8 actually) to copy filtered resources, i.e. build is platform dependent!
[INFO] Copying 21 resources from src/test/resources to target/test-classes
[INFO]
[INFO] --- maven-compiler-plugin:3.13.0:testCompile (default-testCompile) @ jarchivelib ---
[INFO] Recompiling the module because of changed dependency.
[WARNING] File encoding has not been set, using platform encoding UTF-8, i.e. build is platform dependent!
[INFO] Compiling 17 source files with javac [debug target 1.7] to target/test-classes
Use of target 1.7 is no longer supported, switching to 8
Use of source 1.7 is no longer supported, switching to 8
[WARNING] bootstrap class path not set in conjunction with -source 8
[WARNING] source value 8 is obsolete and will be removed in a future release
[WARNING] target value 8 is obsolete and will be removed in a future release
[WARNING] To suppress warnings about obsolete options, use -Xlint:-options.
[INFO] /<<PKGBUILDDIR>>/src/test/java/org/rauschig/jarchivelib/Archiver7zTest.java: /<<PKGBUILDDIR>>/src/test/java/org/rauschig/jarchivelib/Archiver7zTest.java uses or overrides a deprecated API.
[INFO] /<<PKGBUILDDIR>>/src/test/java/org/rauschig/jarchivelib/Archiver7zTest.java: Recompile with -Xlint:deprecation for details.
[INFO]
[INFO] --- maven-surefire-plugin:2.22.3:test (default-test) @ jarchivelib ---
[INFO] Tests are skipped.
[INFO]
[INFO] --- maven-bundle-plugin:3.5.1:bundle (default-bundle) @ jarchivelib ---
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time:  3.122 s
[INFO] Finished at: 2024-10-29T07:48:40Z
[INFO] ------------------------------------------------------------------------
    dh_auto_test
	/usr/lib/jvm/default-java/bin/java -noverify -cp /usr/share/maven/boot/plexus-classworlds-2.x.jar -Dmaven.home=/usr/share/maven -Dmaven.multiModuleProjectDirectory=/<<PKGBUILDDIR>> -Dclassworlds.conf=/etc/maven/m2-debian.conf org.codehaus.plexus.classworlds.launcher.Launcher -s/etc/maven/settings-debian.xml -Ddebian.dir=/<<PKGBUILDDIR>>/debian -Dmaven.repo.local=/<<PKGBUILDDIR>>/debian/maven-repo --batch-mode test
OpenJDK 64-Bit Server VM warning: Options -Xverify:none and -noverify were deprecated in JDK 13 and will likely be removed in a future release.
[INFO] Scanning for projects...
[INFO]
[INFO] ----------------------< org.rauschig:jarchivelib >----------------------
[INFO] Building Java archiving library 1.2.0
[INFO]   from pom.xml
[INFO] -------------------------------[ bundle ]-------------------------------
[INFO]
[INFO] --- maven-resources-plugin:3.3.1:resources (default-resources) @ jarchivelib ---
[WARNING] Using platform encoding (UTF-8 actually) to copy filtered resources, i.e. build is platform dependent!
[INFO] skip non existing resourceDirectory /<<PKGBUILDDIR>>/src/main/resources
[INFO]
[INFO] --- maven-compiler-plugin:3.13.0:compile (default-compile) @ jarchivelib ---
[INFO] Nothing to compile - all classes are up to date.
[INFO]
[INFO] --- maven-resources-plugin:3.3.1:testResources (default-testResources) @ jarchivelib ---
[WARNING] Using platform encoding (UTF-8 actually) to copy filtered resources, i.e. build is platform dependent!
[INFO] Copying 21 resources from src/test/resources to target/test-classes
[INFO]
[INFO] --- maven-compiler-plugin:3.13.0:testCompile (default-testCompile) @ jarchivelib ---
[INFO] Nothing to compile - all classes are up to date.
[INFO]
[INFO] --- maven-surefire-plugin:2.22.3:test (default-test) @ jarchivelib ---
[INFO]
[INFO] -------------------------------------------------------
[INFO]  T E S T S
[INFO] -------------------------------------------------------
[INFO] Running org.rauschig.jarchivelib.CompressorBzip2Test
[INFO] Tests run: 13, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.196 s - in org.rauschig.jarchivelib.CompressorBzip2Test
[INFO] Running org.rauschig.jarchivelib.ArchiveTarBzip2Test
[INFO] Tests run: 20, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.253 s - in org.rauschig.jarchivelib.ArchiveTarBzip2Test
[INFO] Running org.rauschig.jarchivelib.ExtractPermissionsTest
[INFO] Tests run: 8, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.138 s - in org.rauschig.jarchivelib.ExtractPermissionsTest
[INFO] Running org.rauschig.jarchivelib.CompressorXzTest
[INFO] Tests run: 13, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.089 s - in org.rauschig.jarchivelib.CompressorXzTest
[INFO] Running org.rauschig.jarchivelib.PosixFilePermissionsMapperTest
[INFO] Tests run: 7, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.015 s - in org.rauschig.jarchivelib.PosixFilePermissionsMapperTest
[INFO] Running org.rauschig.jarchivelib.CompressorGzipTest
[INFO] Tests run: 13, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.028 s - in org.rauschig.jarchivelib.CompressorGzipTest
[INFO] Running org.rauschig.jarchivelib.ArchiverTarTest
[INFO] Tests run: 21, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.103 s - in org.rauschig.jarchivelib.ArchiverTarTest
[INFO] Running org.rauschig.jarchivelib.ArchiverCpioTest
[INFO] Tests run: 20, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.117 s - in org.rauschig.jarchivelib.ArchiverCpioTest
[INFO] Running org.rauschig.jarchivelib.ArchiverJarTest
[INFO] Tests run: 20, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.12 s - in org.rauschig.jarchivelib.ArchiverJarTest
[INFO] Running org.rauschig.jarchivelib.FileTypeTest
[INFO] Tests run: 4, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.005 s - in org.rauschig.jarchivelib.FileTypeTest
[INFO] Running org.rauschig.jarchivelib.Archiver7zTest
[ERROR] Tests run: 20, Failures: 0, Errors: 3, Skipped: 0, Time elapsed: 0.541 s <<< FAILURE! - in org.rauschig.jarchivelib.Archiver7zTest
[ERROR] create_recursiveDirectory_withoutFileExtension_properlyCreatesArchive(org.rauschig.jarchivelib.Archiver7zTest)  Time elapsed: 0.15 s  <<< ERROR!
java.lang.NullPointerException: Cannot invoke "java.io.OutputStream.flush()" because "this.out" is null

[ERROR] create_multipleSourceFiles_properlyCreatesArchive(org.rauschig.jarchivelib.Archiver7zTest)  Time elapsed: 0.136 s  <<< ERROR!
java.lang.NullPointerException: Cannot invoke "java.io.OutputStream.flush()" because "this.out" is null

[ERROR] create_recursiveDirectory_withFileExtension_properlyCreatesArchive(org.rauschig.jarchivelib.Archiver7zTest)  Time elapsed: 0.149 s  <<< ERROR!
java.lang.NullPointerException: Cannot invoke "java.io.OutputStream.flush()" because "this.out" is null

[INFO] Running org.rauschig.jarchivelib.ArchiverZipTest
[INFO] Tests run: 20, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.1 s - in org.rauschig.jarchivelib.ArchiverZipTest
[INFO] Running org.rauschig.jarchivelib.FactoryTest
[INFO] Tests run: 15, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.02 s - in org.rauschig.jarchivelib.FactoryTest
[INFO] Running org.rauschig.jarchivelib.ArchiverTarGzTest
[INFO] Tests run: 21, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.077 s - in org.rauschig.jarchivelib.ArchiverTarGzTest
[INFO]
[INFO] Results:
[INFO]
[ERROR] Errors:
[ERROR]   Archiver7zTest>AbstractArchiverTest.create_multipleSourceFiles_properlyCreatesArchive:96 » NullPointer
[ERROR]   Archiver7zTest>AbstractArchiverTest.create_recursiveDirectory_withFileExtension_properlyCreatesArchive:83 » NullPointer
[ERROR]   Archiver7zTest>AbstractArchiverTest.create_recursiveDirectory_withoutFileExtension_properlyCreatesArchive:109 » NullPointer
[INFO]
[ERROR] Tests run: 215, Failures: 0, Errors: 3, Skipped: 0
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time:  33.978 s
[INFO] Finished at: 2024-10-29T07:49:15Z
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.22.3:test (default-test) on project jarchivelib: There are test failures.
[ERROR]
[ERROR] Please refer to /<<PKGBUILDDIR>>/target/surefire-reports for the individual test results.
[ERROR] Please refer to dump files (if any exist) [date].dump, [date]-jvmRun[N].dump and [date].dumpstream.
[ERROR] -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException
dh_auto_test: error: /usr/lib/jvm/default-java/bin/java -noverify -cp /usr/share/maven/boot/plexus-classworlds-2.x.jar -Dmaven.home=/usr/share/maven -Dmaven.multiModuleProjectDirectory=/<<PKGBUILDDIR>> -Dclassworlds.conf=/etc/maven/m2-debian.conf org.codehaus.plexus.classworlds.launcher.Launcher -s/etc/maven/settings-debian.xml -Ddebian.dir=/<<PKGBUILDDIR>>/debian -Dmaven.repo.local=/<<PKGBUILDDIR>>/debian/maven-repo --batch-mode test returned exit code 1
make: *** [debian/rules:4: binary] Error 25
dpkg-buildpackage: error: debian/rules binary subprocess returned exit status 2
--------------------------------------------------------------------------------

The above is just how the build ends and not necessarily the most relevant part.
If required, the full build log is available here:

https://people.debian.org/~sanvila/build-logs/202410/

About the archive rebuild: The build was made on virtual machines from AWS,
using sbuild and a reduced chroot with only build-essential packages.

If you could not reproduce the bug please contact me privately, as I
am willing to provide ssh access to a virtual machine where the bug is
fully reproducible.

If this is really a bug in one of the build-depends, please use
reassign and affects, so that this is still visible in the BTS web
page for this package.

Thanks.

#1086277#12
Date:
2026-10-18 09:56:36 UTC
From:
To:
Hello,

Bug #1086277 in jarchivelib reported by you has been fixed in the
Git repository and is awaiting an upload. You can see the commit
message below and you can check the diff of the fix at:

https://salsa.debian.org/java-team/jarchivelib/-/commit/856a5a74cfcf04679051529b845bb682c2be04fb

(this message was generated automatically)
-- 
Greetings

https://bugs.debian.org/1086277

#1086277#19
Date:
2026-10-18 10:22:43 UTC
From:
To:
We believe that the bug you reported is fixed in the latest version of
jarchivelib, which is due to be installed in the Debian FTP archive.

A summary of the changes between this version and the previous one is
attached.

Thank you for reporting the bug, which will now be closed.  If you
have further comments please address them to 1086277@bugs.debian.org,
and the maintainer will reopen the bug report if appropriate.

Debian distribution maintenance software
pp.
Emmanuel Bourg <ebourg@apache.org> (supplier of updated jarchivelib package)

(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing ftpmaster@ftp-master.debian.org)
Format: 1.8
Date: Sun, 18 Oct 2026 11:51:16 +0200
Source: jarchivelib
Architecture: source
Version: 1.2.0-3
Distribution: unstable
Urgency: medium
Maintainer: Debian Java Maintainers <pkg-java-maintainers@lists.alioth.debian.org>
Changed-By: Emmanuel Bourg <ebourg@apache.org>
Closes: 1086277
Changes:
 jarchivelib (1.2.0-3) unstable; urgency=medium
 .
   * Team upload.
   * Fixed the build failure with commons-compress 1.27 (Closes: #1086277)
   * Converted debian/watch to the version 5 format
   * Standards-Version updated to 4.7.4
   * Removed the Priority field
   * Removed the Rules-Requires-Root field
Checksums-Sha1:
 93cc9501de6c8daa1108fc1e9b926fe5d7bfb5d7 2029 jarchivelib_1.2.0-3.dsc
 f3c24c341f023f374500c0e63efc0729e99f678e 2976 jarchivelib_1.2.0-3.debian.tar.xz
 2e0e68454f8ace200bbf13a252623fc5a8ebe13a 15719 jarchivelib_1.2.0-3_source.buildinfo
Checksums-Sha256:
 bafa30c8c5bfd30c8726ea808958fec93e8d6e3ab9198540f5e58fac4e837241 2029 jarchivelib_1.2.0-3.dsc
 4faaa866dd05b8668accd38d1e815f17c586675d138a5fe26b9fef296fab8224 2976 jarchivelib_1.2.0-3.debian.tar.xz
 59b5a0887171da173158bb93011db203a84433a35719d661695ea926d6cb6261 15719 jarchivelib_1.2.0-3_source.buildinfo
Files:
 7c0a1df5293afca825723ce412f13836 2029 java optional jarchivelib_1.2.0-3.dsc
 a538004ab4339e8a149c1dcdd8417e00 2976 java optional jarchivelib_1.2.0-3.debian.tar.xz
 d540aaab1d7cf670b8f2ae5d067c347d 15719 java optional jarchivelib_1.2.0-3_source.buildinfo
-----BEGIN PGP SIGNATURE-----

iQJGBAEBCgAwFiEEuM5N4hCA3PkD4WxA9RPEGeS50KwFAmrUl84SHGVib3VyZ0Bh
cGFjaGUub3JnAAoJEPUTxBnkudCsnHIP/3bluQlkaa7XTl5GZSJSwPYs7QDaaYus
0Jw4S5/sIKfqjKInBxsgJvkTSa4Cfrt9lWfG/EwqWWAFy2hhP7D2k0WQM6FhwKSE
4Yjaqxsd59eef26fxqzFqBszSZuouhgf97ge8Li8iEQZ5hVQvPTNcFOBDBY6wwig
0zDGAnHyMfwsrPku+QizN+b/40j1Bc4yx6aNaGHqVvb3+8/i6YvnpTkgzzdjXv2R
OVsp2IcTstRZuemHD6B3kx7ja7EJMHXW6jhdYF0mGXV9mUykB6tGprDcWxy8IyJf
6/lb+canmY5/MAo61f63+QgKXo1J9HfzdEGsWgWaJt6YggG/E3ak4Qq19+AdrvsE
bTTTQ1BIi12slCk9SzfCKmkghEhdNJbpHRMAj5hmgQOmL4haAbBbCW4M4BcoHVT9
kwewCik06xvxusrw3eZvxyV5trFiGO0LO9Y2ltrEmrZcjhvBYSI4oFEkNpDIx482
4fhhgR9MXj6kcFs2Eh1kXNJJFmjCgrKzIB9ZZzzJQHSaPiWMo5JWNyIlc3wOmElB
0Y47QpV8C9uznqL0+c0ztaJ8z0jbOsKVmHrhOogdMuKt3lT7zXBmdVAB3PeshMyv
2qxOhHLIjFnyFga5nos8gV/sFyxF08hBtrDslZ84063dZDHvwnxReD2dUtAG2nKP
D25NGpnwtilS
=UQFE
-----END PGP SIGNATURE-----