Python

martin-binance

Latest version: v1.2.10.post5

PyUp actively tracks 471,271 Python packages for vulnerabilities to keep your Python environments secure.

Scan your dependencies

1.2.918

Fixed
* 36
* 37

1.2.914

Fixed
* After restart from saved state incorrect value for first_run may cause incorrect data to be saved
for the start deposit. Because of this, the control of initial balances may not work correctly.
* Calculate parameters for grid. Adding price limitation based on [PERCENT_PRICE](https://github.com/binance/binance-spot-api-docs/blob/master/filters.md#percent_price)
filter. Without such limit, the task of finding grid parameters for a given volume has several solutions, including in
the area of negative price values. This is an unlikely event that could have been within the Reverse buy cycle and
high volatility

Update
* Changed logic for place order error handling. Before - save to hold uncompleted order and wait event from exchange.
Now - resend order after timeout.
* Refactoring place_grid() and calc_grid()

Added for new features
* Before start of cycle and in periodically report are showed free assets' data, what volume of coins does
not participate in the turnover

> 19/10 22:26:23 Start
>
>Start process for .db save
>
>Start process for Telegram
>
>Number of unreachable objects collected by GC: 16
>
>19/10 22:26:23 Initial first: 1.009025, second: 9829.04880062
>
>**19/10 22:26:23 Free: First: 1.009025, second: 9629.04880062**
>
>19/10 22:26:24 Start Buy cycle with 200.0 USDT depo

* 7 Allow to withdraw and deposit on active strategy with autocorrection initial balance and depo. See
[manual](https://github.com/DogsTailFarmer/martin-binance#deposit-and-withdraw-assets-on-active-strategy) for detail

1.2.105

Update
* OKX: adding delay in place_limit_order() for avoid exceeding the rate limit (60 orders / 2s)
* Some minor improvements
* up requirements for exchanges-wrapper to 1.2.7-5

1.2.104

Update
* up requirements for exchanges-wrapper to 1.2.7-4

1.2.103

Fixed
* saving the state for partially executed orders as float() instead of Decimal() causes an error when restarting
from the saved state if the last snapshot contains partial execution data.

1.2.102

Fixed
* save/restore internal order_id

1.2.101

Update
* up requirements for exchanges-wrapper to 1.2.7-3

1.2.91

Update
* Refusal to use PROFIT_REVERSE parameter.
Valid for Reverse cycle. For a small deposit, the cycle income can be equal to the minimum order size step.
If you divide it into parts to increase the deposit and make a profit, as a result of rounding the deposit amount does
not increase, which negatively affects the ability of the strategy to complete the reverse cycle.
Instead, all cycle profits are allocated either to increase the deposit (for an odd cycle number)
or to accumulate profits (for an even cycle number)

1.2.82

Fixed
* For analytic export replace Bitfinex mapping from "IOTA to MIOTA" to "IOT to MIOTA"
* Migration transition solution cleared for saved_state from 1.2.6 - > 1.2.7
* lgtm [py/unused-import]

Update
* get_min_buy_amount()

1.2.81

Fixed
* For analytic export replace IOTA to MIOTA for Bitfinex

Update
* dependency exchanges-wrapper up to 1.2.5-3

1.2.71

Fixed
* 26 29 - add preliminary calculation of grid parameters
console
25/09 16:33:07 set_trade_conditions: buy_side: False, depo: 0.050000, base_price: 18950.35, reverse_target_amount: 0, amount_min: 0.000528, step_size: 0.000001, delta_min: 0.01
25/09 16:33:07 set_trade_conditions: depo: 0.050000, order_q: 48, amount_first_grid: 0.000528, amount_2: 0.0005808, q_max: 24, coarse overprice: 1.210355
25/09 16:33:07 For Sell cycle will be set 24 orders for 1.2104% over price

Before start, you can correct value depo and other trade parameters

* 30 Incorrect conversion to comparable currency at initial check of deposit volume
* For analytic export replace IOT to IOTA for Bitfinex

1.2.67

Fixed
* Incorrect settings for max grid orders count at grid update (Filter failure: MIN_NOTIONAL)

Update
* requirements.txt exchanges-wrapper>=1.2.4-5

1.2.10

Update
* internal numbering for orders
* Processing of partial order execution events is linked to a specific order number.
Previously, events were processed sequentially, which led to an error when the order of receiving events was violated.

1.2.9

Added for new features
* Huobi exchange implemented

Update
* Dependency exchanges-wrapper==1.2.6

1.2.8

Added for new features
* Powered by [Docker](https://www.docker.com/) deploy

1.2.7

Fixed
* If it is not possible to calculate the price overlap for the cycle reverse, its value set to coarse estimate * 2
instead of the OVER_PRICE
* In saved state added StrategyBase.trades. This is for correct restore if order was filled partially

Update
README.md - renewed installation chapter

Added for new features
* Disconnecting the gRPC server is now safe, auto reconnect with full recovery of the current session

v1.2.6-8-hotfix 2022-09-03
Fixed
* [File exist error on Windows 11](https://github.com/DogsTailFarmer/martin-binance/issues/19#issue-1360296628)

1.2.6

Fixed
* [Incomplete account setup](https://github.com/DogsTailFarmer/martin-binance/issues/17#issue-1347470971)

Update
* up to Python 3.10.6
* 1.2.5-3 update on_place_order_error_string() to avoid the cyclical sending of an order rejected by the exchange
* [Update readme - limit for several pair with intersecting coin](https://github.com/DogsTailFarmer/martin-binance/issues/18#issue-1347575119)

1.2.5

Fixed
* if not FEE_IN_PAIR and Reverse: underreporting of income as a result of excess fee accrual

Update
* calculate round quote pattern
* optimize place grid method

Added for new features
* implemented first grid order volume calculating for effective FTX trading

1.2.4

Fixed
* Incorrect calculation TP parameters for TP sell, price < 1, (fee + profit) amount < step_size

1.2.3

Fixed
* [No status reply](https://github.com/DogsTailFarmer/martin-binance/issues/11#issue-1328210503)
* [Stopped command in last state when low RAM](https://github.com/DogsTailFarmer/martin-binance/issues/14#issue-1333292978)

Added for new features
* Protect against OS failures when saving a state file
* [No help it Telegram bot](https://github.com/DogsTailFarmer/martin-binance/issues/8#issue-1315732905)
For Telegram bot set up command menu and online help

Update
* Dependencies
* Refactoring calculate TP
* Refactoring calculate over price

1.2.2

Update
* Add \n on each input request
* Handling HTTP 429 error for coinmarketcap

1.2.1

Fixed
* Restore strategy from saved state after restart - get and handling missed event before the state was loaded
* Max retries exceeded with url: * for Telegram requests.post()

Update
* After restart save previous last state file into .bak

1.2.0

Added for new features
* Bitfinex exchange for STANDALONE mode added
* Control for first and last grid orders volume added
* For `ex.STATUS_DELAY = 5 Minute between sending Tlg message about current status, 0 - disable` parameter add
ability to turn off

Fixed
* Correct rounding for base and quote assets on different exchanges

Update
* Refactoring method for calculate over price in Reverse cycle
* Up https://pro.coinmarketcap.com API call to v2

If you update from lower versions please change reference in
`martin_binance/ms_cfg.toml` on next:

` CoinMarketCap`

`url = "https://pro-api.coinmarketcap.com/v2/tools/price-conversion"`

* ATTENTION: in the required package `exchanges-wrapper` was changed format config file
`exchanges_wrapper/exch_srv_cfg.toml` from 1.2.0 version. Before update, save old file and transfer configuration
data into new.
* Finished implemented Decimal calculation for orders processing
* Change data type for `REVERSE_TARGET_AMOUNT` parameter in `cli_XX_AAABBB.py`, update it before restart
* Renewed Grafana template

1.1.0

Added for new features
* FTX exchange for STANDALONE mode added
* updating grid if market conditions change

Update
* Grafana template
* code refactoring

1.0rc7

Added for new features
* control and structure update for funds_rate.db for future updates
* alerting for mismatch of number of orders to strategy status

Fixed
* updated balance value for direct cycle for analytics

Update
* refined calculation of order parameters for grid, taking into account rounding of price and volume value and
correction of parameters of the last order
* Binance API for /api/v3/exchangeInfo

v1.0rc6.1 - 2022-01-19
Update
* refactoring funds_rate_exporter.py
* readme.md, add 'For developer' chapter

1.0rc6

Fixed
* handler for cancel order - part filled - correct cancel non-filled part
* release hold grid after check, not place grid
* remove extra messages about receiving the command through the Telegram
* incorrect balance in USD for assets in trading pair (for analytics)

Update
* set min profit for TP also when calculate it before reverse
* Grafana dashboard template, some improvement

Added for new features
* some cycle parameters for export into analytic
* STANDALONE mode (Binance) get asset balances from Funding wallet for analytics

1.0rc5

Fixed
* Set min profit for TP when executing only the penultimate order of the grid

Added for new features
* Modified and tested for macOS

1.0rc4

Update
* Readme.md

Added for new features
* Cycle end alert and manual action waiting
* Set min profit for TP when executing the penultimate order of the grid

Fixed
* TypeError: unsupported operand type(s) for -: 'float' and 'NoneType' At: /executor.py(615):

1.0rc2

Fixed
* margin Windows full functional
* refactoring service process threading

1.0rc0

* Added direct access to Binance SPOT API
* Migrate to Decimal() calculation for necessary precision
* Added stop-loss checkpoint for possible bug
* Split logic and initial trading setup
* Added buy/sell asset with grid options

Fixed
* Full code refactoring

Update
* Readme.md

0.8rc

Added for new features.
* Auto calculate round float multiplier
* Added fee processing for second currency only, like as KRAKEN
* For analytic subsystem added consolidated asset valuation
* Additional check for Error when place and cancel order
* Recovery state logic implemented
* For ADAPTIVE_TRADE_CONDITION adaptive calculate grid orders quantity

Fixed
* Message 'Waiting ending cycle for manual action' instead of 'Stop...'

Changed for existing functionality.
* Code refactoring
* Place grid orders by part block for first ORDER_Q count and one by one for next

Update
* Readme.md

0.7rc

Added for new features.
* Send Telegram messages periodically that bot still alive
* Added adaptive profit calculate based on Bollinger band
* Added config for [prometheus_client](https://github.com/prometheus/client_python)
* Added 'no loss' over price calculate for Reverse cycle grid
* Added Average Directional Index analysis to optimize Reverse solution

Fixed
* Difference k for top and bottom BB line

Update
* Readme.md

0.7a

Added for new features.
* External control from Telegram bot

0.6a

Added for new features
Changed for changes in existing functionality
Deprecated for soon-to-be removed features
Removed for now removed features
Fixed for any bug fixes
Security

0.5b

Added for new features
* Calculate price of grid orders by logarithmic scale
* Added cycle result data for save into t_funds

Update
* Readme.md

Fixed
* Refactoring and optimise calculate and place take profit order
* Optimise saving funds and cycle data to .db

0.4b

Added for new features.
* Check if the take profit order execute by market and process it
* Optimize send Telegram message and save to .db function

0.3b

Added for new features.
* Create public edition

0.2b

Fixed
* Fix funds call error

Added for new features.
* Commented service functions
* Added setup info into docstring