Creating an undo PowerShell Script for batch updates of Azure DevOps Work Items

Problem One of my client’s recently had a problem that a large number of Azure DevOps work items had been updated via Excel in error. They asked if there was a means to undo these edits. Unfortunately, a feature Azure DevOps does not provide. Solution So, I wrote a PowerShell script to do it. The script… Gets a list of work items edited today by a specific user, the one who did the problematic bulk update, using a Work Item Query Get the last update of each work item and check it was made by the user who did the bulk edit, incase someone manually fixed the problematic update already....

April 16, 2024 · 2 min · Richard Fennell

GitHub Events not being triggered for auto-merged Dependabot PRs

Background I have an Azure Static Website that is built from a GitHub hosted repo using the default Action Workflow automation created by Azure when setting up the static site. A really nice feature of this configuration is that when a PR is created in GitHub a test static website environment site is built in Azure to review the changes. When the PR is closed the test environment site is deleted....

March 18, 2024 · 4 min · Richard Fennell

I can't get git.exe installed on my corporate PC

Issue Many development tools rely on the fact that git.exe is installed to perform source control operations e.g. VSCode. However, a common problem I have seen is that security settings on many corporate Windows devices do not allow the installation of git CLI using an MSI file by the user. VSCode is an approved application, or installed as a user application as opposed to a system one, so is available but limited by it’s lack of source control features....

February 2, 2024 · 4 min · Richard Fennell

Change in Edge/Chromium profile settings broke my Azure Entra ID SSO

Background I have recently hit a problem whilst developing some training material on Single Sign on (SSO) in GitHub Enterprise. This training is to be delivered in a training instance of GHE that is configured to use a training instance of Azure Entra ID as the SAML identity provider. To make my life easier, so I am not logging in and out of my work and test Azure Entra ID directories, I have been using profiles in my Chromium based Edge browser....

December 21, 2023 · 2 min · Richard Fennell

Caching NVD Vulnerability Dependency data on hosted Azure DevOps Pipeline agents

Background On some projects we use Jeremy Long’s DependencyCheck tool, via the Azure DevOps task, to scan our code for known vulnerabilities. This tool uses the National Vulnerability Database (NVD) to get its data. This data is downloaded on demand from the NVD site but the DependencyCheck tool. Since the recent API changes on the NVD site, as supported by DependencyCheck 9.0.x, the downloading of the current vulnerability data has slowed from about 3 minutes to around 15 minutes, even with a valid NVD API Key....

December 6, 2023 · 3 min · Richard Fennell

Setting Azure DevOps Agent Pool Descriptions via the Azure DevOps API

The Issue If you are using Azure Scale Set based Azure DevOps Agent Pools (VMSS) to provide dynamically scalable agent pools, unlike with self hosted agent pools, there is no capabilities tab for the individual agents. My understanding is that this UX design choice was made as the capabilities of all the agents in a VMSS pool are identical, as they are the same disk image, so why show the same data multiple times....

August 24, 2023 · 3 min · Richard Fennell

Setting up Snipe IT on Azure using Docker

Background I have recently been looking at getting Snipe-IT running on Azure using a Docker container. Though the documentation for this project is good, the detail for the Azure setup is a little lacking. So I thought I would document the steps and Rik Hepworth took to get it working. Notes: This is a simple configuration to get it working, it can obviously get a lot more complex with the setup of VNETs etc....

August 9, 2023 · 6 min · Richard Fennell

SonarCloud Azure DevOps PR Analysis fails with a 404 error

The Problem Recently had an issue on a project that had been paused for a few months. When we restarted the project we found that the SonarCloud PR analysis, running via an Azure DevOps YAML pipeline, was failing with a 404 error. The strange thing was that the same pipeline running analysis of the main trunk or the branch the PR related to worked without error. The Solution The issue was fixed by regenerating the SonarCloud PAT that was registered in the Azure DevOps project’s Service Connection....

August 3, 2023 · 1 min · Richard Fennell

Fix for metadata generation failed exit code: 2147450750 loading wrong version of DLLs when building Azure Functions

The Problem Recently an Azure DevOps Pipeline for a .NET 6 based Azure Functions started to fail on some of our self-hosted build agents with the error ##[error]C:\Users\Administrator\.nuget\packages\microsoft.azure.webjobs.script.extensionsmetadatagenerator\4.0.1\build\Microsoft.Azure.WebJobs.Script.ExtensionsMetadataGenerator.targets(37,5): Error : Metadata generation failed. Exit code: '-2147450750' Error: 'Failed to load the dll from [C:\hostedtoolcache\windows\dotnet\shared\Microsoft.NETCore.App\3.1.32\hostpolicy.dll], HRESULT: 0x800700C1An error occurred while loading required library hostpolicy.dll from [C:\hostedtoolcache\windows\dotnet\shared\Microsoft.NETCore.App\3.1.32]' The pipeline it self was simple, just repeating the steps a developer would use locally...

July 19, 2023 · 3 min · Richard Fennell

Update on sending social media posts from Hugo based static site

Around a year ago I posted on ‘Social Media Posts after Migrating from WordPress to Hugo Static Pages’. Recently I have found that the Twitter functionality in my Logic App was failing. Turns out this was due to the changes in the Twitter Free API, with them moving from V1 to V2 which requires OAuth authentication as opposed to a Bearer token. In essence the core of the problem is that the built-in Logic Apps Twitter Connector only supports the V1 Twitter API....

July 13, 2023 · 1 min · Richard Fennell