Skip to content

dateTime.format() value will display on output field but when executed returns invalid DateTime #25267

@mkostechuk

Description

@mkostechuk

Bug Description

Hello, the previous ticket was closed due to inactivity, but the issue is still there.

DateTime.fromISO() works when editing a node, but doesn't work when full workflow is executed

To Reproduce

  1. Paste my simple test workflow

{ "nodes": [ { "parameters": {}, "type": "n8n-nodes-base.manualTrigger", "typeVersion": 1, "position": [ 0, 0 ], "id": "89517ad5-18cc-43a2-8d60-23a6663fb776", "name": "When clicking ‘Execute workflow’" }, { "parameters": { "operation": "get", "dataTableId": { "__rl": true, "value": "RTUmXcXt5SSkmZr6", "mode": "list", "cachedResultName": "test2", "cachedResultUrl": "/projects/Gf5SWUTiJ2Xzg8or/datatables/RTUmXcXt5SSkmZr6" }, "limit": 1 }, "type": "n8n-nodes-base.dataTable", "typeVersion": 1, "position": [ 208, 0 ], "id": "4606fdc5-27a7-4bee-899b-35d3576ec415", "name": "Get row(s)" }, { "parameters": { "assignments": { "assignments": [ { "id": "3f58c229-f02b-4c92-8b10-0c7ecbc2b7bb", "name": "timestamp", "value": "={{ DateTime.fromISO($json.updatedAt).toFormat('dd/MM/yyyy HH:mm:ss') }}", "type": "string" }, { "id": "8b656ed7-bed8-4b48-89a8-b8e4480f774f", "name": "tt", "value": "={{ $json.updatedAt.toDateTime().setZone('Europe/Moscow').toFormat('dd/MM/yyyy HH:mm:ss') }}", "type": "string" } ] }, "includeOtherFields": true, "options": {} }, "type": "n8n-nodes-base.set", "typeVersion": 3.4, "position": [ 416, 0 ], "id": "69cf11a6-ef24-40e8-b73b-fe27b1adc5a4", "name": "Add timestamp" } ], "connections": { "When clicking ‘Execute workflow’": { "main": [ [ { "node": "Get row(s)", "type": "main", "index": 0 } ] ] }, "Get row(s)": { "main": [ [ { "node": "Add timestamp", "type": "main", "index": 0 } ] ] }, "Add timestamp": { "main": [ [] ] } }, "pinData": {}, "meta": { "instanceId": "435a1ecb9e606b9753a6ec0496715a8d59ac35a388e07f71b8ed8bb128b2d349" } }

  1. In the get rows node choose any table you have
  2. Run the workflow
  3. Check the output of the add timestamp node - you'll see "timestamp" field has "Invalid DateTime" output
Image
  1. Open editor of the add timestamp node
  2. Click "Execute step" button - now you have "timestamp" field with a proper datetime
Image

Expected behavior

I expect DateTime.fromISO() to work properly both in editor and when I execute the full workflow

Debug Info

Debug info

core

  • n8nVersion: 2.6.3
  • platform: docker (self-hosted)
  • nodeJsVersion: 22.22.0
  • nodeEnv: production
  • database: sqlite
  • executionMode: regular
  • concurrency: -1
  • license: enterprise (production)
  • consumerId: bf26dc67-2fd6-475f-9ae6-cdd0af7ee804

storage

  • success: all
  • error: all
  • progress: false
  • manual: true
  • binaryMode: filesystem

pruning

  • enabled: true
  • maxAge: 336 hours
  • maxCount: 10000 executions

client

  • userAgent: mozilla/5.0 (windows nt 10.0; win64; x64) applewebkit/537.36 (khtml, like gecko) chrome/144.0.0.0 safari/537.36
  • isTouchDevice: false

security

  • secureCookie: false

Generated at: 2026-02-03T21:01:25.477Z

Operating System

Debian 12

n8n Version

2.6.3

Node.js Version

22.22.0

Database

SQLite (default)

Execution mode

main (default)

Hosting

self hosted

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions