Coder Social home page Coder Social logo

pancaketrade's Introduction

PancakeTrade - Limit orders and more for PancakeSwap on Binance Smart Chain

Docker Image CI Linting

PancakeTrade helps you create limit orders and more for your BEP-20 tokens that swap against BNB, BUSD and USDT on PancakeSwap. The bot is controlled by Telegram so you can interact from anywhere.

screenshot

DISCLAIMER

This software is for educational purposes only. Do not risk money which you are afraid to lose. USE THE SOFTWARE AT YOUR OWN RISK. THE AUTHORS AND ALL AFFILIATES ASSUME NO RESPONSIBILITY FOR YOUR TRADING RESULTS.

We strongly recommend you to have coding and Python knowledge. Do not hesitate to read the source code and understand the mechanism of this bot.

Features

The bot provides a lot of convenience trading features including:

  • Tokens balance and price shown in status messages
  • Price tracking relative to buy transaction
  • Ability to make buy and sell limit orders including trailing stop loss
  • Automatic smart price selection in case liquidity is available in BNB, BUSD and USDT (list could be extended in the future)
  • Automatic approval for selling
  • Assign emoji to each token to differentiate them easily
  • Default slippage set on a token basis for faster order creation
  • Charts links for each token

Requirements

In order to use this bot, you will need the following:

  • A server or computer that can run the script continuously (linux or macOS, as well as WSL have been tested)
  • A Telegram bot token (interact with @BotFather)
  • Your Telegram chat ID/user ID (interact with @userinfobot)

If you choose to use the Docker image, you'll just need docker installed, see the section below.

If you choose to run the script with Python, you'll need the following:

  • Python version between 3.7.2 and 3.9.x
  • Poetry
  • Optional: git to clone this repository, you can also download the source from the github website.

Quick Start

Before you start, make sure you have your Telegram Bot token + user ID available. Initiate the chat with your bot on Telegram (click the "Start" button) to initialize the chat ID before you start the bot the first time.

Run the following commands

git clone https://github.com/beeb/pancaketrade.git
cd pancaketrade
poetry install --no-dev
cp user_data/config.example.yml user_data/config.yml

Next, open the config.yml file inside the user_data folder with a text editor and populate the secrets section.

The bot needs your wallet's private key in order to sign and execute orders on your behalf. You have multiple options to do so:

  • You can run the poetry run trade command as-is and enter your private key in the prompt that will be shown each time the bot is started (only stored in memory)
  • You can provide an environment variable named WALLET_PK. For this multiple options:
    • You can create a .env file in the root of the project (same folder as pyproject.toml) and enter your private key in that file (which is excluded from git): WALLET_PK=123abcd...
    • You can prepend the command with the environment variable (not recommended as this will be stored in your shell history): WALLET_PK=123abcd... poetry run trade
    • You can use a service to run the bot, see the relevant section below

The private key is not the same as the seed words/mnemonic. You need the 64-characters hexadecimal private key.

Your wallet address will be inferred from the private key and doesn't need to be provided.

Run the bot:

poetry run trade

You will receive a notification in the Telegram chat after entering your private key. You can then start by adding your tokens with the /addtoken chat command.

The other most useful command is the /status command that will display all your tokens and the existing orders.

Configuration file

The script looks for a file named config.yml located inside the user_datafolder by default. You can pass another file path to the trade command as a positional argument.

The only parameter that is not self-explanatory is min_pool_size_bnb. Some tokens have multiple liquidity pools with different pairs, like BNB and BUSD. However, sometimes the LP with a given base token has very little liquidity, which means that the price is very volatile and price impact is large. In order to avoid swapping on the pair that has little liquidity, the bot checks that at least min_pool_size_bnb is staked in the LP. If that's not the case, the bot will use another LP when possible.

The update_messages parameter will update the status messages every 30 seconds if set to true. If you have trouble with the inline buttons not working, this means this bot token is not able to update messages anymore. It's unclear what the reason is, but it happened a few times to the developer and testers of this bot. The solution is to create a new bot token and try again, or disable update_messages (not ideal).

---
bsc_rpc: 'https://bsc-dataseed.binance.org:443' # you can use any BSC RPC url you want
min_pool_size_bnb: 25 # PancakeSwap LPs that have less than 25 BNB will not be considered
max_price_impact: 0.05 # if price impact is above 5%, order will not execute
monitor_interval: 5 # the script will check the token prices with this interval in seconds
update_messages: true # status messages will update periodically to show current values
price_in_usd: true # input, show and track prices in USD/token instead of BNB/token
charts: # these are all the chart links that can be included in status messages. Remove the ones you don't need
  - poocoin
  - bogged
  - dexguru
  - dextools
  - dexscreener
secrets:
  telegram_token: 'enter_your:bot_token' # enter your Telegram Bot token
  admin_chat_id: 123456 # enter your chat ID/user ID to prevent other users to use the bot

Updating the bot

When a new version is released, if you cloned the repository with git, you can simply perform a git pull on the master branch. After that, run the poetry install --no-dev command again to update dependencies.

Use docker

This bot now gets published as docker images on Docker Hub.

Before you start, make sure you have your Telegram Bot token + user ID available. Initiate the chat with your bot on Telegram (click the "Start" button) to initialize the chat ID before you start the bot the first time.

Steps to use docker:

  1. Copy the example docker-compose.example.yml file in this repository, rename it to docker-compose.yml
  2. Create a file named .env next to your docker-compose file and insert your private key: WALLET_PK=123abc...
  3. Create a user_data folder if it doesn't already exist, and create your config.yml file inside (see previous section).
  4. Run the service with docker-compose up -d.

Note: the bot will create a file for the database named pancaketrade.db inside the user_data folder on your local machine. Do not delete or move that file because it holds all your token configurations and orders data. This is the file to back up if you want to move the bot elsewhere, etc.

Run as a service

On systems that support systemd, you can use the included pancaketrade.service file to run this script as a service.

cp pancaketrade.service ~/.config/systemd/user/
# edit the new file in .config/systemd/user with your wallet private key
systemctl --user start pancaketrade.service
systemctl --user enable pancaketrade.service # run at launch

Donations

If you feel like this project has helped you and you wish to donate to the developer, you can do so on the Ethereum or Binance Smart Chain networks at the address:

0x026E539B566DcFF02af980d938deCcb11255d519

Thanks for your contribution!

Contribute

In order to contribute, make sure you install dev dependencies with poetry install. This repo is setup to use pre-commit hooks, please install them with pre-commit install before committing.

To add your contribution, fork the repo, create a new branch off of develop and work in there, then create a pull request against the develop branch of this repo.

pancaketrade's People

Contributors

beeb avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

pancaketrade's Issues

maximum number of running instances reached (1)

Hi,

Thank you for this great software!
running it from docker. sometimes got these warnings.

WARNING |Execution of job "TokenWatcher.monitor_price (trigger: interval[0:00:05], next run at: 2021-10-25 09:55:53 UTC)" skipped: maximum number of running instances reached (1)

After a container stop-start its gone.

Maybe I ask too much /status in telegram?

regards
Istvan

True Decimal Price

Hello, Really loving this BOT. First off have to say incredible work and thank you for putting it out there to everyone!

I was curious at the moment the price displays are in scientific notation and was wondering if maybe it could be displayed in the true decimal token value. I can understand that potentially some coins are so low on the decimal it might be hard to read, but at times knowing the USD value to get a better gauge on the price.

Thank you!

New coin alert?

Hi,
congratulations, great job!
I was wondering if it might be interesting to add a monitor to search for new tokens just placed on the pancakeswap market with an alert on the bot and the ability to buy them immediately

(ISSUE) slippage

How to set slipage like this 0.1 % or 0.5 % , in pancakeswap it posible and i trade succesfully.

received a message "Prevented user 842900455 to interact" . is someone trying to hack?

hi received a message "Prevented user 842900455 to interact"

is now my pk is safe? my funds are safe?

thanks

Please confirm the following

  • I am on the latest stable release of pancaketrade
  • I have searched the issues and cannot find a similar one
  • I have read the entire Readme and followed all installation instructions

Setup (please complete the following information):

  • OS and version:
  • Pancaketrade version:

Describe the bug
A clear and concise description of what the bug is.

To Reproduce
Steps to reproduce the behavior:

  1. ...
  2. ...

Expected behavior
A clear and concise description of what you expected to happen.

Screenshots
If applicable, add screenshots to help explain your problem.

Additional context
Add any other context about the problem here.

Sell Order by USD Value

I've always thought that at times when I'm holding a coin instead of wanting it to hit a certain price point and then sell, it would be better to understand if the sum of the balance of the token hits a certain USD value and then it could sell. for example, you set a sell order for selling the token if it reaches a total USD value of $200 dollars or something. Thank you!

Trying to sell more than available

Currently testing with a wallet that has 2949.984xxxx MTV in it. The issue may be in the floor function of a number.
Trying to sell all of it results in:

Selling 2,950.0 MTV...

⛔️ Exception while handling an update
{'code': -32000, 'message': 'insufficient funds for gas * price + value'}

Also entering smaller amount not working. Seems like the bot can't sell anymore I wonder if it's because of the UDST path:

Selling 2,950.0 MTV...

⛔️ Exception while handling an update
{'code': -32000, 'message': 'insufficient funds for gas * price + value'}

Selling 2,850.0 MTV...
⛔️ Exception while handling an update
{'code': -32000, 'message': 'insufficient funds for gas * price + value'}

OK, I will sell 2,800.0 MTV (~$64.38).
Confirm the order below!

✅ Order #1 was added successfully!

🔸 Trying to sell 2,800.0 MTV...

Not it hangs here and does nothing

/status bring this for orders:
💰 #1: MTV = market price - limit sell 2,800.0 MTV

This is the stack trace:
Traceback (most recent call last):
File "/usr/local/lib/python3.9/threading.py", line 973, in _bootstrap_inner
self.run()
File "/usr/local/lib/python3.9/threading.py", line 910, in run
self._target(*self._args, **self._kwargs)
File "/app/pancaketrade/watchers/order.py", line 240, in sell
res, bnb_out, txhash_or_error = self.net.sell_tokens(
File "/app/pancaketrade/network/bsc.py", line 546, in sell_tokens
receipt = self.sell_tokens_with_params(
File "/app/pancaketrade/network/bsc.py", line 603, in sell_tokens_with_params
tx = self.build_and_send_tx(func=func, tx_params=params)
File "/app/pancaketrade/network/bsc.py", line 722, in build_and_send_tx
return self.w3.eth.send_raw_transaction(signed_tx.rawTransaction)
File "/app/.venv/lib/python3.9/site-packages/web3/module.py", line 57, in caller
result = w3.manager.request_blocking(method_str, params, error_formatters)
File "/app/.venv/lib/python3.9/site-packages/web3/manager.py", line 160, in request_blocking
raise ValueError(response["error"])
ValueError: {'code': -32000, 'message': 'insufficient funds for gas * price + value'}

(ERROR) Giant slippage

I requested a sell order and then this happened: It was supposed to swap for $106 dollars but swapped for $85 Dollars. This would be a very high slippage which was set for 1%! Was it a bug?

Screenshot_2021-10-13-19-16-46-621_io metamask
Screenshot_2021-10-13-19-16-59-166_org telegram messenger

HTTPError Message

Hello, so I've been using this for a time and I get this over a long period of time and usage. not exactly sure what causes it or why it occurs but I do know it's something that shows up after a long time of running the bot.

2021-07-18 04:35:47 ERROR |Exception during message update: urllib3 HTTPError ('Connection aborted.', ConnectionResetError(10054, 'An existing connection was forcibly closed by the remote host', None, 10054, None)) 2021-07-18 06:54:37 ERROR |Error while getting Updates: urllib3 HTTPError ('Connection aborted.', ConnectionResetError(10054, 'An existing connection was forcibly closed by the remote host', None, 10054, None)) 2021-07-18 06:54:37 ERROR |Exception while handling an update 2021-07-18 06:54:37 ERROR |urllib3 HTTPError ('Connection aborted.', ConnectionResetError(10054, 'An existing connection was forcibly closed by the remote host', None, 10054, None)) 2021-07-18 06:54:37 ERROR |An uncaught error was raised while handling the error. Traceback (most recent call last): File "C:\Users\migue\Documents\GitHub\pancaketrade\.venv\lib\site-packages\telegram\ext\dispatcher.py", line 536, in process_update self.dispatch_error(None, update) File "C:\Users\migue\Documents\GitHub\pancaketrade\.venv\lib\site-packages\telegram\ext\dispatcher.py", line 810, in dispatch_error callback(update, context) File "C:\Users\migue\Documents\GitHub\pancaketrade\pancaketrade\bot.py", line 407, in error_handler chat_message(update, context, text=f'⛔️ Exception while handling an update\n{context.error}', edit=False) File "C:\Users\migue\Documents\GitHub\pancaketrade\pancaketrade\utils\generic.py", line 74, in chat_message assert update.effective_chat AttributeError: 'NoneType' object has no attribute 'effective_chat' 2021-07-18 06:54:47 ERROR |Exception during message update: urllib3 HTTPError ('Connection aborted.', ConnectionResetError(10054, 'An existing connection was forcibly closed by the remote host', None, 10054, None)) 2021-07-18 06:55:09 ERROR |Error while getting Updates: urllib3 HTTPError ('Connection aborted.', ConnectionResetError(10054, 'An existing connection was forcibly closed by the remote host', None, 10054, None)) 2021-07-18 06:55:09 ERROR |Exception while handling an update 2021-07-18 06:55:09 ERROR |urllib3 HTTPError ('Connection aborted.', ConnectionResetError(10054, 'An existing connection was forcibly closed by the remote host', None, 10054, None)) 2021-07-18 06:55:09 ERROR |An uncaught error was raised while handling the error. Traceback (most recent call last): File "C:\Users\migue\Documents\GitHub\pancaketrade\.venv\lib\site-packages\telegram\ext\dispatcher.py", line 536, in process_update self.dispatch_error(None, update) File "C:\Users\migue\Documents\GitHub\pancaketrade\.venv\lib\site-packages\telegram\ext\dispatcher.py", line 810, in dispatch_error callback(update, context) File "C:\Users\migue\Documents\GitHub\pancaketrade\pancaketrade\bot.py", line 407, in error_handler chat_message(update, context, text=f'⛔️ Exception while handling an update\n{context.error}', edit=False) File "C:\Users\migue\Documents\GitHub\pancaketrade\pancaketrade\utils\generic.py", line 74, in chat_message assert update.effective_chat AttributeError: 'NoneType' object has no attribute 'effective_chat'

image

Show position % increase/decrease in status?

Love the work you've done so far!

Would you consider adding the % increase/decrease of an open position in the status?

Also are pull requests welcome, or would you prefer to work on this alone?

Thanks!

Error at running the bot

I am having the following problem when I execute the command: poetry run trade
Any ideas how to sort this out?
Thanks a lot!!
Python Version 3.9.
Captura de pantalla 2021-10-29 223854

[Error] poetry run trade

Hi, I followed all the instructions in the readme document I am working in WSL, I have python 3.7.1 and poetry 11.1.1 but I am keeping this error message: The virtual environment found in /mnt/c/users/ivan/desktop/pancaketrade-master 1/.venv seems to be broken.
Recreating virtualenv pancaketrade in /mnt/c/users/ivan/desktop/pancaketrade-master 1/.venv (see the attached file for full error message)

Does anyone have any solutions?
error

Add Passphrase when starting the bot.

Add Passphrase when starting the bot.

it would be interesting if the user, when interacting with the bot, was asked for the passphrase of the wallet to initiate transactions..

I understand that when starting the project on linux the passphrase is passed or via the conf file... but the bot could request this information (giving a little more sense of security for those who will use the bot).

Example:

to /start - bot prompts for wallet passphrase....

Config monitor interval

I noticed an issue when you change the monitor_interval in the config file to 1 the bot crashes and gives a typerror File "C:\Users\migue\Documents\GitHub\pancaketrade\.venv\lib\site-packages\apscheduler\job.py", line 196, in _modify raise TypeError('misfire_grace_time must be either None or a positive integer') TypeError: misfire_grace_time must be either None or a positive integer

image

Github Docker Workflow failing

Wondering, I'm doing submissions and noticing the docker is giving a username and error, never seen it before. was this cause of me forking or something. I honestly have never messed with docker or GitHub workflows before. Thanks!

image

[request] Determine if there is a maximum transaction limit

Hello! Your project is fantastic, thank you for putting so much work into this. I have a request, not sure if it's feasible:

I've been in a couple tokens now where I set up a limit sell and it doesn't execute because the dev put a max transaction limit into the contract. Do you know if it's possible to check for something like this, and then only sell the maximum number of tokens allowed?

Different LPs on Pancake

Hi,
First of all, nice job on the bot.
One question I have is: is it possible to support different LP on the pancake swap? (maybe a silly question)
Also, I'm not very sure, but I think for example MTV/BNB and MTV/USDT are different LP for a single coin? (see screen)

Proposal: when you add a coin you can select which LP to use.

Add feature to setup price movement alarms

This feature would allow the user to set a price movement alarm for each token, whereby a telegram message would be issued if the price moves up or down by a certain percentage compared to the last reported value.

When a notification is issued, the current price is used as the new reference for monitoring the price change. When the price moves up or down again by the given percentage, a new notification is issued.

If the token has a "price at buy" value, the notification can include the current profit/loss compared to buying price in the notification.

Gas Estimating warning on all sells

2021-07-30 05:39:08 WARNING |Error estimating gas limit, trying again with alternative method: execution reverted: Pancake: K

Just wanted to point this out and see if its normal but on every single sell that bot does this pops up for me. Thanks!

Define gas Wei in config file

Hey man, First of all thanks for the great tool! I was wondering If there's a simple way to define gas price in wei, since its volatile, last trade I paid 3x the current "normal" price. Maybe for next Versions it could be choosen thought a variable in the config file.

Thanks again!! Everything working good.

Telegram group for this bot

Hi,

do you plan to initiate a telegram group for this bot? I have seen other bot projects doing this.
Would be nice to chat and help each other there.

Thank you for developing the bot!

"Buy/Sell now" hangs

Please confirm the following

  • I am on the latest stable release of pancaketrade
  • I have searched the issues and cannot find a similar one
  • I have read the entire Readme and followed all installation instructions

Setup (please complete the following information):

  • OS and version: Raspbian 10
  • Pancaketrade version: 0.6.1

Describe the bug
Sometimes when you try to use the "Buy/Sell now" function and select the token you want to buy or sell, it just hangs with the loading wheel and stops (times out) after some seconds. Only workaround I found so far is to restart the service and it works again.

To Reproduce
Steps to reproduce the behavior:

  1. Click on "Buy/Sell now" button
  2. Click on the desired token
  3. It hangs (but it only happens sometimes, it normally works)

Expected behavior
It should continue to ask details (amount to be bought/sell.. etc) just like when it works as expected.

Screenshots
Don't have ATM but I will post them as soon as it happens to me again.

Additional context
As I said it's an occasional problem, not happens every time. But when it happens it forces you to restart the service.

warning eror

WARNING |Retrying (Retry(total=0, connect=None, read=None, redirect=None, status=None)) after connection broken by 'SSLError(SSLCertVerificationError(1, '[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: certificate has expired (_ssl.c:1131)'))': /

is this because my connection?

[feature] auto slippage or set several slippage

Hi , could you please add smart try different slippage function when buy/sell now or make order ?
sometimes , the slippage often changes very large such as 10-13% during volatile price .
so ,i wish a feature that allows me to set slippage scope when i bue/sell now or make order.
Thanks.

Error while running "poetry run trade"

I'm getting this error on running poetry run trade.

2021-11-14 13:50:17 INFO |Bye!
Traceback (most recent call last):
File "", line 1, in
File "C:\Users\HACKER\Desktop\beeb-pancaketrade-558a540.venv\lib\site-packages\click\core.py", line 829, in call
return self.main(*args, **kwargs)
File "C:\Users\HACKER\Desktop\beeb-pancaketrade-558a540.venv\lib\site-packages\click\core.py", line 782, in main
rv = self.invoke(ctx)
File "C:\Users\HACKER\Desktop\beeb-pancaketrade-558a540.venv\lib\site-packages\click\core.py", line 1066, in invoke
return ctx.invoke(self.callback, **ctx.params)
File "C:\Users\HACKER\Desktop\beeb-pancaketrade-558a540.venv\lib\site-packages\click\core.py", line 610, in invoke
return callback(*args, **kwargs)
File "C:\Users\HACKER\Desktop\beeb-pancaketrade-558a540\pancaketrade\trade.py", line 28, in main
config = read_config(config_file)
File "C:\Users\HACKER\Desktop\beeb-pancaketrade-558a540\pancaketrade\utils\config.py", line 82, in read_config
data = yamale.make_data(config_file_path)
File "C:\Users\HACKER\Desktop\beeb-pancaketrade-558a540.venv\lib\site-packages\yamale\yamale.py", line 29, in make_data
raw_data = readers.parse_yaml(path, parser, content=content)
File "C:\Users\HACKER\Desktop\beeb-pancaketrade-558a540.venv\lib\site-packages\yamale\readers\yaml_reader.py", line 35, in parse_yaml
return parse(f)
File "C:\Users\HACKER\Desktop\beeb-pancaketrade-558a540.venv\lib\site-packages\yamale\readers\yaml_reader.py", line 11, in pyyaml
return list(yaml.load_all(f, Loader=Loader))
File "C:\Users\HACKER\Desktop\beeb-pancaketrade-558a540.venv\lib\site-packages\yaml_init
.py", line 130, in load_all
yield loader.get_data()
File "C:\Users\HACKER\Desktop\beeb-pancaketrade-558a540.venv\lib\site-packages\yaml\constructor.py", line 45, in get_data
return self.construct_document(self.get_node())
File "yaml_yaml.pyx", line 699, in yaml._yaml.CParser.get_node
File "yaml_yaml.pyx", line 725, in yaml._yaml.CParser._compose_document
File "yaml_yaml.pyx", line 776, in yaml._yaml.CParser._compose_node
File "yaml_yaml.pyx", line 892, in yaml._yaml.CParser._compose_mapping_node
File "yaml_yaml.pyx", line 905, in yaml._yaml.CParser._parse_next_event
yaml.scanner.ScannerError: while scanning a simple key
in "user_data\config.yml", line 6, column 1
could not find expected ':'
in "user_data\config.yml", line 7, column 17

Can you clarify what's this???
image

receiving this warning : connection pool is full, discarding connection: bsc-dataseed.binance.org.

receiving this warning : connection pool is full, discarding connection: bsc-dataseed.binance.org.

Receiving after changing nodes even with getblock.io node.

Help is appreciated. Thanx

Please confirm the following

  • I am on the latest stable release of pancaketrade
  • I have searched the issues and cannot find a similar one
  • I have read the entire Readme and followed all installation instructions

Setup (please complete the following information):

  • OS and version:
  • Pancaketrade version:

Describe the bug
A clear and concise description of what the bug is.

To Reproduce
Steps to reproduce the behavior:

  1. ...
  2. ...

Expected behavior
A clear and concise description of what you expected to happen.

Screenshots
If applicable, add screenshots to help explain your problem.

Additional context
Add any other context about the problem here.

No command poetry found

i jave succesfully installed poetry 1.1.9
but, this happend
No command poetry found
how to fix it
im noob btw, ty before

another help

Traceback (most recent call last):
File "", line 1, in
File "/usr/lib/python3.8/importlib/init.py", line 127, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File "", line 1014, in _gcd_import
File "", line 991, in _find_and_load
File "", line 975, in _find_and_load_unlocked
File "", line 671, in _load_unlocked
File "", line 848, in exec_module
File "", line 219, in _call_with_frames_removed
File "/home/mint/Downloads/pancaketrade-master/pancaketrade/init.py", line 6, in
version = version('pancaketrade')
File "/usr/lib/python3.8/importlib/metadata.py", line 530, in version
return distribution(distribution_name).version
File "/usr/lib/python3.8/importlib/metadata.py", line 503, in distribution
return Distribution.from_name(distribution_name)
File "/usr/lib/python3.8/importlib/metadata.py", line 177, in from_name
raise PackageNotFoundError(name)
importlib.metadata.PackageNotFoundError: pancaketrade

whats the problem

Error

C:\Users\utilizador\Desktop\pancaketrade> poetry install --no-dev
Installing dependencies from lock file

Package operations: 55 installs, 0 updates, 0 removals

• Installing toolz (0.11.1)

ValueError

File \C:\Users\utilizador\AppData\Local\pypoetry\Cache\artifacts\76\04\1d\f46d18706c5f71cc9eaeb2e5fc2c4e83d7b86def15ba7bdcf478790f04\toolz-0.11.1-py3-none-any.whl does not exist

at ~.poetry\lib\poetry_vendor\py3.9\poetry\core\packages\file_dependency.py:40 in init
36¦ except FileNotFoundError:
37¦ raise ValueError("Directory {} does not exist".format(self._path))
38¦
39¦ if not self._full_path.exists():
? 40¦ raise ValueError("File {} does not exist".format(self._path))
41¦
42¦ if self._full_path.is_dir():
43¦ raise ValueError("{} is a directory, expected a file".format(self._path))
44¦

any solution?

Quick way to duplicate orders

I'm manually duplicating orders using the menu and clicking through the menu can be a little tedious. Is it possible to add to the menu to quickly duplicate an order?

The reason for this is because if an order is large enough, it'll trigger the front-running bots on pancakeswap. Hence, I'm splitting order into smaller amounts.

Maybe this can also apply to the "sell all!" button so you can exit your entire position in multiple trades quickly without triggering front-running bots.

[Request] Support Fiat for base

Switchable base instead using BNB,
can be edit in telegram dialog,
BUSD, USDT, DAO etc
btw great project, thanks to make it public

Is it possible to add multiple chat admin?

Hi beep,

Thanks for the great job. Is it possible to add multiple admin chat id into the config file to manage the wallet and use the bot simultaneously?

Thanks in advance

Token price update broken

Seems with the total wallet addition in the code on submitting 3d17907 the telegram bot used to auto-refresh the prices on the status page and on merging change it won't work again and after I discard changes it works again.

help me

$ poetry run trade
2021-09-19 05:14:11 INFO |Bye!
Traceback (most recent call last):
File "", line 1, in
File "C:\Users\Administrator\Downloads\pancaketrade-master\pancaketrade-master.venv\lib\site-packages\click\core.py", line 829, in call
return self.main(*args, **kwargs)
File "C:\Users\Administrator\Downloads\pancaketrade-master\pancaketrade-master.venv\lib\site-packages\click\core.py", line 782, in main
rv = self.invoke(ctx)
File "C:\Users\Administrator\Downloads\pancaketrade-master\pancaketrade-master.venv\lib\site-packages\click\core.py", line 1066, in invoke
return ctx.invoke(self.callback, **ctx.params)
File "C:\Users\Administrator\Downloads\pancaketrade-master\pancaketrade-master.venv\lib\site-packages\click\core.py", line 610, in invoke
return callback(*args, **kwargs)
File "C:\Users\Administrator\Downloads\pancaketrade-master\pancaketrade-master\pancaketrade\trade.py", line 28, in main
config = read_config(config_file)
File "C:\Users\Administrator\Downloads\pancaketrade-master\pancaketrade-master\pancaketrade\utils\config.py", line 88, in read_config
return parse_config_file(config_file_path)
File "C:\Users\Administrator\Downloads\pancaketrade-master\pancaketrade-master\pancaketrade\utils\config.py", line 65, in parse_config_file
conf['_pk'] = questionary.password(
File "C:\Users\Administrator\Downloads\pancaketrade-master\pancaketrade-master.venv\lib\site-packages\questionary\prompts\password.py", line 59, in password
return text.text(
File "C:\Users\Administrator\Downloads\pancaketrade-master\pancaketrade-master.venv\lib\site-packages\questionary\prompts\text.py", line 90, in text
p = PromptSession(
File "C:\Users\Administrator\Downloads\pancaketrade-master\pancaketrade-master.venv\lib\site-packages\prompt_toolkit\shortcuts\prompt.py", line 468, in init
self.app = self._create_application(editing_mode, erase_when_done)
File "C:\Users\Administrator\Downloads\pancaketrade-master\pancaketrade-master.venv\lib\site-packages\prompt_toolkit\shortcuts\prompt.py", line 719, in _create_application
application: Application[_T] = Application(
File "C:\Users\Administrator\Downloads\pancaketrade-master\pancaketrade-master.venv\lib\site-packages\prompt_toolkit\application\application.py", line 277, in init
self.output = output or session.output
File "C:\Users\Administrator\Downloads\pancaketrade-master\pancaketrade-master.venv\lib\site-packages\prompt_toolkit\application\current.py", line 70, in output
self._output = create_output()
File "C:\Users\Administrator\Downloads\pancaketrade-master\pancaketrade-master.venv\lib\site-packages\prompt_toolkit\output\defaults.py", line 73, in create_output
return Win32Output(stdout, default_color_depth=color_depth_from_env)
File "C:\Users\Administrator\Downloads\pancaketrade-master\pancaketrade-master.venv\lib\site-packages\prompt_toolkit\output\win32.py", line 107, in init
info = self.get_win32_screen_buffer_info()
File "C:\Users\Administrator\Downloads\pancaketrade-master\pancaketrade-master.venv\lib\site-packages\prompt_toolkit\output\win32.py", line 211, in get_win32_screen_buffer_info
raise NoConsoleScreenBufferError
prompt_toolkit.output.win32.NoConsoleScreenBufferError: Found xterm, while expecting a Windows console. Maybe try to run this program using "winpty" or run it in cmd.exe instead. Or otherwise, in case of Cygwin, use the Python executable that is compiled for Cygwin.

i got this eror

Menu status ordering

This is a small thing, but I went in on my local source copy and switched these menus around since I felt they make more sense this way. You would want to create an order before ever deleting an order and buy or sell before selling all. Just a personal ordering thing. Thank you!

image

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.