Skip to content
This repository has been archived by the owner on Jun 28, 2022. It is now read-only.

Difference in dataparsing after creating review #8

Open
Cnordbo opened this issue Apr 13, 2018 · 1 comment
Open

Difference in dataparsing after creating review #8

Cnordbo opened this issue Apr 13, 2018 · 1 comment

Comments

@Cnordbo
Copy link

Cnordbo commented Apr 13, 2018

Expected:

{
    "id": 31,
    "restaurant_id": 1,
    "name": "Some Name",
    "createdAt": 1504095567183,
    "updatedAt": 1504095567183,
    "rating": 4,
    "comments": "<removed for readability>"
  }

Actual:

  {
    "id": 2,
    "restaurant_id": "1",
    "name": "Morgan",
     "rating": "5",
    "comments": "asdasd",
    "createdAt": "2018-04-13T19:24:52.518Z",
    "updatedAt": "2018-04-13T19:24:52.518Z",
    "id": 42
  }

Difference:
Rating is parsed as string.
Date format differs within the same dataset.
Restaurant_id parsed as string.

Impact: Breaking

This causes the client application to require special transforms just to ensure that the data is parsed correctly.

@gitasong
Copy link

gitasong commented Oct 9, 2018

I'm confirming this for the restaurants endpoint. Sometimes after posting an updated restaurant/favorite, the updatedAt property is posting in milliseconds, sometimes in UTC format (the second format), while IDB has them all in milliseconds. Not sure why the difference, yet.

mejarc referenced this issue in mejarc/mws-restaurant-stage-3 Oct 23, 2018
bug: HTML does not have [lang]
mejarc referenced this issue in mejarc/mws-restaurant-stage-3 Oct 23, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants