[coverage] Conformance findings: COMPLEX-016

Ouverte
#520 0 commentaires 0 réactions 0 personnes assignées Voir sur GitHub

Les mainteneurs répondent en général sous 1 jour

Personne n'a encore pris cette issue.

Évaluation

Difficulté
4/5
Temps estimé
1-2 jours
Accessibilité débutants
56/100
Type d'issue
Bug
Clarté
Plutôt claire
Activité
Active
Stack technique
go
Domaine
database

Piste de recherche

Start with the coverage PR diff under tests/ and inspect TestNestedTimestampNtzKeepsItsWallClockInArrayMapAndStruct to see how the failure is reproduced. Trace how the SEA/kernel backend renders nested ARRAY, MAP, and STRUCT values and handles each child field's time zone. Done means the test passes in a non-UTC session while nested NTZ values retain 09:15:00.123456 and the zoned timestamp remains 13:15:00.123456Z.

Rédigé par le modèle d'indexation à partir du texte de l'issue.

Description

Summary

Surfaced by the multi-language coverage fan-out while conformance-testing these SPEC-IDs against databricks/databricks-sql-go. Each finding is committed as an expected-failure (xfail) test in the coverage PR — the test asserts the CORRECT (post-fix) behavior and stays red until THIS driver (databricks/databricks-sql-go) is fixed, then flips green as a tripwire.

Findings

  • COMPLEX-016 [sea]: SEA/kernel backend applies the session-zone conversion to nested TIMESTAMP_NTZ leaves: an NTZ leaf inside ARRAY/MAP/STRUCT renders 05:15:00.123456 instead of the literal's 09:15:00.123456 under America/New_York, while the top-level NTZ column is correct — the container walk forwards one session location to every child instead of resolving the render location per child field
    • failing test: TestNestedTimestampNtzKeepsItsWallClockInArrayMapAndStruct (see the coverage PR diff under tests/)
  • COMPLEX-016: SEA/kernel backend applies the session-zone conversion to nested TIMESTAMP_NTZ leaves: under America/New_York an NTZ leaf inside ARRAY/MAP/STRUCT renders 05:15:00.123456 instead of the literal's 09:15:00.123456, while the top-level NTZ column is rendered correctly — the container walk forwards one session location to every child instead of resolving the render location per child field

Reproduce & Expected

COMPLEX-016 — Verify that under a NON-UTC session time zone a TIMESTAMP_NTZ leaf nested inside an ARRAY element, a MAP value, a STRUCT field, and a STRUCT inside a STRUCT keeps the exact wall clock the literal car…

Reproduce:

  • Set the session time zone through whichever surface the driver exposes -- a
    session parameter on connect (e.g. a timezone session param) or, where no
    such option exists, SET TIME ZONE 'America/New_York' on the same session
    before the test query. A NON-UTC zone is REQUIRED: under a UTC session the
    shifted and unshifted NTZ renderings coincide and the case proves nothing.

Expected (per the shared spec):

  • result has exactly 1 row(s)
  • full assertion contract:
result:
- row_count: 1
- timestamp_wall_clock:
    path: ntz_array[0]
    equals: '2024-06-15 09:15:00.123456'
- timestamp_wall_clock:
    path: ntz_map['a']
    equals: '2024-06-15 09:15:00.123456'
- timestamp_wall_clock:
    path: ts_struct.ntz
    equals: '2024-06-15 09:15:00.123456'
- timestamp_wall_clock:
    path: ts_struct.inner.ntz
    equals: '2024-06-15 09:15:00.123456'
- timestamp_instant:
    path: ts_struct.zoned
    equals: '2024-06-15T13:15:00.123456Z'
- struct_field:
    column: ts_struct
    field: label
    equals: pt

Context

Langage dominant
Go
Étoiles
53
Forks
69
Merge moyen
2 j 12 h
PR mergées (30 j)
16

Préparer son environnement

Par où commencer

  1. Lisez l'issue en entier, puis le guide de contribution du projet.
  2. Signalez en commentaire que vous la prenez — cela évite que deux personnes fassent le même travail.
  3. Forkez le dépôt et travaillez sur une branche.
  4. Ouvrez une pull request qui référence le numéro de l'issue.

Autres issues de databricks/databricks-sql-go

Toutes les issues de databricks/databricks-sql-go

Issues similaires

Plus d'issues Go

Recevez les nouvelles issues par e-mail

Un résumé court des issues GitHub adaptées aux débutants.