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

Fix handling of Solidly Factory ABI for equalizer & scale #373

Conversation

Lesigh-3100
Copy link
Collaborator

Fixed handling of factory contract for scale & equalizer

@Lesigh-3100 Lesigh-3100 added the bug Something isn't working label Feb 14, 2024
@Lesigh-3100 Lesigh-3100 self-assigned this Feb 14, 2024
Copy link
Collaborator

@barakman barakman left a comment

Choose a reason for hiding this comment

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

In each one of the following functions:

  • get_abi
  • get_factory_abi
  • get_fee

Split the handling of self.exchange_name into the following 6 cases:

  • if "velocimeter_v2"...
  • elif "scale_v2"...
  • elif "equalizer_v2"...
  • elif "solidly_v2"...
  • elif "aerodrome_v2"...
  • else: raise an exception

And handle each case completely separately even if it happens to be identical to one of the other cases.

Please use == only (no "if in list" or similar).

fastlane_bot/events/exchanges/solidly_v2.py Outdated Show resolved Hide resolved
fastlane_bot/events/exchanges/solidly_v2.py Show resolved Hide resolved
fastlane_bot/events/exchanges/solidly_v2.py Outdated Show resolved Hide resolved
fastlane_bot/events/exchanges/solidly_v2.py Outdated Show resolved Hide resolved
@barakman barakman self-requested a review February 14, 2024 16:07
fastlane_bot/events/exchanges/solidly_v2.py Outdated Show resolved Hide resolved
fastlane_bot/events/exchanges/solidly_v2.py Outdated Show resolved Hide resolved
fastlane_bot/events/exchanges/solidly_v2.py Outdated Show resolved Hide resolved
@barakman barakman self-requested a review February 15, 2024 09:30
fastlane_bot/events/exchanges/solidly_v2.py Outdated Show resolved Hide resolved
fastlane_bot/events/exchanges/solidly_v2.py Outdated Show resolved Hide resolved
fastlane_bot/events/exchanges/solidly_v2.py Outdated Show resolved Hide resolved
@Lesigh-3100 Lesigh-3100 merged commit bd4e6f7 into fantom-rpc-flashloan-configs Feb 15, 2024
1 check passed
@Lesigh-3100 Lesigh-3100 deleted the 372-incorrect-solidly-factory-abi-used-for-scale-equalizer branch February 15, 2024 11:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants