Skip to content

Add Serializable attribute to ZipException #365

Closed

Description

@fatimagullmadni

Steps to reproduce

  1. Use WCF service
  2. Call some Zip functionality where exception is triggered

Expected behavior

the exception is serializable so it does not clash with WCF

Actual behavior

exception=System.Runtime.Serialization.SerializationException: Type 'ICSharpCode.SharpZipLib.Zip.ZipException' in Assembly 'ICSharpCode.SharpZipLib, Version=1.1.0.145, Culture=neutral, PublicKeyToken=1b03e6acf1164f73' is not marked as serializable.

Version of SharpZipLib

1.1.0.145

Obtained from (only keep the relevant lines)

  • Package installed using NuGet

Activity

  1. piksel commented on Jul 4, 2019

    @piksel
    Member

    I think this was skipped due to .NET Standard 1 not supporting it. But since we are now targeting .NET Standard 2, inclusion should no longer be an issue. A PR would be welcomed!

  2. fatimagullmadni commented on Jul 5, 2019

    @fatimagullmadni
    Author

    Thanks for reply, Is there a ETA for the support ?

  3. piksel commented on Jul 5, 2019

    @piksel
    Member

    No, there is currently no ongoing effort to support this.

  4. added
    enhancement
    on Jul 5, 2019
  5. changed the title [-]Zip exception is not serializable[/-] [+]Add Serializable attribute to ZipException[/+] on Jul 5, 2019
  6. Numpsy commented on Aug 1, 2019

    @Numpsy
    Contributor

    There are several exception types defined in the library - if this was going to be done, would it be worth looking over all of them rather than just ZipException?

  7. piksel commented on Aug 1, 2019

    @piksel
    Member

    Yeah, but it should just be a matter of adding [Serializable] in the declaration.

  8. Numpsy commented on Aug 1, 2019

    @Numpsy
    Contributor

    Ok (wasn't sure if they'd need the SerializationInfo constructor overloads adding as well.)

  9. Numpsy commented on Aug 15, 2019

    @Numpsy
    Contributor

    @fatimagullmadni Do the changes in the 1.2.0 release work for your use case?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementhelp wanted

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions