web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Finance | Project Operations, Human Resources, ...
Suggested Answer

Run Pipelines failed with NuGet issue

(1) ShareShare
ReportReport
Posted on by 124
Hi, 

I'm encountering an issue with a 'DEV' pipeline run as described below.
I have no idea how to set the correct path parameter in this case. Can anyone provide me with a clue?

Many thanks.
 
1)#2024.05.03.101 (Failed)
- I run the pieline but get the error /Please switch to using NuGetCommand@2's 'restore' or 'custom'
- I changed NetGet from Task version 0.* to 2.*
 
2)#2024.05.03.102 (Failed)
- Error: The nuget command failed with exit code(1) and error(Cannot determine the packages folder to restore NuGet packages. Please specify either -PackagesDirectory or -SolutionDirectory.
- I added NuGet tool installer and setup Task version with  1.* and version  6.9.1 to install
 
3)#2024.05.03.103 (Failed)
- Error: The nuget command failed with exit code(1) and error(Cannot determine the packages folder to restore NuGet packages. Please specify either -PackagesDirectory or -SolutionDirectory.
- I Modify path to solution in NuGet page from '$(Build.SourcesDirectory)//Build//packages.config' to '**//*.sln'
 
4)#2024.05.03.104 (Failed)
- Error: The nuget command failed with exit code(1) and error(D://a//10//s//Build//Projects//DevBuild//Invoice//Invoice.rnrproj(37,3): error MSB4019: The imported project /C://Program Files (x86)//MSBuild//Microsoft//Dynamics//AX//Microsoft.Dynamics.Framework.Tools.BuildTasks.targets/ was not found. Confirm that the expression in the Import declaration /C://Program Files (x86)//MSBuild//Microsoft//Dynamics//AX//Microsoft.Dynamics.Framework.Tools.BuildTasks.targets/ is correct, and that the file exists on disk.
I have the same question (0)
  • Suggested answer
    André Arnaud de Calavon Profile Picture
    301,482 Super User 2025 Season 2 on at
    Hi JoBox,

    Probably you can review your settings with guidance from Denis Trunin in his blog: Step-by-Step Guide: Creating D365FO Build and Deploy Pipelines | Denis Trunin's X++ Programming Blog
  • Suggested answer
    Anthony Blake Profile Picture
    2,977 Super User 2025 Season 2 on at
    What does your get sources step look like? 
     
    Have you got a "NuGet custom install packages" step?
     
    Import on of the blank samples from the github repo and compare them to your pipeline, it will probably be mapping dependency related:
     

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

News and Announcements

Season of Giving Solutions is Here!

Quick Links

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

Leaderboard > Finance | Project Operations, Human Resources, AX, GP, SL

#1
Abhilash Warrier Profile Picture

Abhilash Warrier 732 Super User 2025 Season 2

#2
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 413 Super User 2025 Season 2

#3
Martin Dráb Profile Picture

Martin Dráb 289 Most Valuable Professional

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans