Can you post your pipeline, or share the yaml steps? Generally, these are some steps I follow:
All these tasks of type DotNetCoreCLI@2.