Unzip .tar.gz files

could you please send ?

Hai,

After the upgraded of CE. I cannot proceed with the old version in my system. I will try to do in virtual machine today. And let you.

Hi Balu, unfortunately I’m unable to unzip .tar.gz file. It gave me below error. Are you able to assist me on this please. zip.zip (1.4 KB)

“Un zip : Could not read C:\ShipmentCorrection\Reports\InputText\zip\BE_WAYBILL_MATCHING_201810231331.tar.gz as a zip file”

Hi @Serran_Neru,

Handling the tar.gz is different than other. Below I have attached the sample for you.

file :Unzip.zip (3.3 KB)

This is the result that you are expecting.

Regards
Balamurugan.S

Hi Bala, thanks alot for prompt help on this.
However unfortunately I encounter below error :frowning:

“UnZip : Method not found: ‘SharpCompress.Common.ArchiveEncoding SharpCompress.Common.OptionsBase.get_ArchiveEncoding()’”

Did I installed the right package?

Let me check and tell you.

Regards

Balamurugan.S

Hi Bala, Thank you so much and will wait for your reply. :slight_smile:

Hi @balupad14, any update?

Hi @Serran_Neru,

I have tested in my local . It is working well. can you attach your xaml . I will test it here.

Regards
Balamurugan.S

Hi Bala ,

I am getting this below error while trying to use unzip activity , I have installed the packages needed and trying to run . Am i missing something?

testZip has thrown an exception

Source: UnZip

Message: Method not found: ‘SharpCompress.Common.ArchiveEncoding SharpCompress.Common.OptionsBase.get_ArchiveEncoding()’.

Exception Type: MissingMethodException

System.MissingMethodException: Method not found: ‘SharpCompress.Common.ArchiveEncoding SharpCompress.Common.OptionsBase.get_ArchiveEncoding()’.
at BalaReva.Externals.UnZipFile.Execute(CodeActivityContext context)
at System.Activities.CodeActivity.InternalExecute(ActivityInstance instance, ActivityExecutor executor, BookmarkManager bookmarkManager)
at System.Activities.ActivityInstance.Execute(ActivityExecutor executor, BookmarkManager bookmarkManager)
at System.Activities.Runtime.ActivityExecutor.ExecuteActivityWorkItem.ExecuteBody(ActivityExecutor executor, BookmarkManager bookmarkManager, Location resultLocation)

Hi @Elakya_sekar,

Can you please attach the zip file to test the unzip ?

Regards
Balamurugan.S

Hello,

I have a .tar.gz archive that contains a folder structure and a .tar archive at the end. More exactly:
myarchivetar.gz contains: home\erovinie\public_html\staging_assets_archives\archive.tar

When I use the unzip activity selecting the myarchive.tar.gz and execute, I have the following error:

18.4.2+Branch.master.Sha.9888b477be8d3ec8a832306fc59c34ba6edad108

Source: UnZip

Message: Entry is trying to create a directory outside of the destination directory.

Exception Type: SharpCompress.Common.ExtractionException

An ExceptionDetail, likely created by IncludeExceptionDetailInFaults=true, whose value is:
SharpCompress.Common.ExtractionException: Entry is trying to create a directory outside of the destination directory.
at BalaReva.Externals.UnZipFile.Execute(CodeActivityContext context)
at System.Activities.CodeActivity.InternalExecute(ActivityInstance instance, ActivityExecutor executor, BookmarkManager bookmarkManager)
at System.Activities.ActivityInstance.Execute(ActivityExecutor executor, BookmarkManager bookmarkManager)
at System.Activities.Runtime.ActivityExecutor.ExecuteActivityWorkItem.ExecuteBody(ActivityExecutor executor, BookmarkManager bookmarkManager, Location resultLocation)

tis is how my xaml looks like. Can’t share the .tar.gz archives…:

Hi @crimaru,

Thank you for using the activity and your feed.
Can you please attache sample to test at my side.?

Regards
BalaReva

1 Like

Can’t share the archive.

It contains a .tar inside a tar.gz.

Didn’t managed to create .tar.gz archive with a .tar archive containing dummy data. If you can do it, you should give it a try and see. I solved my issue by using 7z in command prompt.

The .xaml contains only the activity with the path to the .tar.gz and the path where to download the contents (same location with the .tar.gz file. Also tried with other locations, same error).

Thanks!

HI @crimaru,

I need a sample file which you have the real one. I don’t have proper to generate the tar.gz.

Regards
Balamurugan.S

To unpack a tar.gz file, you can use the tar command from the shell.

Sample: tar -xzf rebol.tar.gz

The result will be a new directory containing the files. Also, on many systems, when you download the tar.gz from a web browser, an unpacker will open, and you can just use that. You can visit 7zipguides.

Hi Bala.

Try to download the package, it is no longer available?

Hello @Exiamen,

Welcome to UiPath Community.

Now the UiPath Gallery is discontinued . Now you can get it from here.

Regards
Balamurugan.S

Balupad

Thanks for your help, but do not uncompress the .CSV.GZ file

Hi,
Here is a new package for only gz file to unzip.

Regards
Balamurugan.S