LDAR-Sim / LDAR_Sim

MIT License
11 stars 22 forks source link

Emissions creation typerror fix #289

Closed ThomasGalesloot closed 3 months ago

ThomasGalesloot commented 3 months ago

Pull Request Key Information

Reason for change

Fix type-error that occur with emissions creation

What was changed

Add typecasting to avoid type-errors.

Intended Purpose

Prevent type-errors during runtime

Level of version change required

Patch

Testing Completed

Manual testing using modified sites file to produce error (Added emissions duration): facilities_Perm_for_test.csv

All other input are parameter were sourced from simple_test_case1

All unit tests passing: unit_test_results.txt

All E2E test passing: V4-simple_repairable_emissions_5f77e95675f2c4286e250f910aac2e7374cafc0c.log V4_simple_non_repairable_emissions_5f77e95675f2c4286e250f910aac2e7374cafc0c.log

Target Issue

N/A

Additional Information

N/A

ThomasGalesloot commented 3 months ago

Latest E2E test results: V4-simple_repairable_emissions_cac2f907ebce2287ff6df7ce8ed6716c85216475.log V4_simple_non_repairable_emissions_cac2f907ebce2287ff6df7ce8ed6716c85216475.log

Latest Unit test results: unit_test_results.txt

ThomasGalesloot commented 3 months ago

Please double check the sources.py for more self._emis_duration if you are going to hard cast it to a float.

Removed all typecasts except for the initial value setting