Skip to content
This repository was archived by the owner on Oct 30, 2023. It is now read-only.

Conversation

@mcourteaux
Copy link

@mcourteaux mcourteaux commented Jun 24, 2021

This fixes: #355, and probably #309.

This will cause people using this non-existent thing to cause compilation problems, which in my opinion is exactly what you want: the compiler telling you that your trading logic is using some non-existent thing in the API. Backwards compatibility is really not what you want here IMO. Updating this repository should indeed force you to look into your bug.

@joaopsilva joaopsilva merged commit 6403409 into binance-exchange:master Jun 24, 2021
@joaopsilva
Copy link
Member

Thanks.

@brintal
Copy link

brintal commented Jun 24, 2021

But UserDataUpdateEventType.ACCOUNT_UPDATE is still used in the example included in the project. Hence the maven build is breaking now?!

@mcourteaux
Copy link
Author

But UserDataUpdateEventType.ACCOUNT_UPDATE is still used in the example included in the project. Hence the maven build is breaking now?!

I updated the tests, and the Maven build is working for me. I looked through the code, and it seems here indeed:
https://github.com/binance-exchange/binance-java-api/blob/master/src/test/java/com/binance/api/examples/UserDataStreamExample.java#L30
it is still used. This is not reported when I did mvn install. How do you trigger the error?

@brintal
Copy link

brintal commented Jun 25, 2021

@mcourteaux
Could you try executing mvn clean install. It seems like you still have the old classes in your classpath hence no error for you. clean should take care of that.
I just cloned the repo on a new machine and did mvn clean install. Result:

[ERROR] COMPILATION ERROR : 
[INFO] -------------------------------------------------------------
[ERROR] /home/michael/Dev/IdeaProjects/binance-java-api/src/test/java/com/binance/api/examples/AccountBalanceCacheExample.java:[12,1] cannot find symbol
  symbol:   static ACCOUNT_UPDATE
  location: class
[ERROR] /home/michael/Dev/IdeaProjects/binance-java-api/src/test/java/com/binance/api/examples/UserDataStreamExample.java:[30,61] cannot find symbol
  symbol:   variable ACCOUNT_UPDATE
  location: class com.binance.api.client.domain.event.UserDataUpdateEvent.UserDataUpdateEventType
[ERROR] /home/michael/Dev/IdeaProjects/binance-java-api/src/test/java/com/binance/api/examples/MarginUserDataStreamExample.java:[31,61] cannot find symbol
  symbol:   variable ACCOUNT_UPDATE
  location: class com.binance.api.client.domain.event.UserDataUpdateEvent.UserDataUpdateEventType
[ERROR] /home/michael/Dev/IdeaProjects/binance-java-api/src/test/java/com/binance/api/examples/AccountBalanceCacheExample.java:[61,38] cannot find symbol
  symbol:   variable ACCOUNT_UPDATE
  location: class com.binance.api.examples.AccountBalanceCacheExample

@mcourteaux
Copy link
Author

@brintal I made followup PR to fix examples: #388

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

UserDataUpdateEvent: ACCOUNT_UPDATE is wrong

3 participants