dotnet / source-build

A repository to track efforts to produce a source tarball of the .NET Core SDK and all its components
MIT License
259 stars 126 forks source link

3774 new binaries introduced into VMR #4395

Closed Winniexu01 closed 1 month ago

Winniexu01 commented 1 month ago

main build: https://dev.azure.com/dnceng/internal/_build/results?buildId=2449450&view=logs&j=fa5c2909-0e29-5671-d5eb-16d6c40e0c4a&t=2a0bd486-3f67-5c59-da0c-b84d88848a4b

New binaries:
  src/sdk/.dotnet/dotnet
  src/sdk/.dotnet/host/**
  src/sdk/.dotnet/packs/**
  src/sdk/.dotnet/sdk/**
  src/sdk/.dotnet/shared/**
  src/sdk/.dotnet/templates/**
  artifacts/bin/**
  artifacts/obj/**

More information: NewBinaries.txt allowed-sb-binaries.txt allowed-vmr-binaries.txt

mthalman commented 1 month ago

@ellahathaway - PTAL. These binaries don't exist in the repo.

ViktorHofer commented 1 month ago

Potentially regressed with https://github.com/dotnet/sdk/commit/d5cb00f7dcb79b9cfc6c528f5b574ba4fd5ffd7a?

ellahathaway commented 1 month ago

The BinaryToolKit binaries make sense. I'll add those to the ignore file.

As far as the rest of the binaries, it looks like the Initialize Tooling step of Tag & Scan installs dotnet into src/sdk in order to use darc: Adding to current process PATH: /mnt/vss/_work/1/s/src/sdk/.dotnet To fix that, I'll make the ignored .dotnet/ be **/.dotnet/.

akoeplinger commented 1 month ago

@ellahathaway alternatively we could use the root dir as the working directory and pass --tool-manifest src/sdk/.config/dotnet-tools.json to dotnet tool restore

ellahathaway commented 1 month ago

alternatively we could use the root dir as the working directory and pass --tool-manifest src/sdk/.config/dotnet-tools.json to dotnet tool restore

This is a much better alternative. Thanks for pointing this out! I'll update the PR accordingly.

Edit: Tried to configure this locally, and I can't seem to get darc installed correctly. After setting up vmr/.dotnet, I ran .dotnet/dotnet tool restore --tool-manifest src/sdk/.config/dotnet-tools.json which succeeded. However, .dotnet/dotnet darc returns:

Could not execute because the specified command or file was not found.
Possible reasons for this include:
  * You misspelled a built-in dotnet command.
  * You intended to execute a .NET program, but dotnet-darc does not exist.
  * You intended to run a global tool, but a dotnet-prefixed executable with this name could not be found on the PATH.
akoeplinger commented 1 month ago

@ellahathaway hm interesting, the --tool-manifest option looks a bit pointless then :) You can make it work if you run the commands in the src/sdk directory but with the dotnet from the root:

source eng/common/tools.sh
InitializeDotNetCli true

cd src/sdk
../../.dotnet/dotnet tool restore
../../.dotnet/dotnet darc
ellahathaway commented 1 month ago

You can make it work if you run the commands in the src/sdk directory but with the dotnet from the root

This worked locally for me. Thanks for your help!