Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enhance Error Handling #161

Closed
3 of 4 tasks
codingfabi opened this issue May 4, 2024 · 1 comment
Closed
3 of 4 tasks

Enhance Error Handling #161

codingfabi opened this issue May 4, 2024 · 1 comment

Comments

@codingfabi
Copy link
Contributor

codingfabi commented May 4, 2024

We should validate and intercept certain user inputs and also prevent crashes by throwing verbose exception. Some Ideas:

  • Define invalid combinations of function parameters (e.g. transportationMode="plane" and fuelType="diesel"). We should write an evaluation util function for this that checks for certain, obvious/common combinations that do not make sense (see also: Method to get valid options for a combination of parameters #137).
  • Throw UnknownEmissionFactor exception when no EmissionFactor is found.
  • Throw exception on Unknown parameters (Unknown transportation mode or unknown fueling type)
  • Handle common routing exceptions:
    - [ ] Invalid ORS key
    - [ ] Invalid Latitude/Longitude input
    - [ ] Adress not found
@redfrexx
Copy link
Member

redfrexx commented May 6, 2024

Improved error handling related to parameter combinations for emission factors in #173 . Improvement of error handling related to routing is now continued in new issue #189 .

@redfrexx redfrexx closed this as completed May 6, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants