SRvSaha / CoWinVaccineSlotFinder

Cross-Platform Software to Fetch the Available Slots & Book the Appointment for COVID-19 Vaccination
https://shawt.io/r/sYv
MIT License
81 stars 32 forks source link

Configuration File Should be Validated before Proceeding with Slot Booking #34

Closed SRvSaha closed 3 years ago

SRvSaha commented 3 years ago

Is your feature request related to a problem? Please describe. Since the Configuration file appsettings.config takes in user input, so there is a chance that user has either not modified the configuration file itself or has provided with some incorrect value which was not expected. So, application should handle those scenarios before proceeding.

Example: Suppose user wants to search by District and has entered the values inside "Districts": {FOO, BAR}, but has forgotten to set to value of IsSearchToBeDoneByDistrict as true. In that case, the searching would not happen, while the user would be expecting that the App is searching.

Describe the solution you'd like Basically there should be some sort of semantic parser which parses the config and checks if the default values are overwritten in the config. If not, then it should let the user know which all configs are not overwritten and must be modified. Also, if defaults are overwritten and user is not providing the proper values after overwriting, App should inform the user about the issue so that it can be changed and the Application can be run again.

This is to be done fore Auth Module and FinderModules are called.

Describe alternatives you've considered N/A

Additional context Issue #19 #22 #24

SRvSaha commented 3 years ago

@iSatishYadav Can you please take this up?