Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Different behaviour in Windows before and after running library(zip) #116

@context-dependent

Description

@context-dependent

Ran into this issue on Windows 11, attempting to unzip an archive with descendent files having names that include single quotes.

An example directory structure:

problematic-filenames.zip
   /l'esprit du corps.png

After installing, but prior to running library(zip),

zip::unzip("problematic-filenames.zip")

Panics and exits with error code 1, R_ZIP_EOPEN.

After running library(zip), identical calls produced the desired result in current and subsequent sessions, even after reinstalling the zip package.

I don't know how to reproduce the error, as I don't know how to undo the side-effect(s) of library(zip), but I do know that the default zip tool in windows 11 will panic when asked to zip folders with files whose paths contain single quotes.

The problem with this difference is that, when r-lib/zip is imported into another package as a dependency, users of the dependent package on Windows may experience unforeseen errors if they haven't called library(zip), which seems bad.

Metadata

Metadata

Assignees

No one assigned

    Labels

    reprexneeds a minimal reproducible example

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions