You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Calling telemetry.addData("foo", () -> null); in an OpMode will cause a NullPointerException at org.firstinspires.ftc.robotcore.internal.opmode.TelemetryImpl$Value.compose(TelemtryImpl.java:134) when telemetry is being updated.
The decompiled code doesn't make the reason immediately obvious.
The text was updated successfully, but these errors were encountered:
When you call telemetry.addData("foo", () -> null);, you are adding a data point to the telemetry with the name "foo" and a value supplier that returns null. This means that when the telemetry tries to update and compose the data to be sent to the driver station, it will try to call the compose() method on the value supplier, which will throw a NullPointerException because the value supplier is returning null.
To avoid this error, you should make sure that the value supplier returns a non-null value or remove the call to telemetry.addData("foo", () -> null); if you do not actually need to add data with a null value to the telemetry.
Calling
telemetry.addData("foo", () -> null);
in an OpMode will cause a NullPointerException atorg.firstinspires.ftc.robotcore.internal.opmode.TelemetryImpl$Value.compose(TelemtryImpl.java:134)
when telemetry is being updated.The decompiled code doesn't make the reason immediately obvious.
The text was updated successfully, but these errors were encountered: