wpilibsuite / 2024Beta

Repository for Beta Testing of 2024 Software
32 stars 5 forks source link

Shuffleboard crashes when adding Camera widget on Windows 11 #51

Closed chauser closed 8 months ago

chauser commented 8 months ago

When I try to drag a CameraServer item onto a new tab in Shuffleboard, the Shuffleboard crashes. This occurs on my Windows 11 laptop but not on my Windows 10 laptop. Other differences between the two machines: Windows 11 is 10 cores, 12 logical processors, 1920x1200 display (but settting to 1920x1080 did not help). Windows 10 is 4 cores, 8 l.p., 1920x1080 display. Both machines have wpilib 2024 beta 4 installed.

I ran the 2023 shuffleboard on the Windows 11 machine and it did not crash. I ran the 2024 shuffleboard with the 2023 JVM and it did crash. By running from the command line I captured the shuffleboard output. The crashing one produces terminal output that end like this:

INFO: Took 3142ms to start Shuffleboard
#
# A fatal error has been detected by the Java Runtime Environment:
#
#  EXCEPTION_ACCESS_VIOLATION (0xc0000005) at pc=0x00007ffb67fdc7f0, pid=22448, tid=21148
#
# JRE version: OpenJDK Runtime Environment Temurin-17.0.5+8 (17.0.5+8) (build 17.0.5+8)
# Java VM: OpenJDK 64-Bit Server VM Temurin-17.0.5+8 (17.0.5+8, mixed mode, sharing, tiered, compressed oops, compressed class ptrs, g1 gc, windows-amd64)
# Problematic frame:
# V  [jvm.dll+0xc7f0]
#
# No core dump will be written. Minidumps are not enabled by default on client versions of Windows
#
# An error report file with more information is saved as:
# C:\Users\Public\wpilib\2024\hs_err_pid22448.log
#
# If you would like to submit a bug report, please visit:
#   https://github.com/adoptium/adoptium-support/issues

The error report file is attached. hs_err_pid22448.log

The runs of shuffleboard that do not crash (both 2023 and 2024 versions) all show something different after the INFO message regarding shuffleboards startup time. One of those looks like this:

VideoException [edu.wpi.first.cscore.VideoException: empty value]
        at edu.wpi.first.cscore.CameraServerJNI.getTelemetryAverageValue(Native Method)
        at edu.wpi.first.cscore.CameraServerJNI.getTelemetryAverageValue(CameraServerJNI.java:364)
        at edu.wpi.first.cscore.VideoSource.getActualDataRate(VideoSource.java:334)
        at edu.wpi.first.shuffleboard.plugin.cameraserver.source.CameraServerSource.lambda$new$5(CameraServerSource.java:139)

Dec 21, 2023 2:51:28 PM edu.wpi.first.shuffleboard.plugin.cameraserver.source.CameraServerSource lambda$new$5
WARNING: Could not get framerate
VideoException [edu.wpi.first.cscore.VideoException: empty value]
        at edu.wpi.first.cscore.CameraServerJNI.getTelemetryAverageValue(Native Method)
        at edu.wpi.first.cscore.CameraServerJNI.getTelemetryAverageValue(CameraServerJNI.java:364)
        at edu.wpi.first.cscore.VideoSource.getActualFPS(VideoSource.java:321)
        at edu.wpi.first.shuffleboard.plugin.cameraserver.source.CameraServerSource.lambda$new$5(CameraServerSource.java:145)

Those WARNINGs and VideoExceptions do not appear on the terminal for the crashing version so they may be relevant.

I will try to get my hands on another Windows 11 machine for further differential testing tonight.

ThadHouse commented 8 months ago

Just for a quick sanity test, you're not running Windows 11 N on that system, right?

chauser commented 8 months ago

Correct. It's the Home version.

On Thu, Dec 21, 2023, 3:30 PM Thad House @.***> wrote:

Just for a quick sanity test, you're not running Windows 11 N on that system, right?

— Reply to this email directly, view it on GitHub https://github.com/wpilibsuite/2024Beta/issues/51#issuecomment-1867049666, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAGLUUY5TW7TN5I3VRUZD2DYKTBA3AVCNFSM6AAAAABA7CRQU6VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTQNRXGA2DSNRWGY . You are receiving this because you authored the thread.Message ID: @.***>

ThadHouse commented 8 months ago

We found the bug, and its new to Beta 4. Was your testing on Windows 10 using Beta 4 shuffleboard? Theres no difference between 10 and 11 with the bug, it would have broken on all platforms.

chauser commented 8 months ago

Too many darn computers. You're right -- the Windows 10 one was on Beta 3.

On Thu, Dec 21, 2023 at 4:13 PM Thad House @.***> wrote:

We found the bug, and its new to Beta 4. Was your testing on Windows 10 using Beta 4 shuffleboard? Theres no difference between 10 and 11 with the bug, it would have broken on all platforms.

— Reply to this email directly, view it on GitHub https://github.com/wpilibsuite/2024Beta/issues/51#issuecomment-1867073949, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAGLUU24R6SYBO7MEPOYUQTYKTGAXAVCNFSM6AAAAABA7CRQU6VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTQNRXGA3TGOJUHE . You are receiving this because you authored the thread.Message ID: @.***>