
    i!                         d dl Zd dlmZmZmZ d dlZd dlmZm	Z	m
Z
mZmZmZmZ d dlmZ d dlmZ d dlmZ d dlmZ  G d d	ej        j                  ZdS )
    N)
ArrayCacheArrayCacheBySymbolByIdArrayCacheByTimestamp)IntOrder	OrderBookStrStringsTickersTrade)Client)List)ExchangeError)NotSupportedc            
       0    e Zd Z fdZddi fdedededee         fdZddi fdee         dededee         fd	Z	d'defd
Z
defdZdefdZdedefdZdddi fdedededee         fdZdefdZdi fdededefdZdefdZdi fdee         dedefdZdi fdedefdZdededefdZi fdedee         fdZdededefdZdefdZdddi fdedededee         fdZdefdZ defdZ!defd Z"d'd!Z#d" Z$d# Z%defd$Z&defd%Z'i fd&Z( xZ)S )(geminic                     |                      t          t          |                                           ddddddddddddddddiddidd	          S )
NTF)wswatchBalancewatchTickerwatchTickerswatchBidsAskswatchTradeswatchTradesForSymbolswatchMyTradeswatchOrderswatchOrderBookwatchOrderBookForSymbols
watchOHLCVzapi.gemini.comr   zwss://api.gemini.comzwss://api.sandbox.gemini.com)apitest)hashostnameurls)deep_extendsuperr   describe)self	__class__s    U/var/www/html/crypto-bot/backend/venv/lib/python3.11/site-packages/ccxt/pro/gemini.pyr'   zgemini.describe   s    fd 3 3 < < > > %$ %!%#)-!&#"&,0"  ) 0 8	 !A
 A
   	    Nsymbolsincelimitreturnc                   K   |                                   d{V  |                     |          }d|d         z   }|d         }dd|                                gdgd}d	|d         z   }	| j        d
         d         dz   }
|                     |
|||	           d{V }| j        r|                    |d         |          }|                     |||dd          S )a)  
        watch the list of most recent trades for a particular symbol
        :see: https://docs.gemini.com/websocket-api/#market-data-version-2
        :param str symbol: unified symbol of the market to fetch trades for
        :param int [since]: timestamp in ms of the earliest trade to fetch
        :param int [limit]: the maximum amount of trades to fetch
        :param dict [params]: extra parameters specific to the exchange API endpoint
        :returns dict[]: a list of `trade structures <https://docs.ccxt.com/#/?id=public-trades>`
        Ntrades:r,   id	subscribel2namesymbolstypesubscriptionsl2:r    r   /v2/marketdata	timestampT)load_marketsmarketupperr$   watch
newUpdatesgetLimitfilter_by_since_limit)r(   r,   r-   r.   paramsr?   messageHashmarketIdrequestsubscribeHashurltradess               r*   watch_tradeszgemini.watch_trades-   s      !!!!!!!!!V$$&"22$< ! ((  

 

 x 00it$'77zz#{G]KKKKKKKK? 	=OOF8$4e<<E))&%TRRRr+   r7   c                   K   |                      d||           d{V }| j        rB|                     |d          }|                     |d          }|                    ||          }|                     |||dd          S )a$  
        :see: https://docs.gemini.com/websocket-api/#multi-market-data
        get the list of most recent trades for a list of symbols
        :param str[] symbols: unified symbol of the market to fetch trades for
        :param int [since]: timestamp in ms of the earliest trade to fetch
        :param int [limit]: the maximum amount of trades to fetch
        :param dict [params]: extra parameters specific to the exchange API endpoint
        :returns dict[]: a list of `trade structures <https://docs.ccxt.com/#/?id=public-trades>`
        rK   Nr   r,   r=   T)#helper_for_watch_multiple_constructrB   	safe_listsafe_stringrC   rD   )r(   r7   r-   r.   rE   rK   firsttradeSymbols           r*   watch_trades_for_symbolszgemini.watch_trades_for_symbolsM   s       ??'SYZZZZZZZZ? 	8NN61--E**5(;;KOOK77E))&%TRRRr+   c                    |                      |d          }|                     |dd          }|                     |d          }|                     |dd          }|                     |d          }|'|                     |d          }|d	k    rd
}n|dk    rd}|                     |d          }	|                     |	|          }
|                     |d |||                     |          |
d |d |d |d d|          S )Nr=   event_idtidpricequantityamountside	makerSidebidsellaskbuyr,   )r2   orderinfor=   datetimer,   r9   rZ   takerOrMakerrW   costrY   fee)safe_integersafe_string_2rP   safe_string_lowersafe_symbol
safe_tradeiso8601)r(   trader?   r=   r2   priceStringamountStringrZ   
marketSiderG   r,   s              r*   parse_ws_tradezgemini.parse_ws_trade^   s/   2 %%e[99	z599&&ug66))%XFF%%eV44<//{CCJU""u$$))%::!!(F33"Y//  " 
  
   	r+   clientc                 D   |                      |          }|d         }|                     | j        dd          }|                     | j        |          }|t          |          }|| j        |<   |                    |           d|z   }|                    ||           d S )Nr,   tradesLimit  r1   )rp   rf   options
safe_valuerK   r   appendresolve)r(   rq   messagerl   r,   rs   storedrF   s           r*   handle_tradezgemini.handle_trade   s     ##G,,x''mTJJf55>,,F"(DKe&(v{+++++r+   c                    |                      |d          }|                     |          }|                     |d          }||d         }|                     | j        dd          }|                     | j        |          }|t          |          }|| j        |<   t          dt          |                    D ]3}	| 	                    ||	         |          }
|
                    |
           4d|z   }|                    ||           d S d S )Nr,   rK   rs   rt   r   r1   )rh   safe_marketrv   rf   ru   rK   r   rangelenrp   rw   rx   )r(   rq   ry   rG   r?   rK   r,   rs   rz   irl   rF   s               r*   handle_tradeszgemini.handle_trades   s   L ))'8<<!!(++(33H%F++DL-NNK__T[&99F~#K00&,F#1c&kk** % %++F1Iv>>e$$$$#f,KNN6;///// r+   r=   c                    |p|                      | j        dd          }i }t          dt          |                    D ]}||         d         }|                     |                                          }|d         }	|                     ||         |          }
||
d<   |                     |          |
d<   |                     | j	        |	          }|t          |          }|| j	        |	<   |                    |
           |||	<   t          |                                          }t          dt          |                    D ]/}||         }	||	         }d|	z   }|                    ||           .d S d S )Nrs   rt   r   r,   r=   rb   r1   )rf   ru   r~   r   r}   lowerrp   rk   rv   rK   r   rw   listkeysrx   )r(   rq   rK   r=   rs   storesForSymbolsr   rG   r?   r,   rl   rz   r7   rF   s                 r*   handle_trades_for_multidataz"gemini.handle_trades_for_multidata   s   ++DL-NNK!1c&kk** 2 2!!9X.))(..*:*:;;)++F1Iv>>%.k"$(LL$;$;j!f==>'44F*0DK'e$$$+1 ((+002233G1c'll++ 4 4 )&1'&0v{3333+ "4 4r+   1mc                   K   |                                   d{V  |                     |          }|                     | j        ||          }dd|z   |d                                         gdgd}d|d         z   d	z   |z   }	| j        d
         d         dz   }
|                     |
|	||	           d{V }| j        r|                    ||          }| 	                    |||dd          S )a  
        watches historical candlestick data containing the open, high, low, and close price, and the volume of a market
        :see: https://docs.gemini.com/websocket-api/#candles-data-feed
        :param str symbol: unified symbol of the market to fetch OHLCV data for
        :param str timeframe: the length of time each candle represents
        :param int [since]: timestamp in ms of the earliest candle to fetch
        :param int [limit]: the maximum amount of candles to fetch
        :param dict [params]: extra parameters specific to the exchange API endpoint
        :returns int[][]: A list of candles ordered, open, high, low, close, volume
        Nr3   candles_r2   r5   r8   ohlcv:r,   :r    r   r<   r   T)
r>   r?   rP   
timeframesr@   r$   rA   rB   rC   rD   )r(   r,   	timeframer-   r.   rE   r?   timeframeIdrH   rF   rJ   ohlcvs               r*   watch_ohlcvzgemini.watch_ohlcv   s*      !!!!!!!!!V$$&&t	9MM '4t**,,  

 

 !11C7+Eit$'77jjk7KHHHHHHHH? 	2NN6511E))%q$GGGr+   c                    |                      |dd          }|dd          }|                    d          }|d|         }|                      |dd                                          }|                     |          }|                     ||          }|                     |dg           }	|                     |          }
|                     | j        |          }|
i | j        |<   |                     | j        |         |
          }|;|                     | j	        dd	          }t          |          }|| j        |         |
<   t          |	          }t          d|          D ];}||z
  d
z
  }|                     |	|         |          }|                    |           <d|z   dz   |z   }|                    ||           |S )Nr9       _r   r,   changes
OHLCVLimitrt      r   r   )rP   findr   r}   ri   rv   find_timeframeohlcvsrf   ru   r   r   r~   parse_ohlcvrw   rx   )r(   rq   ry   r9   r   timeframeEndIndexrG   r?   r,   r   r   ohlcvsBySymbolrz   r.   changesLengthr   indexparsedrF   s                      r*   handle_ohlcvzgemini.handle_ohlcv  s   4 44122h',,S11!!$5"56##GXr::@@BB!!(++!!(F33//'9b99''44	f==!"$DKV!4i@@>%%dlL$GGE*511F-3DK	*Gq-(( 	" 	"A!A%)E%%genf==FMM&!!!!'#-;v{+++r+   c                 h  K   |                                   d{V  |                     |          }d|d         z   }|d         }dd|                                gdgd}d	|d         z   }| j        d
         d         dz   }	|                     |	|||           d{V }
|
                                S )a>  
        watches information on open orders with bid(buy) and ask(sell) prices, volumes and other data
        :see: https://docs.gemini.com/websocket-api/#market-data-version-2
        :param str symbol: unified symbol of the market to fetch the order book for
        :param int [limit]: the maximum amount of order book entries to return
        :param dict [params]: extra parameters specific to the exchange API endpoint
        :returns dict: A dictionary of `order book structures <https://docs.ccxt.com/#/?id=order-book-structure>` indexed by market symbols
        N
orderbook:r,   r2   r3   r4   r5   r8   r;   r    r   r<   )r>   r?   r@   r$   rA   r.   )r(   r,   r.   rE   r?   rF   rG   rH   rI   rJ   	orderbooks              r*   watch_order_bookzgemini.watch_order_bookN  s       !!!!!!!!!V$$"VH%55$< ! ((  

 

 x 00it$'77**S+wNNNNNNNN	   r+   c                 ^   |                      |dg           }|                     |d          }|                     |          }|d         }d|z   }|                      | j        |          }||                                 }t          dt          |                    D ]i}	||	         }
|                     |
d          }|                     |
d          }|
d         dk    rdnd	}||         }|                    ||           |||<   j||d<   || j        |<   |	                    ||           d S )
Nr   r,   r   r   r      r_   bidsasks)
rv   rh   r}   
orderbooks
order_bookr~   r   safe_numberstorerx   )r(   rq   ry   r   rG   r?   r,   rF   r   r   deltarW   sizerZ   booksides                  r*   handle_order_bookzgemini.handle_order_bookk  s>   //'9b99))'8<<!!(++!"V+OODOV<<	))Iq#g,,'' 	' 	'AAJE$$UA..E##E1--D#Ah%//66fD HNN5$'''&IdOO$	("+y+.....r+   c                 h   K   |                      d||           d{V }|                                S )a  
        watches information on open orders with bid(buy) and ask(sell) prices, volumes and other data
        :see: https://docs.gemini.com/websocket-api/#multi-market-data
        :param str[] symbols: unified array of symbols
        :param int [limit]: the maximum amount of order book entries to return
        :param dict [params]: extra parameters specific to the exchange API endpoint
        :returns dict: A dictionary of `order book structures <https://docs.ccxt.com/#/?id=order-book-structure>` indexed by market symbols
        r   N)rN   r.   )r(   r7   r.   rE   r   s        r*   watch_order_book_for_symbolsz#gemini.watch_order_book_for_symbols  sC       BB;PWY_````````	   r+   c                 @   K   |                      d||           d{V S )a~  
        watches best bid & ask for symbols
        :see: https://docs.gemini.com/websocket-api/#multi-market-data
        :param str[] symbols: unified symbol of the market to fetch the ticker for
        :param dict [params]: extra parameters specific to the exchange API endpoint
        :returns dict: a `ticker structure <https://docs.ccxt.com/#/?id=ticker-structure>`
        bidsasksN)rN   )r(   r7   rE   s      r*   watch_bids_askszgemini.watch_bids_asks  s3       ==j'SYZZZZZZZZZr+   noncec                    |d         d         }|                      |                                          }|d         }|| j        vr-|                     i           | j        |<   || j        |         d<   | j        |         }d|z   }	t	          dt          |                    D ]n}
||
         }|                     |d          }|                     |d          }|                     |d          }|dk    rS|dk    r||d<   ||d<   d||d	<   ||d
