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

switch to use class modal for configurations #536

Open
wants to merge 17 commits into
base: main
Choose a base branch
from

Conversation

junyuanz1
Copy link
Collaborator

No description provided.

@junyuanz1 junyuanz1 changed the title switch to use dataclass for configuration switch to use class modal for configurations Dec 7, 2024
@junyuanz1 junyuanz1 marked this pull request as ready for review December 7, 2024 07:35
@brndnmtthws
Copy link
Owner

At a glance this looks pretty good, but it's a big change so I will have to take some time to test everything and make sure it's working as expected.

@brndnmtthws
Copy link
Owner

brndnmtthws commented Dec 8, 2024

First thing I noticed is the config output is missing for these values (old output is shown below):

Screenshot 2024-12-08 at 14 02 33

Everything else appears to be o.k., but I want to test a bit more with live data.

The relevant code is here:

config_table.add_section()
config_table.add_row("[spring_green1]When contracts are ITM")
config_table.add_row(
"",
"Roll puts",
"=",
f"{config['roll_when']['puts']['itm']}",
)
config_table.add_row(
"",
"Roll puts always",
"=",
f"{config['roll_when']['puts']['always_when_itm']}",
)
config_table.add_row(
"",
"Roll calls",
"=",
f"{config['roll_when']['calls']['itm']}",
)
config_table.add_row(
"",
"Roll calls always",
"=",
f"{config['roll_when']['calls']['always_when_itm']}",
)

@brndnmtthws
Copy link
Owner

I did some more testing, and overall it looks good and seems to not have broken anything. I think we can merge this once the missing config output is added back.

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.

2 participants