Skip to content

alpha 7 - #2566

Draft
samfreund wants to merge 110 commits into
PhotonVision:mainfrom
samfreund:alpha-7
Draft

alpha 7#2566
samfreund wants to merge 110 commits into
PhotonVision:mainfrom
samfreund:alpha-7

Conversation

@samfreund

@samfreund samfreund commented Jul 21, 2026

Copy link
Copy Markdown
Member

No description provided.

@github-actions github-actions Bot added the photonlib Things related to the PhotonVision library label Jul 21, 2026
@samfreund samfreund mentioned this pull request Jul 21, 2026
@github-actions github-actions Bot added the backend Things relating to photon-core and photon-server label Jul 28, 2026
@samfreund
samfreund force-pushed the alpha-7 branch 7 times, most recently from 096280e to bf6bdb0 Compare July 30, 2026 05:50
@samfreund

This comment was marked as resolved.

Comment thread .github/workflows/build.yml Outdated
Comment thread photon-targeting/src/main/native/jni/FileLoggerExtrasJNI.cpp
@github-actions github-actions Bot added documentation Anything relating to https://docs.photonvision.org frontend Having to do with PhotonClient and its related items labels Aug 4, 2026
Signed-off-by: samfreund <samf.236@proton.me>
Comment thread photon-client/src/components/settings/ApriltagControlCard.vue
Comment on lines +47 to +48
* field layout, or cannot be parsed. This way a {@code null} return is never used to signal
* failure; callers that detect a migration simply persist the result and parse it.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"This way a {@code null} return is never used to signal failure; callers that detect a migration simply persist the result and parse it."

I'm having trouble parsing this sentence -- help me deslop?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Doing it this way means we don't have to write a bunch of null check boilerplate. See SQLConfigProvider line 315 or thereabouts, we just check if the migrated string is the same or not instead of having a bunch of null checks and then checking for changes etc.


@Test
public void testMigrateOldFieldLayout() {
// exact serialization format produced by the old AprilTagFieldLayout

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

processedMat,
type,
MathUtils.wpiNanoTime() - latency,
NetworkTablesJNI.now() - latency,

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just a general note we should double check latency measurements remain sane to catch any obvious unit conversion errors on all our supported platforms + also intentionally run a TSP client and server with out of sync clocks to verify the E2E latency stays ~the same

}

@Test
public void testMigrateNewFieldLayoutUnchanged() {

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I know that migrateFieldLayoutJson uses "unchanged" to mean "it's already correct". Is there another data structure that can more explicitly encode that?


void PhotonCamera::CheckTimeSyncOrWarn(photon::PhotonPipelineResult& result) {
if (result.metadata.timeSinceLastPong > 5L * 1000000L) {
if (result.metadata.timeSinceLastPong > INT64_C(5) * 1000000000L) {

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe 2027 is the year we make timeSinceLastPong a unit type. This INT64_C() * MAGIC CONSTANT thing is gross

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

up to you matt, but I'd ask for a separate PR

Comment thread photon-targeting/build.gradle Outdated
@samfreund
samfreund force-pushed the alpha-7 branch 6 times, most recently from c2180b2 to 1654691 Compare August 31, 2026 05:47
Signed-off-by: samfreund <samf.236@proton.me>
@samfreund
samfreund requested a balanced review from Copilot August 31, 2026 17:04

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

Signed-off-by: samfreund <samf.236@proton.me>
Signed-off-by: samfreund <samf.236@proton.me>
Signed-off-by: samfreund <samf.236@proton.me>
Signed-off-by: samfreund <samf.236@proton.me>
Signed-off-by: samfreund <samf.236@proton.me>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backend Things relating to photon-core and photon-server documentation Anything relating to https://docs.photonvision.org frontend Having to do with PhotonClient and its related items photonlib Things related to the PhotonVision library

Projects

Status: In progress

Development

Successfully merging this pull request may close these issues.

5 participants