A month with Microsoft and others — One year on

It’s now more than a year since I write the first blog about this. I must say I wasn’t really expecting to follow this up but I have now decided that it may be worthwhile to attempt to see what if anything has changed. A few things have changed for me, which mean that the focus of this may be a little different. In particular I’ve started using Rider more. I still find it quirky and sometimes I find it hard to work out if it can do what I want. Having said that I am using it increasingly. I’m also using VS 16.7, as I discovered this is a sort of LTS for VS I intend on sticking with that. Finally I have a new laptop! My old Surfacebook has been replaced with a very high spec Lenovo workstation. Apart from a few minor quibbles and terrible wifi I am delighted with the new machine. I’m now running an i9 with 8 cores (16 virtual), 32 Gb Ram and dual SSD. The extra oomph should make a significant boost to performance over the Surfacebook.

1 Sep

This is the first day of this blog and VS has already bombed out once. I think it was due to changing branch in Git. I didn’t make a note but i did restart VS as a result of it, so I think it’s fair to say 10 minutes disruption as the solution is a rather complex one.

I get the gold bar quite often throughout the day, the main culprit is one stating there is an issue, An exception of type ArgumentException has been encountered. On looking at the log file, it appears from the call stack to be somehow related to Microsoft.CodeAnalysis. I wondered if it was caused by Resharper and so disabled it — with no overall effect, so it looks like it’s something built in. Googling didn’t provide any solution that appeared to apply and I noticed a few posts that may have been related on an official MS support site but they were from some time ago. When this occurs, if I don’t restart VS it seems to do strange things, it may be unrelated of course but the strangeness doesn’t seem to happen otherwise.

Second gold bar error (as above) — this time the culprit is RoslynNuGetSearch. No idea why this should be the case as I didn’t think I was doing anything that should require NuGet as I was editing code at the time. This doesn’t happen in Rider so I’m going to use that for the rest of the day

Time lost — around 30 minutes to restart VS and reopen my solution (thrice ).

3 Sep

There is one problem with my Lenovo Workstation and that’s the WIFI. I use it in exactly the same location as the MacBook (which I’m using now), my iPad, my android phone, an Alexa device and previously my Surfacebook Pro. None of these other devices have issues with the WIFI. The obvious solution is cat 5 which I have however the Lenovo doesn’t have a standard ethernet port, so I have to use a USB to ethernet adapter. Additionally between here and the router is all wooden floors so it’s not quite so easy to have permanent cat5, especially when it’s bright orange! As it’s only me in most of the time I just trail it across the floor. The problem is that if I startup (or reboot) the machine while the ethernet is plugged in then the machine takes a ridiculous amount of time to boot, it gets stuck on the windows Please Wait message for about half an hour or more. Unfortunately this morning I was too quick plugging in the ethernet and so it’s happening now and I’m using the MacBook as we speak. The good side of this is that I can use Rider on it.

Time lost — a few minutes, as I’m fortunate that I can use a Mac

There is something about the combination of Git, Visual Studio and NuGet that seems to cause me regular and frustrating issues. While I realise this may well be due to a number of factors, including my lack of understanding, that is how it appears to be. These issues don’t happen with Mercurial, Rider and Paket.

So today was the worst issue I have had for some time. I needed to deploy an update to a web service today. Yesterday, I prepared as much as I was able to make the update a smooth one, including checking out the appropriate commit. Today, after no changes to the application, it refused to build. further testing revealed that it was only in Release configuration that it wouldn’t build, in Debug configuration. The error in question was the dreaded

Fortunately for me I had a solution to this. Unfortunately for me that didn’t work in this case. To make it worse I could find no reference to System.Buffers. The only thing that worked was to publish in Debug configuration!!. Clearly this is not optimal but it had to do until I can resolve this issue. There are plenty of people with this issue but there appears to be nothing useful about it from Microsoft. I probably need to look at fuslogvw but don’t have time at the moment.

To make it worse I also got this error

This is a package I have created and is readily available locally and widely used in this particular solution. Bizarrely, uninstalling the package from the whole solution seemed to resolve the issue, though I have since had to reinstall it.

To add insult to injury, I use VSCode a lot for formatting json and xml, just to make it more readable. I basically create a new file, regardless of the project I am working on, paste the json, format it then dump it. This normally works well. Today, VSCode Insiders decided I couldn’t paste as the new file was read only. Thankfully the normal VSCode was more obliging. After testing it appears that there is just one folder it’s taken a dislike to. Every other folder appeared to work normally.

Overall time lost — about 90 minutes hunting for and trying solutions

4 Sep

To some of you this one will be self explanatory

If it’s not, you’re lucky. I’ve no idea why this crops up when all I have done is loaded a solution in Visual Studio — it shouldn’t even be using NuGet as it’s a Paket solution. In this case the simplest solution is to open it in Rider or VSCode. This appears to be related to my proxy settings but VS appears to cache them on start up which for me would explain why this is an issue as I sometimes have to change my proxy settings and VS isn’t aware of the change unless its restarted.

Time wasted — 10 minutes — much of which is wasted on closing that dialog box, the rest of which is shutting down VS and opening another IDE

7 Sep

My internet connection has been terrible over the weekend. I guess that’s the price for using Virgin Media, but this is worse than normal, it was down for most of yesterday, started working for an hour or two in the evening, then gave up again. This morning it seems to be working.

I doubt its connected but my laptop has decided once again to go for what I am now calling the long boot option, this time the ethernet wasn’t plugged in so I’m hoping it’s not a Windows update. I heard recently that one of the recent ones can break some Lenovo machines. It’s set to delay updates as long as possible — in the hope of minimal impact on my machine. I’m using the Mac again, the more I use it the more I like it, the only issue I have with it is the limited screen estate. I like very high resolution screens when I’m writing code

8 Sep

I get this repeatedly

I don’t think I’m the only one but if I ignore it then eventually other things seem to go wrong, though that may just be my perception. This happens so often that if I restart VS every time then I would spend more time restarting VS than using it. Having said that, it’s only happened three or four times in the last hour or two. Looking at the stack trace I see this —

Which looks like a Microsoft issue to me — I’ve removed Developer Analytical Tools from my installation of VS as that looked a likely culprit. So far so good but we will have to see. If that doesn’t work I will strip down VS as much as I possibly can and try again. So far this seems to have improved things but as its so arbitrary it’s hard to know for sure.

Time Wasted a few minutes per reboot — overall about 15 including time to fire up Rider and remove Analytical tools

9 Sep

Today my laptop is going for the Windows long boot for no obvious reason. There were some Lenovo updates yesterday but I didn’t install them. As a result I’m on the Mac. If only this had a higher res screen I’d be using it a lot more.

Time wasted Best part of half an hour — the time it takes the laptop to boot. It’s fine using the Mac but I know I will start using the Lenovo when it finally wakes up so I end up doing little bits on the Mac rather than real work

So today I was working on a library that depends on another library, I’d added a new enum to the dependency but the dependent library refused to see it. Even DotPeek refused to show it. The dependency is a fairly simple library that’s targeted at NetStandard2.0 and .NET Core 3.1 and the enum is a very simple one. I often use VSCode to edit this dependency for speed and usually all is well. The eventual fix for this issue was to rem out the enum and recreate it! No Idea why that worked but it did — time wasted 10 minutes trying various things.

Today when I have been using Rider, it keeps losing the connection with UpSource. I think this is a network issue as other things have seemed slow too.

I’ve been having trouble connecting Rider to YouTrack recently, it refuses point blank. The dialog isn’t helpful either, this is what I see

Personally I think this is about as unhelpful as it gets. I’ve no idea what the text above the server Url is. I guess that the Use P… checkbox is for using a password but where do I enter it and even if I do where would I put the user name? Equally Get Token isn’t working either. To add insult to injury UpSource works fine.

Overall this is a little frustrating but I can always use the web interface. What’s more frustrating is that when I use the other Jetbrains IDE’s I have to install YouTrack and Upsource again!! Given that I can sync settings and plugins, I set the Share option on (which I presume does this) and that one of the IDE’s knows I have Youtrack/Upsource why would I not want to use them from all IDE’s?

Time wasted a few minutes before I gave up.

I’m still getting the gold bar error from 1 Sep but so far today not the one from yesterday so maybe my fix worked!

I have an app that calls some third party web services, I need to change my proxy to be able to access this. The problem I have is that if I forget to do this before I open the solution then VS appears to cache the connection at some point, so my only option is to change the proxy then reboot VS.

Time wasted — 5–10 minutes to restart VS and get back to where I was.

10 Sep

Another long boot day! I’m mildly concerned by this and hoping its just one of the rare coincidences. I also have a number of Lenovo updates to install so I’ll try them too when it wakes up. That will give me an hour or so on the Mac.

I’m on the mac and I’m trying to update the servicestack dotnet tools and I’m getting an error!

The fourth option at least made me laugh. NuGet strikes again! Even on the Mac NuGet is killing me. It’s fast becoming the bane of my life and is seriously tempting me to try another language Go is the current favourite but at the moment I can’t afford the time. Anyway, back to this issue, although it’s not stated above, apparently there is a NuGet file somewhere which is trying to access an internal server (that I can’t access remotely from the Mac). I only found this out by trying to install the web tool, which for some reason gave a marginally more helpful error. Looking at the above error all I see is

Which in my very limited knowledge looks pretty normal. So I seem to be stuck with little or no chance of help. Go is looking even more tempting now. Fortunately! while all this was happening my Lenovo finally woke up.

I’ve just lost my internet connection on my laptop, the alexa device in the same room is working fine so although the Laptop is wired in I suspect its not the issue that its making out, it is however quite disruptive as I’m trying to work on a remote machine.

Time lost — a few minutes.

11 Sep

Another long boot day! This is an ominous sign, I think I’ll spend my half an hour or so googling

Talk about synchronicity! While googling, an MS survey came up and the last question was would you recommend Windows 10.

Time lost — another half an hour or more googling a new issue

Another new one on me —

This is on a Solution that’s been using NuGet for a significant number of years. I’m not aware of anything that’s changed. Googling showed that this has been around since at least early 2018. fortunately some suggestions in https://stackoverflow.com/questions/49439130/no-projects-supported-by-nuget-in-the-solution helped regain the NuGet GUI but VS then took a serious dislike to one of the projects in the solution. In order to resolve this, yet another VS Restart was required!

Time lost — about 15 minutes on two restarts and a quick google

I've had a couple of ArgumentException — gold bars today which has necessitated a VS restart. But just to end the day (and the week) I got a Could not load Type from Assembly error. This is a well known error but I can’t see anything wrong so I’m ending the week on a low. To add insult to injury the type it can’t load is in a custom library that has been in place for years.

Time lost. 15 minutes as It was too late to do anything else

14 Sep

Unsurprisingly today is another long boot day

I have an internal library that a large legacy Solution depends upon. I needed to add a fairly small enum to the library and wanted to use it from the Solution. Nothing complex or unusual here however the Solution completely refuses to acknowledge that the new enum exists despite being able to see everything else in the library. (it is a public enum, so no issue there).

Time Wasted — 10 minutes trying to figure out the issue, then applying a fudge to make it work.

Another gold bar to add to my collection, I haven’t seen this one for a while

The error log referred to doesn’t seem to have much of use. There are a couple of issues that appear to relate to MS software but it’s not at all clear what might have caused the above error.

Finally, when I was shutting down Rider decided to hang, it was completely unresponsive. I had a few instances open but none of them responded, though they didn’t do anything that prevented shutdown.

15 Sep

A bit disappointing that I have another long boot today, I have left the ethernet cable in (which is what usually causes it) and it still happened. Thankfully I used the time to do some updates on the Mac. One of these updates was Rider, when it started up it complained about the gitflow plugin. I hadn’t realised it was completely out of date and went about updating to a much more up to date version

Today it’s Paket’s turn. I have a new solution that I have converted to Paket. I manually added a library to the dependencies and the relevant references file, yet dotnet build failed to locate the library. The solution turned out to be to use Paket add <Library> which obviously does something I overlooked.

Time wasted, a couple of minutes.

This isn’t an entirely comfortable fit into this post however I wanted to make a note of it due to a couple of things. I’m in the process of getting to grips with Docker. I’m just about ok setting up prebuilt containers and using them so I wanted to try to make one of my own. Everything tells you how simple it is and VS and VSCode even have a command for it. The catch for me seems to be that I was using a console app. For some reason the stuff on the web largely assumes you want asp.net. I’m not sure how much difference this makes but basically I couldn’t get it working for my app. The app is a brand new .net core 3.1 console app based on a ServiceStack template. The app runs fine on its own. When I used VS, it refused to work at all and seems to download the wrong version of the container, though that may have just been for the specific question asked on GitHub. To add further insult, it turns out that there is a dependency on an MS library that is not available from normal sources — perhaps it’s using some NuGet black magic but my app is using Paket which can’t locate the nupkg that's referenced. It didn’t even want to download the previous version of the library, so I manually downloaded that and put it in my local NuGet server. I then stripped out the VS code and re-ran the docker integration in VS Code. This was slightly better behaved and did at least create a container, however that’s where it all started to go wrong. The container refused to start with no obvious reason — and nothing I could see in the logs. The only error I get is that it can’t find the specified version of .net core! Tweaking global.json didn’t help at all. As a docker novice I am pretty stuck now, the docker files on the web all look either remarkably similar or completely beyond my current knowledge level.

I then noticed that there was a new version of .net core LTS. I don’t know where this is announced but I only ever see it when I actively look. Installing this on the Lenovo was probably a mistake as it insists it needs a reboot afterwards. Other machines don’t do that, both Windows and Mac. So now I'm back on the Mac for a good half an hour or so.

NuGet has broken my Mac — well that’s a bit melodramatic but it’s not entirely untrue, though it’s behaviour is a bit like a virus. My Mac is only connected to my work network when I am physically at work. Currently it has no VPN access. This means that NuGet doesn’t play well with it as it is often trying to access servers that it can’t. That’s precisely what happened this time. For some reason that I may never fathom, when I do a dotnet tool install it tries to access a server on my work network and I get unable to load the serviceindex errors. This is in the brand new (as of a few minutes ago) installation of dotnet. In fact the Nuget.targets file seems riddled with issues. When I look in the offending file I see no reference whatsoever to the missing server!

16 Sep

Shock news! I’ve just saved some time. I updated my VS to the latest version and didn’t need to reboot. That’s the first time this has happened on my laptop.

Time saved! about half an hour (as it’s still doing the slow boot thing)

17 Sep

So I now have a workaround for the long boot, not used before as I wanted to confirm what was happening. Basically now I just close the lid which puts it to sleep. The bonus is that it boots faster than normal, the downside is that it will probably need rebooting every now and again.

Time saved — a few minutes per day

Time lost — half an hour per reboot

18 Sep

I have a bit of an issue now, as I am taking two weeks leave at short notice. So I have decided that when I get back on Tue 6th Oct I will continue for two more weeks so that I cover about a month.

7 Oct

So yesterday, all went well apart from some minor issues due to the need to change my password and the desperate need by VS to reboot my machine after an update!. Today we are back to the slow boot, but as I have been away for two weeks it gave me chance to update the Mac. It surprised me just how many updates there were.

I’m trying to get Visual Studio to open a solution when I have a different one open. I haven’t touched it for about 10 minutes as I was in a short meeting. Apparently its too busy to do anything I ask it. I wouldn’t mind but this is the very latest version as of yesterday.

8 Oct

My internet connection dropped, I first realised when Alexa stopped playing the radio station I listen to. This was rather unexpected as early last month, my ISP sent some engineers out to fix an issue with the line. The guys who came were great, they not only fixed the line they found an issue in the cabinet and fixed that too. The downtime only lasted about 20–30 minutes but it does make you realise how much we rely on the web these days, I don’t even have any music that’s locally accessible, it was very quiet for that half an hour. It’s a shame that nothing tells you when the connection is back, surely Alexa could do that. — Time wasted none as I was working offline

Outlook is having one of its tantrums today, if I happen to look at someone else’s calendar I keep getting a login screen to login as them, even when I have closed the calendar. Time wasted is minimal but it happens repeatedly and steals focus every time, it’s done it a few times while I am typing this so the annoyance factor is high.

I decided to reboot the laptop, as you will be aware this takes an appallingly long time so I fired up the Mac. My MacBook is obviously feeling left out by all of this and appears to want to prove it can be as disruptive as any other machine. It has started repeatedly asking for access to my keychain for various apps. This is at least as annoying as the Outlook issue. It always seems pretty poor to me that attempts to make authentication secure often make it more disruptive for legitimate users and has little or no effect on the hackers. For me I’m wondering whether to use post it notes with passwords on as to my knowledge, none of the hackers have ever been to my house and even if they have they haven’t been in my study.

OK so rebooting the laptop was a big mistake, after I finally got to login, it’s now asking for both Skype and Outlook logins doubly annoying. so in desperation I’ve downloaded the recovery assistant linked from here https://docs.microsoft.com/en-us/outlook/troubleshoot/authentication/continually-prompts-password-office-365 but that doesn’t work for my type of account, whatever that means! Finally I seem to have resolved this by setting a new profile for Outlook and deleting the sip folder for Skype

Time wasted about half an hour — looking for and trying solutions

9 Oct

Outlook still isn’t quite right but it’s better than yesterday

12 Oct

I’m avoiding rebooting by putting the machine to sleep. I don’t entirely trust this process (bad memories from long ago), so I shut all my apps down first. It’s not ideal but it seems to be doing the job for now

So today I’ve been working on an open source library that I have. I've done a fair chunk of work on it and it’s now refusing to Pack — it just gives the particularly unhelpful message

There are a variety of discussions around this one including this one which lays the door on Paket’s lap. Although I have sympathies with both sides it does seem a little disingenuous to do this as past experience suggests to me that its more likely to be some sort of undocumented change. Regardless of the source, the fix only seems to apply to .NET 5 which isn’t an LTS. I would have expected it to be applied to an LTS as well.

There are two workarounds for the issue that are suggested, one of which involves the hairy task of editing a file that clearly says at the top — DO NOT EDIT THIS IF YOU DON’T KNOW WHAT YOU ARE DOING — that’s enough to keep me away. I tried the option of using an older version of the sdk by editing global.json, fortunately that worked

Time wasted — about half an hour reading through long threads with differing suggested solutions

I’ve just opened an old library that hasn’t been touched for about a year. It’s a net standard 2.0 one and I’m pretty sure it’s in use so it should be fine, however Visual Studio disagreed with

I don’t currently have the time to investigate this

13 Oct

Paket has failed me! This is really a first and is somewhat disappointing. The error is

It’s disappointing as I have no interest in any version of .NET Core that isn’t an LTS. After a lot of messing around it turns out I was wrong — it’s not a Paket issue, which restores my faith. It’s an issue with an NUnit template. I was setting up a new Dotnet project and when I added the NUnit project it told me there was an update so I installed it — with the benefit of hindsight this was a foolish mistake. It’s this template that demands .NET 5, so I have to edit the template after I’ve used it so we have the correct TFM’s. Although this was frustrating, with hindsight it was a simple issue to resolve.

Time wasted — about an hour

For reasons I won’t go into I’m trying to rename a library. I’ve had to do this before and it went fairly straightforwardly. Basically I setup a new solution and copy all the code files I want into it. I then add in the dependencies. Normally this is a fairly straightforward process but for some reason with this project it’s not. How do I know this, well it won’t Pack, the build succeeds but there is no output and if I try from the console I get

and nothing more, no errors, no clues. Second time around it all worked fine!

Time wasted — around an hour

14 Oct

Today VS Bombed out completely, it just disappeared. I’m sure we have all had this occasionally and are thankful that it recovers pretty well. Amusingly it told me that there was a VS update when I restarted it.

OK it’s just bombed out again, this time I know what I did so I need to do some testing to see if it looks like a bug.

It’s definitely a (minor) bug, if you create a new project and put a hyperlink to an svg file into the icon line in properties, the application crashes.

Time wasted — about 10 minutes

15 Oct

I tried to setup my first ever live share session. Sadly, after 5–10 mins we failed to get it working and ended up using screen sharing. This isn’t something that I need to do often but it would be nice i fI could get it working.

Time wasted 5–10 minutes

Just discovered that you can’t delegate meetings in Outlook so that someone else can attend on your behalf. This is something that happens reasonably often so I can’t believe there is no official way to do it. Mind you, you still can’t schedule email timing either — GroupWise used to be able to do that!

Time wasted a minute or two looking for the setting then googling

16 Oct

VS has saved the best till last. Over the last few days I’ve been getting the VS error about something going wrong and needing to restart. I haven’t mentioned most of them on here as it’s become part of the new normal. Today however when it happened, VS refused to restart and came up with this one

which seems to be to be rather ironic as I was trying to restart it

Time wasted — probably 5–10 minutes in numerous VS restarts over the day

Summary

So in total I have lost around a full days work on the 20 days that it was enough for me to make comment and this is only because I have a second machine I can fire up. Obviously not everyone has this luxury. Of course I haven’t mentioned the times when an app tried to randomly tried to update itself — naturally this happens when I’m in a rush. Nor did I mention that my mouse has a mind of its own and occasionally shoots off across the screen, and so on.

As a not very scientific study this suggests to me that the first run I did of this was probably about right. My feeling is that although the emphasis has shifted and some things can obviously be done much more effectively, that for each of those there is a new issue or a niggle that’s disruptive. Many of the issues above just wouldn’t exist some years ago. Each of the issues I mentioned disrupted my flow, so in each case, the reality is that I lost more time than I stated in order to regain it.

Senior IT Officer for North Lincolnshire Council