Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error while Inserting work item in ADO - Different Error #37

Closed
chad-msft opened this issue Dec 15, 2022 · 1 comment
Closed

Error while Inserting work item in ADO - Different Error #37

chad-msft opened this issue Dec 15, 2022 · 1 comment

Comments

@chad-msft
Copy link

chad-msft commented Dec 15, 2022

I am having an error that is similar to #33. Running the PnP-DevOps.ps1 script successfully creates the epics but errors on all of the issues.

PS C:\Users\cschult\source\repos\WellArchitected-Tools\WARP\devops> .\PnP-DevOps.ps1 -pat xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx -uri https://dev.azure.com/cschult-WAFTst/relitemstst -name WAF-Rel-Assessment -csv "C:\Users\cschult\OneDrive - Microsoft\PWC\Swiss Rel WAF\Azure_Well_Architected_Review_Dec_9_2022_1_37_29_PM.csv"Assessment Name: WAF-Rel-Assessment
URI Base: https://dev.azure.com/cschult-WAFTst/relitemstst/
Number of Recommendations to import: 25
Ready? [y/n]: y
Adding Epic to ADO: Application Performance Management
Adding Epic to ADO: Networking & Connectivity
Adding Epic to ADO: Operational Procedures
Adding Epic to ADO: Application Design
Adding Epic to ADO: Data Platform Availability
Adding Epic to ADO: Deployment & Testing
Adding Epic to ADO: Azure Advisor
Adding Epic to ADO: Health Modeling & Monitoring
Adding Epic to ADO: Application Platform Availability
Attempting DevOps Import for all Issues
Fetching existing DevOps Work Items
Adding Work Item: Have clearly defined availability targets
Write-Error: C:\Users\cschult\source\repos\WellArchitected-Tools\WARP\devops\PnP-DevOps.ps1:402
Line |
402 | Add-NewIssueToDevOps `
| ~~~~~~~~~~~~~~~~~~~~~~
| Exception while creating work item: [ { "op": "add", "path": "/fields/System.Title", "value": "Have clearly defined
| availability targets" }, { "op": "add", "path": "/fields/Microsoft.VSTS.Scheduling.Effort", "value": "0"
| }, { "op": "add", "path": "/fields/Microsoft.VSTS.Common.Priority", "value": "1" }, {
| "op": "add", "path": "/fields/System.Tags", "value": "Reliability;WAF-Rel-Assessment" }, { "op": "add",
| "path": "/fields/Microsoft.VSTS.Common.BusinessValue", "value": "95" }, { "op": "add", "path":
| "/fields/Microsoft.VSTS.Common.TimeCriticality", "value": "95" }, { "op": "add", "path":
| "/fields/Microsoft.VSTS.Common.Risk", "value": "1 - High" }, { "op": "add", "path":
| "/fields/System.Description", "value": "<a
| href="https://learn.microsoft.com/azure/architecture/framework/Resiliency/business-metrics#workload-availability-targets">Have clearly defined availability
| targets\r\n" }, { "op": "add", "path": "/relations/-", "value": {"rel":
| "System.LinkTypes.Hierarchy-Reverse", "url": "https://dev.azure.com/cschult-WAFTst/d2b0a816-58c6-4aeb-8516-5c70c22bf9c7/_apis/wit/workItems/6", "attributes":
| {"comment": "Making a new link for the dependency"}} } ]

Azure_Well_Architected_Review_Dec_9_2022_1_37_29_PM.csv

@chad-msft
Copy link
Author

I figured out the issue.
Some Azure DevOps projects have different work item types available (Feature, Issue, Epic, Etc.). The script is hardcoded to only use Feature work item types which are not available in the 'Basic" project type. I am sending PR with needed changes to help with this and other errors I found while debugging.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant