FileArchive creates zip files with backslashes on Windows #16273
Labels
area/assets-and-archives
FileAsset/FileArchive etc.
kind/bug
Some behavior is incorrect or out of spec
os/windows
What happened?
In a Pulumi Python project, on a Windows 11 computer, I created an S3 bucket object based on an AssetArchive containing a FileArchive. The Pulumi update was successful, and the zip file was present in S3. An AWS CodeBuild project takes the zip file as its source, running on "aws/codebuild/amazonlinu2-x86_64-standard:5.0".
On the Linux host, I expected the "ls -R" command to show a nested directory tree. Instead, it showed a list of files with backslashes in their names.
I downloaded the zip file to Windows 11, and both Explorer and 7zip open the file and show the nested directory tree with no complaints. Opening the zip file in Notepad++, I see backslashes in filenames.
Example
Output of
pulumi about
Plugins
KIND NAME VERSION
resource aws 6.37.1
resource aws-native 0.103.0
language python unknown
Host
OS Microsoft Windows 11 Enterprise
Version 10.0.22631 Build 22631
Arch x86_64
This project is written in python: executable='C:\projects\bit\poetry-demo.venv\Scripts\python.exe' version='3.12.3'
[...]
Additional context
A similar bug (#2784) was fixed five years ago.
Contributing
Vote on this issue by adding a 👍 reaction.
To contribute a fix for this issue, leave a comment (and link to your pull request, if you've opened one already).
The text was updated successfully, but these errors were encountered: