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

Announcements

No record found.

News and Announcements icon
Community site session details

Community site session details

Session Id :
Finance | Project Operations, Human Resources, ...
Answered

Dev VM builds models, build VM via pipeline errors on deleted objects

(0) ShareShare
ReportReport
Posted on by 355

Hoping someone can please offer thoughts on this behaviour. We've got a pair of Tier 1 cloud-hosted environments in an LCS project with TFS for the extension developments. On the Dev box, the custom models all build successfully, so I've attempted to check a series of changes. The gated checkin pipeline then fails with 11 errors, all thrown by objects that have been deleted within the changeset. The pipeline shows the deletes in its Checkout task, so I can't understand why the build is then attempting to compile the objects.

Example error:

C:\DynamicsSDK\Metadata\Microsoft.Dynamics.AX.Application.Build.targets(40,5): error : Error: AxMap/CUSLetterTemplateMap/Mappings/CUSLetterTemplate/Connections/LegalEntity/MapFieldTo - Field 'LegalEntity' does not exist. [C:\DynamicsSDK\Metadata\BuildMetadata.proj]


Checkout task extract:

Metadata\CUSDevelopment\CUSDevelopment\AxMap:
Unshelving delete: CUSLetterTemplateMap.xml

I've tried a remote desktop connection onto the build machine whilst the pipeline is running, monitoring the metadata folder above, and I can see the relevant map appearing in the folder, being deleted, and then appearing again as the error gets thrown.

Any thoughts gratefully received.

I have the same question (0)
  • Verified answer
    Martin Dráb Profile Picture
    238,769 Most Valuable Professional on at

    It's strange that the map exists on the build VM. The build shouldn't have to delete it. Because the build environment shouldn't contain any custom code (when it's restored from the clean backup at the beginning of the build), and the map doesn't exist in source control anymore, it simply shouldn't be downloaded when the workspace is created.

    I suspect that the backup actually isn't clean - it already contains your objects.

  • Rich Profile Picture
    355 on at
    [quote]

    It's strange that the map exists on the build VM. The build shouldn't have to delete it. Because the build environment shouldn't contain any custom code (when it's restored from the clean backup at the beginning of the build), and the map doesn't exist in source control anymore, it simply shouldn't be downloaded when the workspace is created.

    I suspect that the backup actually isn't clean - it already contains your objects.

    [/quote]

    Thanks Martin: you're right about the backup (meaning the J\:DynamicsBackup\Packages folder) containing the custom models & ISV models that make up the deployable package I'm expecting the pipeline to build.  I haven't found any documentation on this folder, but I see two prior threads (Package build process creates new files, Error on prepare for build) that give a decent explanation of its purpose & origins. Slightly frustrated I didn't find either of those threads before posting & have led you to repeat what others have suggested to resolve similar issues. Having removed the custom model folders from the backup packages folder, the build is now working, so hopefully I'll remember that one (though I also hope not to see the backup in an unclean state again!)

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

Quick Links

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Stars!

Congratulations to our 2025 Community Spotlights

Thanks to all of our 2025 Community Spotlight stars!

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

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 509 Super User 2026 Season 1

#2
Giorgio Bonacorsi Profile Picture

Giorgio Bonacorsi 375

#3
Adis Profile Picture

Adis 268 Super User 2026 Season 1

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans