Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

** Uncaught Exception! ** #421

Open
Haringat opened this issue Aug 14, 2018 · 6 comments
Open

** Uncaught Exception! ** #421

Haringat opened this issue Aug 14, 2018 · 6 comments

Comments

@Haringat
Copy link
Contributor

Version: 0.16.1
Build date: 2018-08-08 00:33
OS: Linux (amd64)
JRE: 1.8.0_181
OpenGL version: 4.6.0 NVIDIA 396.45 (NVIDIA Corporation)
Error: ** Uncaught Exception! **
Stack trace:

java.lang.NoSuchMethodError: java.nio.FloatBuffer.flip()Ljava/nio/FloatBuffer;
	at org.newdawn.slick.openal.SoundStore.init(SoundStore.java:376)
	at org.newdawn.slick.Music.<init>(Music.java:204)
	at itdelatrisu.opsu.audio.MusicController.loadTrack(MusicController.java:144)
	at itdelatrisu.opsu.audio.MusicController.access$000(MusicController.java:54)
	at itdelatrisu.opsu.audio.MusicController$1.run(MusicController.java:116)

This happens on Java SE 8 JDK as well as OpenJDK8 when trying to access the main menu. It does not happen on Java9+ though.

@tpenguinltg
Copy link
Contributor

Duplicate of #418. I still don't understand how this is triggered because I'm on Java 8 and I don't get this error, both with sound effects on and off.

@itdelatrisu
Copy link
Owner

Linking #418.

@Lyonlancer5
Copy link
Contributor

Java 9+?
May be related to plasma-umass/doppio#497, specifically this and this.

Noting that FloatBuffer and ByteBuffer both extend Buffer, the signature java.nio.FloatBuffer.flip()Ljava/nio/FloatBuffer; seems to expect a return type of a FloatBuffer instead of the superclass' Buffer (javadoc referenced).

Could it be that the JDK used to build the JARs are JDK 9+ targeting JDK 7 compatibility?

@tpenguinltg
Copy link
Contributor

tpenguinltg commented Sep 9, 2018

Could it be that the JDK used to build the JARs are JDK 9+ targeting JDK 7 compatibility?

No, not for the JARs, but based on the build date, it looks like @Haringat is building it himself.

@Haringat: I trust that running javac -version shows a Java 8 version?

I pushed up an issue/421 branch on my fork with the workaround described in the links above. Can you please try building from that branch (or apply the diff yourself) and see if that fixes anything?

@8ar10der
Copy link

I meet the same issue on my ArchLinux with openjdk8, I have to change to the openjdk10 to let opsu work.

@tpenguinltg
Copy link
Contributor

@amaothree Are you building it yourself or using the JAR?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants