XChange icon indicating copy to clipboard operation
XChange copied to clipboard

[GateIO] Can not initialize the MarketDataService

Open lavaalone opened this issue 4 years ago • 2 comments

Receiving error message as below when initializing the MarketDataService. Caused by: si.mazi.rescu.HttpStatusIOException: Cannot construct instance of org.knowm.xchange.gateio.dto.marketdata.GateioFeeInfo (although at least one Creator exists): no String-argument constructor/factory method to deserialize from String value ('false') at [Source: (String)"{"result":"false","code":5,"message":"Error: empty key or sign"}"; line: 1, column: 11] (through reference chain: java.util.LinkedHashMap["result"]) at si.mazi.rescu.ResponseReader.read(ResponseReader.java:104) at si.mazi.rescu.RestInvocationHandler.mapInvocationResult(RestInvocationHandler.java:169) at si.mazi.rescu.RestInvocationHandler.receiveAndMap(RestInvocationHandler.java:157) at si.mazi.rescu.RestInvocationHandler.invoke(RestInvocationHandler.java:113) at com.sun.proxy.$Proxy58.getFeeList(Unknown Source) at org.knowm.xchange.gateio.service.GateioMarketDataServiceRaw.getGateioFees(GateioMarketDataServiceRaw.java:40) at org.knowm.xchange.gateio.GateioAdapters.adaptToExchangeMetaData(GateioAdapters.java:245) at org.knowm.xchange.gateio.GateioExchange.remoteInit(GateioExchange.java:43) at org.knowm.xchange.BaseExchange.applySpecification(BaseExchange.java:113)

Code is run directly from the provide sample code at GateIoExchangeDemo.java, copied below: Exchange exchange = ExchangeFactory.INSTANCE.createExchange(GateioExchange.class);

Other information:

  • Branch: master
  • Java: 11

lavaalone avatar Nov 23 '21 05:11 lavaalone

Im facing the same problem here, i think gate v2 api are deprecated, they released a new version

https://www.gate.io/docs/developers/apiv4/en/#access-url

GARCII avatar Dec 18 '21 23:12 GARCII

gateio api v4 is added. see https://github.com/knowm/XChange/pull/4766

bigscoop avatar Sep 02 '23 07:09 bigscoop