NuGet.exe pack does not error when file names collide with folder names, creating packages with odd/invalid unpacking behaviour #13273
Labels
Functionality:Pack
Priority:3
Issues under consideration. With enough upvotes, will be reconsidered to be added to the backlog.
Product:NuGet.exe
NuGet.exe
Type:Bug
NuGet Product Used
NuGet.exe
Product Version
NuGet Version: 6.8.0.131
Worked before?
No response
Impact
It bothers me. A fix would be nice
Repro Steps & Context
Attempt to pack a package with the following structure:
the files' contents other than the nuspec do not matter. nuspec contents:
Once the package is packed (I just used
nuget pack
), the package can be inspected with a tool like 7zip to note that it contains both abin
file and abin
folder. When these files are extracted onto a filesystem, things get weird, it will either give an access denied error or ask about overwriting file/folder contents, depending on the tool used to unpack the nupkg.This was first noticed because attempting to upload a package malformed in this way causes a 500 Internal Server Error when uploading to the Chocolatey Community Repository, as it does some inspection and unpacking of uploaded packages; see chocolatey/home#303
The expected behaviour from the user perspective is that
extensionless-file
is placed inside the already-definedbin
folder, but the common method of defining the<file>
node assrc="source-file" target="target-folder"
does not work in this case.Verbose Logs
No response
The text was updated successfully, but these errors were encountered: