Sitecore Command Line error on dotnet sitecore login

Hey fellow developers, this is a very short post 🙂
I recently got an error when trying to do a dotnet sitecore login.

Unhandled exception: System.Exception: Unhandled exception
 ---> System.NullReferenceException: Object reference not set to an instance of an object.
   at Sitecore.DevEx.Configuration.FilesystemConfigurationManager.ReadRootConfiguration(Stream rootConfigurationStream, Stream userConfigurationStream, String filePath) in C:\BA\ca7111d945a16af4\src\Sitecore.DevEx.Configuration\FilesystemConfigurationManager.cs:line 82
   at ...

This was indeed strange, I have never seen this before.

After tons of hair-pulling, I found the culprit. It turned out to be the user.json file in the .sitecore folder. I had to delete the user.json file, after that dotnet sitecore login worked like a charm(created a new user.json file)

That’s all for now folks 😊


Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.