tulleuchen / jirastopwatch

Not MORE timetracking - just EASIER timetracking
http://jirastopwatch.com
Apache License 2.0
142 stars 96 forks source link

Crash on startup #61

Closed Shulyaka closed 7 years ago

Shulyaka commented 7 years ago

Hi!

The application won't start anymore. It says "Jira StopWatch encountered an unhandled error". Below is the part of the log file. Note that it is in Russian for some reason. The "Система конфигурации не прошла инициализацию" means 'Configuration system has not been initialized'.

07.03.2017 16:16:52: Unhandled UI Exception
07.03.2017 16:16:52: Система конфигурации не прошла инициализацию
07.03.2017 16:16:52:    в System.Configuration.ClientConfigurationSystem.OnConfigRemoved(Object sender, InternalConfigEventArgs e)
   в System.Configuration.Internal.InternalConfigRoot.OnConfigRemoved(InternalConfigEventArgs e)
   в System.Configuration.Internal.InternalConfigRoot.RemoveConfigImpl(String configPath, BaseConfigurationRecord configRecord)
   в System.Configuration.BaseConfigurationRecord.GetSectionRecursive(String configKey, Boolean getLkg, Boolean checkPermission, Boolean getRuntimeObject, Boolean requestIsHere, Object& result, Object& resultRuntimeObject)
   в System.Configuration.BaseConfigurationRecord.GetSection(String configKey)
   в System.Configuration.ClientConfigurationSystem.System.Configuration.Internal.IInternalConfigSystem.GetSection(String sectionName)
   в System.Configuration.ConfigurationManager.GetSection(String sectionName)
   в System.Configuration.ClientSettingsStore.ReadSettings(String sectionName, Boolean isUserScoped)
   в System.Configuration.LocalFileSettingsProvider.GetPropertyValues(SettingsContext context, SettingsPropertyCollection properties)
   в System.Configuration.SettingsBase.GetPropertiesFromProvider(SettingsProvider provider)
   в System.Configuration.SettingsBase.GetPropertyValueByName(String propertyName)
   в System.Configuration.SettingsBase.get_Item(String propertyName)
   в System.Configuration.ApplicationSettingsBase.GetPropertyValue(String propertyName)
   в System.Configuration.ApplicationSettingsBase.get_Item(String propertyName)
   в StopWatch.Properties.Settings.get_UpgradeRequired()
   в StopWatch.Settings..ctor()
   в StopWatch.MainForm..ctor()
   в StopWatch.Program.Main()
Shulyaka commented 7 years ago

Reinstall does not help

carstengehling commented 7 years ago

Your config file has probably become corrupt. Try to delete this folder and start the application again:

C:\Users\\AppData\Local\StopWatch

This problem should be fixed in the latest release. What version are you running?

Shulyaka commented 7 years ago

You are right, after removing of the config file it works fine again. However it would be good if the application would recover automatically on this kind of error, or prevent the config file from corruption. So it's now more of a feature request than an issue. Should I close the issue or leave it open? I think I had a power outage when it broke. I'm using the latest version 1.9.0.

carstengehling commented 7 years ago

Just keep it open. I use the built-in config system of .net, and it is a bit "black box". But I'll figure something out.

carstengehling commented 7 years ago

I just remembered, that this has already been fixed and will be part of the next release.

See commit here: https://github.com/carstengehling/jirastopwatch/commit/d5d15ba2c1cc108e08f1d96cd9b3cf9083e8624e