BitMEX / api-connectors

Libraries for connecting to the BitMEX API.
https://www.bitmex.com/app/restAPI
910 stars 795 forks source link

How to block/resolve warnings.warn(swagger_validation_warning) ? #265

Open moltenbit opened 5 years ago

moltenbit commented 5 years ago

Hello, I am quite new here so sorry if this is sth basic.

I wrote a python program using tkinter and bitmex API; it creates a simple GUI which displays the current price on livenet. (using OrderBook_getL2 method)

My problem is: the code itself runs fine, the price is displayed on the GUI. But the command prompt (which opens up same time as GUI) shows this error:

warnings.warn(swagger_validation_warning)

Because I want to create a Windows executable file from my .py file with pyinstaller this is a problem. The exe does not work because of the error in command prompt even if I create the exe with the '--noconsole' option in pyinstaller. Since I can not use an API key to authenticate I really do not know how to go on now...

I would appreciate any help either blocking the error code in pyinstaller or resolving the problem on the bitmex side of things.

legendcord commented 5 years ago

You can workaround this issue by commenting out the warning message in validator20.py