alpacahq / alpacahq/Alpaca-API

Calendar API can get confused about dates

オープン
#157 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る
主要言語
言語のデータがありません
スター
173
フォーク
17
PR マージ指標
30日以内にマージされた PR はありません

説明

**Describe the bug**

When asked for market days between 1900-01-01 and 1900-12-31, the `calendar` API returns a single day, **1970-01-02**.

**To Reproduce**
`GET https://paper-api.alpaca.markets/v2/calendar?start=1900-01-01&end=1900-12-31`

**Expected behavior**
I'd expect it to return an empty array, that is, no days.
Or an error indicating data for that time is unknown.

**Additional context**

```
response {
method: 'GET',
path: 'https://paper-api.alpaca.markets/v2/calendar?start=1900-01-01&end=1900-12-31',
statusCode: 200,
statusMessage: 'OK',
headers: {
server: 'nginx/1.16.1',
date: 'Sat, 30 Jan 2021 00:11:54 GMT',
'content-type': 'application/json; charset=UTF-8',
'content-length': '99',
connection: 'keep-alive',
'access-control-allow-credentials': 'true',
vary: 'Origin'
},
body: [
{
date: '1970-01-02',
open: '09:30',
close: '16:00',
session_open: '0700',
session_close: '1900'
}
]
}
```

コントリビューションガイド

このリポジトリのコントリビューションガイドは索引されていません

評価

この issue はまだ評価されていません。

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。