Why has my MVC site stopped working?

I am currently upgrading a .NET Core 3.1(LTS) MVC website to run on .NET 6, stepping it through intermediate .NET versions to make sure some EF Migrations were done correctly. Everything upgraded without any major issue until the final step to .NET 6. As soon as I did this my MVC pages failed to render, but no error was reported After much fiddling the solution to the problem was pointed out to me by one of my colleagues....

July 28, 2022 · 2 min · Richard Fennell

Cannot retrieve Umbraco node

We recently hit a problem when we tried to edit a page on anold Umbraco 7 instance. When we tried to edit a page in the Umbraco web UI we got the error ‘failed to retrieve data for content id 1119’ Now this page had been created a long time ago by a user who had since left the company, and this was the root cause. It seems there is an issue with Umbraco and deleted users....

July 25, 2022 · 1 min · Richard Fennell

Social Media Posts after Migrating from WordPress to Hugo Static Pages

I posted recently on my experience moving to Hugo from WordPress. One feature lost in the move were the Wordpress plugins used to automatically post to Twitter and LinkedIn when a new blog post was created. I always found this very useful, so looked or a way to replicate this functionality for static pages. The solution I ended up with was Azure Logic Apps. I created a Logic App with a scheduled triggered that checked my blogs’s RSS feed every 30 minutes....

July 7, 2022 · 1 min · Richard Fennell

Migrating from WordPress to Hugo Static Pages

Background Over the years, the Black Marble blog server has been hosted on many platforms. It’s previous incarnation was WordPress, running as a network of sites with an aggregated feed. Of late we had found this slow to serve the first page (due to website start-up time) and there was the constant need to keep the instance patched. The time had come for a new solutions, and we picked Hugo Static Pages....

July 1, 2022 · 3 min · Richard Fennell

Don't skimp on resources for GHES for demo instances

I wanted to have a look at some GitHub Enterprise Server (GHES) upgrade scenarios so decided to create a quick GHES install on my local test Hyper-V instance. Due to me skimping on resources, and making a typo, creating this instance was much harder than it should have been. The first issue was I gave it a tiny data disk, this was down to me making a typo in my GB to Bytes conversion when specifying the size....

June 16, 2022 · 2 min · Richard Fennell

Fix for cannot 'TypeError: Cannot read property' when Dependabot submits a PR to upgrade a Jest Module

GitHub’s Dependabot is a great tool to help keep your dependencies up to date, and most of the time the PR it generates just merges without a problem. However, sometimes there are issues with other related dependencies. This was the case with a recent PR to update jest-circus to 28.x. The PR failed with the error TypeError: Cannot read property ’enableGlobally’ of undefined at jestAdapter (node_modules/jest-circus/build/legacy-code-todo-rewrite/jestAdapter.js:39:25) at TestScheduler.scheduleTests (node_modules/@jest/core/build/TestScheduler.js:333:13) at runJest (node_modules/@jest/core/build/runJest....

May 19, 2022 · 1 min · Richard Fennell

Fix for Azure DevOps deployment to an environment stuck in "Job is pending" state

Issue I had an Azure DevOps YAML based pipeline that had been working but was now getting stuck with the message “Job is pending…” when trying to start a stage in which there is a deployment to an environment. Looking at the logs and Azure DevOps UI it was not obvious what the issue was. Solution Turns out it was due to environment checks and approvals. There was a branch policy on the environment....

April 7, 2022 · 1 min · Richard Fennell

A workaround for not being able to access custom variables via stagedependencies if they are set in deployment jobs in Azure DevOps Pipelines

I have blogged in the past ( here and here) about the complexities and possible areas of confusion with different types of Azure DevOps pipeline variables. I have also seen issues raised over how to access custom variables across jobs and stages. Safe to say, this is an area where it is really easy to get it wrong and end up with a null value. I have recently come across another edge case to add to the list of gotchas....

February 19, 2022 · 2 min · Richard Fennell

The importance of blogging - or how to do your future self a favour

Yesterday, yet again, I was thankful for my past self taking time to blog about a technical solution I had found. I had an error when trying to digitally sign a package. On searching on the error code I came across my own blog post with the solution. This was, as usual, one I had no recollection of writing. I find this happens all the time. It is a little disturbing when you search for an issue and the only reference is to a post you made and have forgotten, so you are the defacto expert, nobody knows anymore on the subject, but better than having no solution....

January 14, 2022 · 1 min · Richard Fennell

Using Azure DevOps Stage Dependency Variables with Conditional Stage and Job Execution

I have been doing some work with Azure DevOps multi-stage YAML pipelines using stage dependency variables and conditions. They can get confusing quickly, you need one syntax in one place and another elsewhere. So, here are a few things I have learnt… What are stage dependency variables? Stage Dependencies are the way you define which stage follows another in a multi-stage YAML pipeline. This is as opposed to just relying on the order they appear in the YAML file, the default order....

January 10, 2022 · 5 min · Richard Fennell