IQSS / IQSS/dataverse-client-javascript
Inconsistency in `DatasetVersionInfo` model? (Date vs string)
Nessuno ha ancora preso questa issue.
- Lingua principale
- TypeScript
- Stelle
- 20
- Fork
- 11
- Merge medio
- 2g 5h
- PR unite (30g)
- 1
Descrizione
I noticed that in the DatasetVersionInfo model, the timestamps use inconsistent types:
releaseTime and createTime are represented as Date objects, while lastUpdateTime is represented as an ISO 8601 string and not transformed into a Date object:
The return values from the Dataverse API for retrieving a dataset version are all consistently ISO 8601 strings:
I was wondering what the reason for this is, or whether this inconsistency should be cleaned up? (If so, I'd be open to opening a PR for that)
Guida per i contributori
Apri la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Direzione di ricerca
Inizia con la definizione referenziata di DatasetVersionInfo in src/datasets/domain/models/Dataset.ts e con la trasformazione in src/datasets/infra/repositories/transformers/datasetTransformers.ts. Confronta il modo in cui releaseTime, createTime e lastUpdateTime sono rappresentati rispetto alla risposta dell’API Dataverse. Il lavoro è completo quando il modello e il transformer utilizzano una rappresentazione dei timestamp deliberata e coerente per tutti e tre i campi.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Valutazione
- Stack tecnologico
- typescript
- Ambito
- api, backend-api-design
- Tipo di issue
- Bug
- Difficoltà
- 2/5
- Tempo stimato
- 1-3 ore
- Stato di attività
- Attiva
- Chiarezza
- Abbastanza chiara
- Idoneità per principianti
- 68/100