GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — eth_sendTransaction does not exist/is not available after calling mint_liquidity method. · Issue #364 · uniswap-python/uniswap-python

eth_sendTransaction does not exist/is not available after calling mint_liquidity method. #364

New issue
Copy link
New issue
Copy link
Open
Open
eth_sendTransaction does not exist/is not available after calling mint_liquidity method.#364
Copy link
Labels
bugSomething isn't workingSomething isn't working

Description

@SMohsenRazaviZ
SMohsenRazaviZ
opened on Jan 3, 2024
Issue body actions

Hello friends !
I'm having trouble interacting with the uniswap liquidity pool using uniswap-python. this is my code :

from web3 import Web3
from uniswap import Uniswap
from web3.middleware import geth_poa_middleware

from contracts import USDT, WMATIC

WALLET_ADDRESS = '...'
PK = '...'
VERSION = 3
PROVIDER = "https://polygon-mainnet.infura.io/v3/" +'INFURA_KEY'

AMOUNT = 0.5

w3 = Web3(Web3.HTTPProvider(PROVIDER))
uniswap = Uniswap(address=WALLET_ADDRESS, private_key=PK, version=VERSION, provider=PROVIDER)
uniswap.w3.middleware_onion.inject(geth_poa_middleware, layer=0)

pool = uniswap.get_pool_instance(token_0=WMATIC.address, token_1=USDT.address)

amount_0 = w3.to_wei(AMOUNT, WMATIC.get_decimal_unit())
amount_1 = uniswap.get_price_input(WMATIC.address, USDT.address, qty=amount_0)

nft = uniswap.mint_liquidity(pool=pool, amount_0=amount_0, amount_1=amount_1, tick_lower=0, tick_upper=887220)

print(nft)

and The error is :
web3.exceptions.MethodNavailable: {'code': -32601, 'message': 'eth_sendTransaction method does not exist/not available'}
I tried other RPCs and other pairs, but the problem still exists.

Activity

  1. SMohsenRazaviZ
    added
    bugSomething isn't workingSomething isn't working
    on Jan 3, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingSomething isn't working

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions

      You are visitor 01402503 — GeezerVison does not store the pages you look up.
      Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.