Page MenuHomePhabricator

Consider Creating a Way to Debug Native Code Functions
Closed, ResolvedPublicFeature

Description

Description

Inspired by Ege on IRC chat:

<Ege> Hello everyone, is there any way to make a function print something? For debugging purposes so that I know what's going on within the function

Currently, the only way to do this is to make code changes in the evaluator and run it locally. That's obviously not sustainable on the live site.

We could create a special logging function in the evaluators and cause that logging function to spit out some metadata (so part of the Z22K2).

Desired behavior/Acceptance criteria (returned value, expected error, performance expectations, etc.)

  • team will discuss whether this is a feature we'd like to support
  • appropriate action will be taken (e.g. a design document or no design document)

Completion checklist

Event Timeline

I like this idea; we already have Z820 for injecting arbitrary content into the Z22K2, but providing an in-executor accessor for this would be a nice flow improvement if possible.

Jdforrester-WMF changed the subtype of this task from "Task" to "Feature Request".Jul 26 2023, 1:45 PM

Alternatively the debug information can simply be printed to stderr.

Change 992227 had a related patch set uploaded (by Jforrester; author: Jforrester):

[operations/deployment-charts@master] wikifunctions: Upgrade evaluators from 2023-11-29-143341 to 2024-01-18-182630

https://gerrit.wikimedia.org/r/992227

Change 992227 merged by jenkins-bot:

[operations/deployment-charts@master] wikifunctions: Upgrade evaluators from 2023-11-29-143341 to 2024-01-18-182630

https://gerrit.wikimedia.org/r/992227