<   o||d<   |                     |          |d<   ||d<   || j        |<   |	                    ||	           d S )Nr   r,   z	bidsasks:rZ   rW   	remainingr\   	bidVolumer^   	askVolumer=   rb   ra   )
r}   r   r   parse_tickerr~   r   rP   r   rk   rx   )r(   rq   rawBidAskChangesr=   r   rG   r?   r,   currentBidAskrF   r   entryrawSiderW   r   s                  r*   handle_bids_asks_for_multidataz%gemini.handle_bids_asks_for_multidata  s   8 $A&x0!!(.."2"233!$-''$($5$5b$9$9DM&!.4DM&!(+f-!F*q#.//00 	2 	2A$Q'E&&uf55G$$UG44E##E;77Dqyy%',e$-1k**',e$-1k**%.k"$(LL$;$;j! 0f -f}k22222r+   itemHashNamec                   K   |                                   d {V  |                     |d ddd          }|                     |d                   }|d         s|d         st          | j        dz             g }g }t          dt          |                    D ]W}||         }|dz   |z   }	|                    |	           |                     |          }
|                    |
d                    Xd	                    |          }| j	        d
         d         dz   |z   dz   }|dk    r|dz  }n|dk    r|dz  }n|dk    r|dz  }| 
                    ||d            d {V S )NFTr   spotlinearz8 watchMultiple supports only spot or linear-swap symbolsr   r2   ,r    r   z/v1/multimarketdata?symbols=z&heartbeat=true&r   z"trades=false&bids=true&offers=truer   z3trades=false&bids=true&offers=true&top_of_book=truerK   z#trades=true&bids=false&offers=false)r>   market_symbolsr?   r   r2   r~   r   rw   joinr$   watch_multiple)r(   r   r7   rE   firstMarketmessageHashes	marketIdsr   r,   rF   r?   queryStrrJ   s                r*   rN   z*gemini.helper_for_watch_multiple_construct  s     !!!!!!!!!%%gtUD$GGkk'!*--6" 	e;x+@ 	etw)ccddd	q#g,,'' 	+ 	+AQZF&,v5K  ---[[((FVD\****88I&&it$'EEPSee;&&77CCZ''HHCCX%%88C((mTBBBBBBBBBr+   c                    |d         d         }|                      |                                          }|d         }d|z   }|| j        vr|                                 }	|	| j        |<   | j        |         }
|
d         }|
d         }t	          dt          |                    D ]}||         }|                     |d          }|                     |d          }|                     |d          }|d	k    r|                    ||           i|                    ||           ||
d<   ||
d<   ||
d<   ||
d
<   ||
d<   | 	                    |          |
d<   |
| j        |<   |
                    |
|           d S )Nr   r,   r   r   r   rW   r   rZ   r\   r   r=   rb   )r}   r   r   r   r~   r   r   rP   r   rk   rx   )r(   rq   rawOrderBookChangesr=   r   rG   r?   r,   rF   obr   r   r   r   r   rW   r   r   s                     r*   handle_order_book_for_multidataz&gemini.handle_order_book_for_multidata  s     'q)(3!!(.."2"233!"V+$/))""B&(DOF#OF+	  q#12233 	( 	(A'*E$$UG44E##E;77D&&uf55G%

5$''''

5$'''' 	& 	&$	("	'!*	+ $Y 7 7	*"+y+.....r+   c                 ^    |                      ||           |                     ||           d S N)r   r   r(   rq   ry   s      r*   handle_l2_updateszgemini.handle_l2_updates  s7    L 	vw///67+++++r+   c                   K   | j         d         d         dz   }|                                  d{V  d|i}|                     |           d{V  ||                     |          }|d         }d}|                     ||d|           d{V }	| j        r|	                    ||          }|                     |	|||d          S )	a.  
        watches information on multiple orders made by the user
        :see: https://docs.gemini.com/websocket-api/#order-events
        :param str symbol: unified market symbol of the market orders were made in
        :param int [since]: the earliest time in ms to fetch orders for
        :param int [limit]: the maximum number of order structures to retrieve
        :param dict [params]: extra parameters specific to the exchange API endpoint
        :returns dict[]: a list of `order structures <https://docs.ccxt.com/#/?id=order-structure>`
        r    r   z/v1/order/events?eventTypeFilter=initial&eventTypeFilter=accepted&eventTypeFilter=rejected&eventTypeFilter=fill&eventTypeFilter=cancelled&eventTypeFilter=bookedNrJ   r,   ordersT)r$   r>   authenticater?   rA   rB   rC   filter_by_symbol_since_limit)
r(   r,   r-   r.   rE   rJ   
authParamsr?   rF   r   s
             r*   watch_orderszgemini.watch_orders;  s      it$  (J  J!!!!!!!!!3

 
+++++++++[[((FH%Fzz#{D+FFFFFFFF? 	3OOFE22E00tTTTr+   c                 8    |                                  |_        |S r   )millisecondslastPongr   s      r*   handle_heartbeatzgemini.handle_heartbeatT  s     ++--r+   c                     |S r    r   s      r*   handle_subscriptionzgemini.handle_subscriptiona  s	     r+   c                 \   d}| j         0|                     | j        dd          }t          |          | _         | j         }t	          dt          |                    D ]2}|                     ||                   }|                    |           3|                    | j         |           d S )Nr   ordersLimitrt   r   )	r   rf   ru   r   r~   r   parse_ws_orderrw   rx   )r(   rq   ry   rF   r.   r   r   r`   s           r*   handle_orderzgemini.handle_ordern  s    0 ;%%dlM4HHE077DKq#g,,'' 	! 	!A''
33EMM%    t{K00000r+   c                    |                      |d          }|                     |d          }|                     |d          }|                     |d          }|                     |d          }d}d}	|dk    rd	}n|d
k    rd}n
|dk    rd}d}	|                     i d|                     |d          d|                     |d          d|d|d|                     |          dd d|                     |          d|                     ||          d|                     |          d|d|	d|                     |d          d|                     |d          dd d|                     |d          dd d |                     |d!          |                     |d"          |                     |d#          d d d$|          S )%Ntimestampmsr9   r,   
order_typebehaviorGTCFzimmediate-or-cancelIOCzfill-or-killFOKzmaker-or-cancelPOTr2   order_idclientOrderIdclient_order_idra   r=   rb   lastTradeTimestampstatustimeInForcepostOnlyrZ   rW   	stopPriceaverageavg_execution_pricerd   rY   original_amountexecuted_amountremaining_amount)filledr   re   rK   )rf   rP   
safe_orderrk   parse_ws_order_statusri   parse_ws_order_typer   )
r(   r`   r?   r=   r   rG   typeIdr   r   r   s
             r*   r   zgemini.parse_ws_order  st   , %%e];;	!!%00##E844!!%66##E:66,,,KK''KK***KH  
$""5*55 
T--e5FGG 
 E 
 	 

 Y// 
 !$ 
 d0088 
 d&&x88 
 D,,V44 
 ; 
  
 D$$UF33 
 T%%eW55 
  
 t''/DEE 
  D! 
" d&&u.?@@# 
$ &&u.?@@))%1CDD+ 
  
  
, -  	r+   c                 B    ddddddd}|                      |||          S )Nopenclosedcanceledrejected)acceptedbookedfill	cancelledcancel_rejectedr  rP   )r(   r   statusess      r*   r   zgemini.parse_ws_order_status  s:    #)"
 
 &&999r+   c                 <    dddd}|                      |||          S )Nr.   r?   )zexchange limitz
market buyzmarket sellr  )r(   r9   typess      r*   r   zgemini.parse_ws_order_type  s1    %"#
 

 tT222r+   c                 F    t          |                     |                    r   )r   jsonr   s      r*   handle_errorzgemini.handle_error  s     DIIg..///r+   c                    t          |t                    }|r|                     ||           d S |                     |d          }|dk    r|                     ||           | j        | j        | j        | j        d}|                     |dd          }|	                    d          dk    r| 
                    ||           d S |                     ||          }| |||           |dk    r|                     |d	|                                           }|                     |d
          }	|                     |d          }
g }g }g }t          |
          }t!          dt          |
                    D ]}|
|         }|                     |d          }|dk    o!d|v o|                     |d         ddg          }|                     |d          }|dk    p|o|dk    o|dk    }|r|                    |           |r|                    |           |dk    r|                    |
|                    t          |          }|dk    r|                     ||||	           t          |          }|dk    r|                     ||||	           t          |          }|dk    r|                     |||           d S d S d S )Nreasonerror)
l2_updatesrl   subscription_ack	heartbeatr9   r   candlesr   updater   eventIdeventschangerZ   r^   r\   ztop-of-bookinitialr   rl   )
isinstancer   r   rP   r  r   r{   r   r   r   r   rv   rf   r   rO   r   r~   in_arrayrw   r   r   r   )r(   rq   ry   isArrayr  methodsr9   methodtsr  r  orderBookItemsbidaskItemscollectedEventsOfTradeseventsLengthr   event	eventTypeisOrderBookeventReasonisBidAsklengthBalengthOblengthTradess                           r*   handle_messagezgemini.handle_message  s3   H Wd++ 	fg...F!!'844Wfg...0& $ 8.	
 
 4499Y1$$fg...F$//F67###8""7M4;L;L;N;NOOB'';;G^^GX66FNK&(#v;;L1c&kk** > >q	 ,,UF;;	(H4|6U?|PTP]P]^cdj^knsuzm{P|P|"..uh??'=8k>~{^gOg>~my}~m~ >&&u----  >"))%0000'))+226!9===;''H!||33FKWUUU>**H!||44V^RQXYYY677La009PRTUUUUU9 6  r+   c                 N  K   |                      |d          }| j        || j        v rd S |                                  t          | j        d         d                   }|                    d          }t          |          }|dk    r|n|}|||         }||                                 d}|                     |                     |                    }	| 	                    | 
                    |	          | 
                    | j                  t          j        d          }
ddd	i iii}|                     |           | j        d         d         d	         }| j        |	|
d
}|| j        d         d         d	<   |                     |           || j        d         d         d	<   d S )NrJ   r    r   ?r   )rH   r   hexru   headers)zX-GEMINI-APIKEYzX-GEMINI-PAYLOADzX-GEMINI-SIGNATURE)rP   clientscheck_required_credentialsr   r$   r   r   string_to_base64r  hmacencodesecrethashlibsha384extend_exchange_optionsru   apiKeyrq   )r(   rE   rJ   
startIndexurlParamsIndex	urlLengthendIndexrH   payloadb64	signaturedefaultOptionsoriginalHeadersr5  s                 r*   r   zgemini.authenticate?  s     vu--L$3$,+>+>F'')))5)$/00
#HH	&4&9&9>>	j)*ZZ\\
 
 ##DIIg$6$677IIdkk#..DK0H0H'.Z_``	r
 	$$^444,t,Y7	B#{ #"+
 

 4;T9%i0C3BT9%i000r+   r   )*__name__
__module____qualname__r'   strr   r   r   rL   rS   rp   r   r{   r   r   r   r   r   r   r   r   r   r
   r   r   r   rN   r   r   r	   r   r   r   r   r   r   r   r   r  r1  r   __classcell__)r)   s   @r*   r   r      s|           6 <@d[] S S SS S Sbfglbm S S S S@ OSaenp S Sd3i S S[^ Suyz  vA S S S S"4 4E 4 4 4 4l,6 , , , ,.40F 40 40 40 40l4& 4S 4 4 4 40 8<$]ajl H H HC HWZ Hquvzq{ H H H H@36 3 3 3 3j @DB ! !S ! !S\ ! ! ! !:/ / / / /* SW_a 
! 
!$s) 
!C 
!fo 
! 
! 
! 
! 8<B [ [W [7 [ [ [ [63V 63Z] 63fi 63 63 63 63p gi C Cc CTXY\T] C C C C0*/f */^a */jm */ */ */ */X', ', ', ', ',R 04$UYbd U U UC Us Uimnsit U U U U2v    &     16  1  1  1  1D: : : :x	: 	: 	:3 3 306 0 0 0 0UVV UV UV UV UVn )+ !C !C !C !C !C !C !C !Cr+   r   )ccxt.async_supportccxt ccxt.async_support.base.ws.cacher   r   r   r<  ccxt.base.typesr   r   r   r	   r
   r   r   !ccxt.async_support.base.ws.clientr   typingr   ccxt.base.errorsr   r   async_supportr   r   r+   r*   <module>rV     s       f f f f f f f f f f  O O O O O O O O O O O O O O O O O O 4 4 4 4 4 4       * * * * * * ) ) ) ) ) )PC PC PC PC PCT& PC PC PC PC PCr+   