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

Add pydantic and user input models #77

Merged
merged 17 commits into from
Nov 29, 2023
Merged

Add pydantic and user input models #77

merged 17 commits into from
Nov 29, 2023

Conversation

alanisaac
Copy link
Collaborator

@alanisaac alanisaac commented Sep 20, 2023

Creating a PR from our work this week, to see CI status and as a reminder for next week.

Copy link
Collaborator

@axiomizer axiomizer left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me besides my one comment

rules-engine/src/rules_engine/engine.py Outdated Show resolved Hide resolved
@axiomizer
Copy link
Collaborator

axiomizer commented Oct 18, 2023

As part of the outputs, we'll need information about each billing period: Whether the rules engine included that billing period, and the UA for that billing period

jkwan2011 and others added 12 commits November 14, 2023 23:51
Co-authored-by: Erika Nesse <erika-n@users.noreply.github.com>
Co-authored-by: Alan Pinkert <alanisaac@users.noreply.github.com>
Co-authored-by: Debajyoti Debnath <debajyotid2@users.noreply.github.com>
Co-authored-by: harry <harryzhu626@users.noreply.github.com>
Refactored docstrings to 72 character maximum.
Refactored if-else statement.

Co-authored-by: Erika Nesse <erika-n@users.noreply.github.com>
Co-authored-by: Nate <axiomizer@users.noreply.github.com>
Co-authored-by: harry <harryzhu626@users.noreply.github.com>
Co-authored-by: Debajyoti Debnath <debajyotid2@users.noreply.github.com>
Co-authored-by: Jeff Korenstein <jkoren@users.noreply.github.com>
Co-authored-by: Erika Nesse <erika-n@users.noreply.github.com>
Co-authored-by: harry <harryzhu626@users.noreply.github.com>
Co-authored-by: Debajyoti Debnath <debajyotid2@users.noreply.github.com>
Co-authored-by: Jonathan Kwan <jkwan2011@users.noreply.github.com>
Co-authored-by: Nate <axiomizer@users.noreply.github.com>
Co-authored-by: harry <harryzhu626@users.noreply.github.com>
Co-authored-by: Erika Nesse <erika-n@users.noreply.github.com>
Co-authored-by: Debajyoti Debnath <debajyotid2@users.noreply.github.com>
Co-authored-by: KKaempen <KKaempen@users.noreply.github.com>
Co-authored-by: Alan Pinkert <alanisaac@users.noreply.github.com>
alanisaac and others added 3 commits November 15, 2023 01:57
…ata class

Co-authored-by: Jonathan Kwan <jkwan2011@users.noreply.github.com>
Co-authored-by: Debajyoti Debnath <debajyotid2@users.noreply.github.com>
Co-authored-by: Erika Nesse <erika-n@users.noreply.github.com>
Co-authored-by: harry <harryzhu626@users.noreply.github.com>
date=row["Date"], temperature=row[weather_station] # type: ignore[arg-type]
)
result.append(item)
dates.append(row["Date"])
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we need to pass this to strptime?

alanisaac and others added 2 commits November 29, 2023 00:53
Co-authored-by: Debajyoti Debnath <debajyotid2@users.noreply.github.com>
Co-authored-by: Jonathan Kwan <jkwan2011@users.noreply.github.com>
@alanisaac alanisaac merged commit 1f36ec5 into main Nov 29, 2023
8 checks passed
@alanisaac alanisaac deleted the add_pydantic branch November 29, 2023 00:56
AdamFinkle pushed a commit to AdamFinkle/home-energy-analysis-tool that referenced this pull request May 22, 2024
* adding pydantic dependency

* Added user input models.

Co-authored-by: Erika Nesse <erika-n@users.noreply.github.com>
Co-authored-by: Alan Pinkert <alanisaac@users.noreply.github.com>
Co-authored-by: Debajyoti Debnath <debajyotid2@users.noreply.github.com>
Co-authored-by: harry <harryzhu626@users.noreply.github.com>

* Added SummaryOutput class.
Refactored docstrings to 72 character maximum.
Refactored if-else statement.

Co-authored-by: Erika Nesse <erika-n@users.noreply.github.com>
Co-authored-by: Nate <axiomizer@users.noreply.github.com>
Co-authored-by: harry <harryzhu626@users.noreply.github.com>
Co-authored-by: Debajyoti Debnath <debajyotid2@users.noreply.github.com>
Co-authored-by: Jeff Korenstein <jkoren@users.noreply.github.com>

* black

* Moved Pydantic models into split folder

Co-authored-by: Erika Nesse <erika-n@users.noreply.github.com>
Co-authored-by: harry <harryzhu626@users.noreply.github.com>
Co-authored-by: Debajyoti Debnath <debajyotid2@users.noreply.github.com>
Co-authored-by: Jonathan Kwan <jkwan2011@users.noreply.github.com>
Co-authored-by: Nate <axiomizer@users.noreply.github.com>

* updated pydantic models

* Refactor Home class in engine.py.

* changes from this session

* cleaned up code from halloween!

* added SummaryInput to home

* Fixed black

Co-authored-by: harry <harryzhu626@users.noreply.github.com>
Co-authored-by: Erika Nesse <erika-n@users.noreply.github.com>
Co-authored-by: Debajyoti Debnath <debajyotid2@users.noreply.github.com>
Co-authored-by: KKaempen <KKaempen@users.noreply.github.com>
Co-authored-by: Alan Pinkert <alanisaac@users.noreply.github.com>

* fix mypy

* added entry point functions, inclusion code conversion, and weather data class

Co-authored-by: Jonathan Kwan <jkwan2011@users.noreply.github.com>
Co-authored-by: Debajyoti Debnath <debajyotid2@users.noreply.github.com>
Co-authored-by: Erika Nesse <erika-n@users.noreply.github.com>

* updated tests based on new framework

Co-authored-by: harry <harryzhu626@users.noreply.github.com>

* fix lints

* fixed datetime parsing

Co-authored-by: Debajyoti Debnath <debajyotid2@users.noreply.github.com>
Co-authored-by: Jonathan Kwan <jkwan2011@users.noreply.github.com>

* mypy fix

---------

Co-authored-by: Jonathan Kwan <jkwan2011@users.noreply.github.com>
Co-authored-by: Erika Nesse <erika-n@users.noreply.github.com>
Co-authored-by: Alan Pinkert <alanisaac@users.noreply.github.com>
Co-authored-by: Debajyoti Debnath <debajyotid2@users.noreply.github.com>
Co-authored-by: harry <harryzhu626@users.noreply.github.com>
Co-authored-by: Nate <axiomizer@users.noreply.github.com>
Co-authored-by: Jeff Korenstein <jkoren@users.noreply.github.com>
Co-authored-by: KKaempen <KKaempen@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants