commons-compress icon indicating copy to clipboard operation
commons-compress copied to clipboard

COMPRESS-614: Use FileTime in SevenZArchiveEntry

Open andrebrait opened this issue 2 years ago • 10 comments

I also included a deprecation notice I missed from COMPRESS-612 and I moved some common paths between Zip and SevenZip to ZipUtil (and those will also be used for COMPRESS-613).

andrebrait avatar Mar 21 '22 15:03 andrebrait

@andrebrait @garydgregory Does apache.compress support creating password protected archive files? I'm using implementation 'org.apache.commons:commons-compress:1.21' in my Android project.

(NOT RELATED TO YOUR PR)

asthagarg2428 avatar Mar 24 '22 03:03 asthagarg2428

@andrebrait @garydgregory Does apache.compress support creating password protected archive files? I'm using implementation 'org.apache.commons:commons-compress:1.21' in my Android project.

(NOT RELATED TO YOUR PR)

Pretty sure it does not. It supports opening 7z protected archives, but I don't think it supports creating them in any way, and it does not support either when it comes to zip.

andrebrait avatar Mar 24 '22 07:03 andrebrait

@garydgregory waiting for this to be merged so I can send the changes for COMPRESS-613

andrebrait avatar Apr 04 '22 15:04 andrebrait

Hi @andrebrait Sorry about the noise on git master but our build was broken due to some mistakes in porting from JUnit 4 to 5. Would you mind rebasing on master?

garydgregory avatar May 06 '22 11:05 garydgregory

@garydgregory done ;)

andrebrait avatar May 10 '22 15:05 andrebrait

@garydgregory I'm sorry to bump this, but just wanted to check if we could merge this before 1.22. I still have another improvement around time handling for Zip files in the pipeline, but this has to go first. I have reviewed this myself and I couldn't find anything that could hint into a regression or something, but let me know if you need any help and/or explanation of what something is doing here.

andrebrait avatar Jun 09 '22 12:06 andrebrait

I will review it this weekend.

garydgregory avatar Jun 09 '22 13:06 garydgregory

Codecov Report

Merging #256 (f0dae66) into master (7440afc) will increase coverage by 0.08%. The diff coverage is 88.37%.

@@             Coverage Diff              @@
##             master     #256      +/-   ##
============================================
+ Coverage     80.08%   80.17%   +0.08%     
- Complexity     6608     6644      +36     
============================================
  Files           339      340       +1     
  Lines         25205    25235      +30     
  Branches       4151     4148       -3     
============================================
+ Hits          20186    20232      +46     
+ Misses         3422     3411      -11     
+ Partials       1597     1592       -5     
Impacted Files Coverage Δ
...che/commons/compress/archivers/zip/X000A_NTFS.java 66.66% <79.16%> (+5.79%) :arrow_up:
...ns/compress/archivers/sevenz/SevenZOutputFile.java 96.94% <87.50%> (+0.49%) :arrow_up:
.../compress/archivers/sevenz/SevenZArchiveEntry.java 84.67% <88.46%> (+2.85%) :arrow_up:
...ommons/compress/archivers/tar/TarArchiveEntry.java 71.71% <100.00%> (ø)
...a/org/apache/commons/compress/utils/TimeUtils.java 100.00% <100.00%> (ø)
...apache/commons/compress/archivers/zip/ZipFile.java 78.24% <0.00%> (-0.54%) :arrow_down:
...e/commons/compress/harmony/pack200/ClassBands.java 82.09% <0.00%> (-0.06%) :arrow_down:
...ache/commons/compress/harmony/pack200/BandSet.java 74.78% <0.00%> (ø)
...ress/harmony/pack200/AttributeDefinitionBands.java 73.91% <0.00%> (ø)
...compressors/bzip2/BZip2CompressorOutputStream.java 92.60% <0.00%> (+0.01%) :arrow_up:
... and 5 more

:mega: We’re building smart automated test selection to slash your CI/CD build times. Learn more

codecov-commenter avatar Sep 16 '22 16:09 codecov-commenter

@garydgregory I'm finally back to working on this. I see some missed lines in the coverage report. Gonna add the tests for them later.

andrebrait avatar Sep 16 '22 16:09 andrebrait

Sweet

garydgregory avatar Sep 16 '22 18:09 garydgregory

@garydgregory done, coverage should be back up and all conflicts were resolved.

andrebrait avatar Oct 22 '22 10:10 andrebrait

@garydgregory let me know if you need help on making any required changes for switching it from 1.22 to 1.23

andrebrait avatar Dec 06 '22 13:12 andrebrait