Skip to content

Starlark pop not working as documented #9953

@Hipska

Description

@Hipska

Relevant telegraf.conf:

Use this as Starlark code:

units = int(metric.tags.pop("units", "0"))

System info:

Telegraf 1.20.2 (git: HEAD f721f53)

Steps to reproduce:

  1. Use starlark processor with above code snippet
  2. Send metric not having the units tag.

Expected behavior:

No error and units should be 0.

Actual behavior:

Error in pop: pop: key must be of type ‘str’

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions