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 solvers #43

Merged
merged 4 commits into from
Aug 6, 2024
Merged

Add solvers #43

merged 4 commits into from
Aug 6, 2024

Conversation

anxolin
Copy link
Contributor

@anxolin anxolin commented Aug 5, 2024

Networks

Allow to add our supported networks to the CMS.

Screenshot at Aug 05 14-30-35

Solver

Model solvers.

Screenshot at Aug 05 14-29-04

After this PR

After merging the PR we should make a new step in the process to add new networks

Test

Run locally, and try to create the networks and a solver

@anxolin anxolin requested a review from a team August 5, 2024 13:33
@anxolin anxolin marked this pull request as ready for review August 5, 2024 13:33
Comment on lines 13 to 17
"attributes": {
"name": {
"type": "string",
"required": true
},
Copy link
Contributor

Choose a reason for hiding this comment

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

Can we add solverId field?
That should be unique and match the ids stored on the backend, to avoid another mapping on the frontend.
We could maybe rename this one to displayName and make it not required.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Can we add solverId field?

No problem

We could maybe rename this one to displayName

Fine with me, but why not just name?

and make it not required.

Why? I would hope they all have name, right?

Copy link
Contributor

Choose a reason for hiding this comment

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

Just name is fine.
I thought about being explicit it's not the same name/id used on the backend, which is for display purposes.
And I proposed to make it not required because we can use the solvedId in case one is not provided.

@anxolin anxolin requested a review from alfetopito August 5, 2024 14:36
Comment on lines 60 to 61
"default": 0,
"type": "integer"
Copy link
Contributor

Choose a reason for hiding this comment

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

Why an integer?

Sorry if I gave that impression.
My idea with this field is to match the ids used in the backend, which are actually strings.

For example, there's a solver named gnosis_1inch.

I want to use that as the id here, as for the name we could have Gnosis 1inch solver (that's why I proposed to change it to displayName.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I see, I can call it displayName no worries. What do I call this solverId? you are happy with solverId (normally ID are UUID or numbers so might be confusing). Alternative I could call this the name but might also be confusing.

Copy link
Contributor

Choose a reason for hiding this comment

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

I don't have anything better.
Yes, not numeric neither UUID, but still a unique identifier of the solver that's not meant to be nice for displaying.

@anxolin anxolin merged commit 8bd2052 into main Aug 6, 2024
3 checks passed
@alfetopito alfetopito deleted the add-solvers branch August 7, 2024 09:51
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