Comments (5)
Many thanks!
from gateio-crypto-trading-bot-binance-announcements-new-coins.
Can I just implement your solution into the current bot? Bit of a python noob here
from gateio-crypto-trading-bot-binance-announcements-new-coins.
The last option I posted, to get only the first coin and ignore the rest on a multi coin announcement is safe to implement. You can just copy this code and replace the original get_last_coin() method.
The other one needs a bit of tweaking, which I am testing right now. Until we get another multi-coin announcement I will not be 100% sure it works.
from gateio-crypto-trading-bot-binance-announcements-new-coins.
This is my code from the new_listings_scraper. How would i edit it to be the equivalent of what rrm1991 mentioned above to only get the first coin of a multi-coin listing? I'm a rookie, so I couldn't interpret what rrm1991 said to do and apply it to my code. Any help would be appreciated, thanks.
def get_last_coin():
"""
Returns new Symbol when appropriate
"""
# scan Binance Announcement
latest_announcement = get_announcement()
# enable Kucoin Announcements if True in config
if config['TRADE_OPTIONS']['KUCOIN_ANNOUNCEMENTS']:
logger.info('Kucoin announcements enabled, look for new Kucoin coins...')
kucoin_announcement = get_kucoin_announcement()
kucoin_coin = re.findall('\(([^)]+)', kucoin_announcement)
found_coin = re.findall('\(([^)]+)', latest_announcement)
uppers = None
# returns nothing if it's an old coin or it's not an actual coin listing
if 'Will List' not in latest_announcement or found_coin[0] == globals.latest_listing or \
found_coin[0] in previously_found_coins:
# if the latest Binance announcement is not a new coin listing, or the listing has already been returned, check kucoin
if config['TRADE_OPTIONS']['KUCOIN_ANNOUNCEMENTS'] and 'Gets Listed' in kucoin_announcement\
and kucoin_coin[0] != globals.latest_listing and kucoin_coin[0] not in previously_found_coins:
if len(kucoin_coin) == 1:
uppers = kucoin_coin[0]
previously_found_coins.add(uppers)
logger.info('New Kucoin coin detected: ' + uppers)
if len(kucoin_coin) != 1:
uppers = None
else:
if len(found_coin) == 1:
uppers = found_coin[0]
previously_found_coins.add(uppers)
logger.info('New coin detected: ' + uppers)
if len(found_coin) != 1:
uppers = None
return uppers
from gateio-crypto-trading-bot-binance-announcements-new-coins.
I've created a new Draft PR to tackle this issue.
The first step would be to just grab the first coin similar to @rrm1991's implementation.
See here: #150
In the future we might implement a solution that would monitor and buy/sell all mentioned coins simultaneously.
But there are some problems with that as well which we do need to discuss then.
from gateio-crypto-trading-bot-binance-announcements-new-coins.
Related Issues (20)
- Consider logs more beautify & add more informative new fields
- Unable to buy API3, Empty error HOT 3
- False positive announcement alert after 2 days from kucoin HOT 1
- Bot does not buy Binance announcements
- Error In SSH Server HOT 4
- Telegram notifications don't work HOT 2
- ModuleNotFoundError when running main.py HOT 1
- Matrix discussion room
- Better logging when polling announcements
- Add more config options when using proxies
- Remove proxies when they return an invalid response
- Option to add custom proxies
- When chosen pairing doesn't exist, print error accordingly
- Messages not send to telegram HOT 1
- Get Announcement with latency HOT 4
- Looks like Binance is tweaking cache
- Error with kucoin new announcements
- Telegram notifications broken? HOT 1
- Error 400 pulling Binance announcement page HOT 2
- New Crypto
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from gateio-crypto-trading-bot-binance-announcements-new-coins.