'Code' node seems to require explicit 'json' key in the output [v0.199.0]

Describe the issue/error/question

The code node seems to want the json key to be set explicitly, in the Run Once for Each Item mode, even though, it’s expected to work even without it.

What is the error message (if any)?

Please share the workflow

Information on your n8n setup

  • n8n version: 0.199.0
  • Database you’re using (default: SQLite): Postgres
  • Running n8n with the execution process [own(default), main]: main
  • Running n8n via [Docker, npm, n8n.cloud, desktop app]: Docker

Hi @shrey-42, this has surprised me as well but from looking at the example code I believe it’s expected. You can continue to use your existing Function Item nodes though (if you don’t want to use the Code node with the slightly different syntax), simply copy it over from an existing older workflow.