redpanda-data / redpanda-data/connect

Add detailed error log

Open
#1,972 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

effort: lower enhancement ux
Dominant language
Go
Stars
8.8k
Forks
969
Avg merge
1d 13h
Merged PRs (30d)
64

Description

config.yaml
input:
  generate:
    interval: ""
    mapping: "root = {}"
    count: 1

pipeline:
  processors:
    - mapping:
        import "logic/logic1.blob"
        import "logic/logic2.blob"
        let rand num = random int (seed: timestamp_ unix nano () , min: 20, max: 40)
        root = if ($rand num < 30) J
           this. apply ("logic1")
        } else (
           this. apply ("logic2")
        }

logic/logic1.yaml
map logic1 {
  root = this.logic1.slice (0, 5)
}

logic/logic2.yaml
map logic1 {
  root = this.logic1.slice (5, 10)
}
ERRO failed assignment (line 5): failed assignment (line 2): expected array or string value, got null from field this. logic1

I have different *.blobl files, which I’m importing and then if I got any exception, it’s showing some field got null or expected array or string with line number (I may refer the same field name in multiple mappings) but not exactly in which mappings - which is difficult to find where exactly the issue is.

IMG_5082

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Reproduce the failure using config.yaml, logic/logic1.yaml, and logic/logic2.yaml, then trace how errors from the imported mappings are reported. Done means an error identifies the relevant mapping or imported file when the same field name appears in multiple mappings.

Written by the indexing model from the issue text.

Assessment

Tech stack
go
Domain
data-engineering, observability
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
32/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.