robotpy / mostrobotpy

Official Repository of python implementation of WPILib components
https://robotpy.github.io
Other
10 stars 11 forks source link

[BUG]: NT struct array topic doesn't publish schema #60

Closed truher closed 6 months ago

truher commented 8 months ago

Problem description

x = ntcore.NetworkTableInstance.getDefault().getStructArrayTopic("foo", Translation2d).publish()
x.set([Translation2d(0,0)])

is rendered as opaque in glass, and there is only one publisher, "foo."

adding

y = ntcore.NetworkTableInstance.getDefault().getStructTopic("foo", Translation2d).publish()
y.set(Translation2d(0,0)

adds the "/.schema" publisher and fixes the array rendering.

Operating System

Linux

Installed Python Packages

No response

Reproducible example code

No response

virtuald commented 8 months ago

WPILib fix in https://github.com/wpilibsuite/allwpilib/pull/6303

auscompgeek commented 6 months ago

Fixed in v2024.3.1