CyberPunkMetalHead / binance-trading-bot-new-coins

This Binance trading bot detects new coins as soon as they are listed on the Binance exchange and automatically places sell and buy orders. It comes with trailing stop loss and other features. If you like this project please consider donating via Brave.
MIT License
1.46k stars 268 forks source link

calling yaml.load() without Loader=... is deprecated #70

Closed JohnKennedy2019 closed 2 years ago

JohnKennedy2019 commented 2 years ago

Hi Andrei,

Thanks a lot for your code and videos :)

when i executed the main.py i got below error. could you please help me here.

I downloaded the file from --> https://github.com/CyberPunkMetalHead/binance-trading-bot-new-coins

Hope this the latest code.

After download i only changed binance_tld: to "COM"

Error as below:

C:\Anaconda\envs\api_test\lib\site-packages\dateparser\conf.py:45: YAMLLoadWarning: calling yaml.load() without Loader=... is deprecated, as the default Loader is unsafe. Please read https://msg.pyyaml.org/load for full details. cls._yaml_data = load_yaml(data).pop('settings', {}) C:\Anaconda\envs\api_test\lib\site-packages\dateparser\languages\loader.py:38: YAMLLoadWarning: calling yaml.load() without Loader=... is deprecated, as the default Loader is unsafe. Please read https://msg.pyyaml.org/load for full details. data = load_yaml(data) Traceback (most recent call last): File "main.py", line 4, in from new_listings_scraper import File "C:\ADM\Test_binance\binance-trading-bot-new-coins-main\binance-trading-bot-new-coins-main\new_listings_scraper.py", line 10, in from send_notification import File "C:\ADM\Test_binance\binance-trading-bot-new-coins-main\binance-trading-bot-new-coins-main\send_notification.py", line 4, in config = load_config('config.yml') File "C:\ADM\Test_binance\binance-trading-bot-new-coins-main\binance-trading-bot-new-coins-main\load_config.py", line 5, in load_config return yaml.load(file, Loader=yaml.FullLoader) File "C:\Anaconda\envs\api_test\lib\site-packages\yaml__init__.py", line 114, in load return loader.get_single_data() File "C:\Anaconda\envs\api_test\lib\site-packages\yaml\constructor.py", line 49, in get_single_data node = self.get_single_node() File "C:\Anaconda\envs\api_test\lib\site-packages\yaml\composer.py", line 36, in get_single_node document = self.compose_document() File "C:\Anaconda\envs\api_test\lib\site-packages\yaml\composer.py", line 55, in compose_document node = self.compose_node(None, None) File "C:\Anaconda\envs\api_test\lib\site-packages\yaml\composer.py", line 84, in compose_node node = self.compose_mapping_node(anchor) File "C:\Anaconda\envs\api_test\lib\site-packages\yaml\composer.py", line 127, in compose_mapping_node while not self.check_event(MappingEndEvent): File "C:\Anaconda\envs\api_test\lib\site-packages\yaml\parser.py", line 98, in check_event self.current_event = self.state() File "C:\Anaconda\envs\api_test\lib\site-packages\yaml\parser.py", line 439, in parse_block_mapping_key "expected , but found %r" % token.id, token.start_mark) yaml.parser.ParserError: while parsing a block mapping in "config.yml", line 2, column 3 expected , but found '' in "config.yml", line 18, column 22

JohnKennedy2019 commented 2 years ago

This package issue was automatically fixed, once i created a new environment. Thanks !!