tastytrade 10.2.3__tar.gz → 11.0.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {tastytrade-10.2.3 → tastytrade-11.0.0}/.github/CONTRIBUTING.md +1 -1
- {tastytrade-10.2.3 → tastytrade-11.0.0}/.github/pull_request_template.md +1 -1
- {tastytrade-10.2.3 → tastytrade-11.0.0}/.github/workflows/python-app.yml +19 -10
- tastytrade-11.0.0/.python-version +1 -0
- {tastytrade-10.2.3 → tastytrade-11.0.0}/PKG-INFO +8 -9
- {tastytrade-10.2.3 → tastytrade-11.0.0}/README.md +2 -3
- {tastytrade-10.2.3 → tastytrade-11.0.0}/docs/index.rst +0 -2
- {tastytrade-10.2.3 → tastytrade-11.0.0}/docs/orders.rst +21 -1
- tastytrade-11.0.0/docs/sessions.rst +59 -0
- {tastytrade-10.2.3 → tastytrade-11.0.0}/pyproject.toml +11 -8
- {tastytrade-10.2.3 → tastytrade-11.0.0}/tastytrade/__init__.py +3 -8
- {tastytrade-10.2.3 → tastytrade-11.0.0}/tastytrade/account.py +261 -423
- {tastytrade-10.2.3 → tastytrade-11.0.0}/tastytrade/instruments.py +255 -248
- {tastytrade-10.2.3 → tastytrade-11.0.0}/tastytrade/market_data.py +41 -41
- {tastytrade-10.2.3 → tastytrade-11.0.0}/tastytrade/market_sessions.py +7 -8
- {tastytrade-10.2.3 → tastytrade-11.0.0}/tastytrade/metrics.py +45 -46
- tastytrade-11.0.0/tastytrade/oauth.py +129 -0
- {tastytrade-10.2.3 → tastytrade-11.0.0}/tastytrade/order.py +70 -70
- {tastytrade-10.2.3 → tastytrade-11.0.0}/tastytrade/session.py +156 -333
- {tastytrade-10.2.3 → tastytrade-11.0.0}/tastytrade/streamer.py +49 -60
- {tastytrade-10.2.3 → tastytrade-11.0.0}/tastytrade/utils.py +130 -49
- {tastytrade-10.2.3 → tastytrade-11.0.0}/tastytrade/watchlists.py +14 -14
- tastytrade-11.0.0/tests/conftest.py +22 -0
- {tastytrade-10.2.3 → tastytrade-11.0.0}/tests/test_account.py +8 -5
- {tastytrade-10.2.3 → tastytrade-11.0.0}/tests/test_session.py +8 -24
- {tastytrade-10.2.3 → tastytrade-11.0.0}/tests/test_streamer.py +6 -9
- tastytrade-11.0.0/uv.lock +2210 -0
- tastytrade-10.2.3/.python-version +0 -1
- tastytrade-10.2.3/docs/api/backtesting.rst +0 -6
- tastytrade-10.2.3/docs/backtest.rst +0 -32
- tastytrade-10.2.3/docs/sessions.rst +0 -32
- tastytrade-10.2.3/tastytrade/backtest.py +0 -250
- tastytrade-10.2.3/tests/conftest.py +0 -34
- tastytrade-10.2.3/tests/test_backtest.py +0 -24
- tastytrade-10.2.3/uv.lock +0 -1602
- {tastytrade-10.2.3 → tastytrade-11.0.0}/.github/FUNDING.yml +0 -0
- {tastytrade-10.2.3 → tastytrade-11.0.0}/.github/workflows/python-publish-test.yml +0 -0
- {tastytrade-10.2.3 → tastytrade-11.0.0}/.github/workflows/python-publish.yml +0 -0
- {tastytrade-10.2.3 → tastytrade-11.0.0}/.gitignore +0 -0
- {tastytrade-10.2.3 → tastytrade-11.0.0}/.readthedocs.yaml +0 -0
- {tastytrade-10.2.3 → tastytrade-11.0.0}/LICENSE +0 -0
- {tastytrade-10.2.3 → tastytrade-11.0.0}/Makefile +0 -0
- {tastytrade-10.2.3 → tastytrade-11.0.0}/docs/Makefile +0 -0
- {tastytrade-10.2.3 → tastytrade-11.0.0}/docs/account-streamer.rst +0 -0
- {tastytrade-10.2.3 → tastytrade-11.0.0}/docs/accounts.rst +0 -0
- {tastytrade-10.2.3 → tastytrade-11.0.0}/docs/api/account.rst +0 -0
- {tastytrade-10.2.3 → tastytrade-11.0.0}/docs/api/dxfeed.rst +0 -0
- {tastytrade-10.2.3 → tastytrade-11.0.0}/docs/api/instruments.rst +0 -0
- {tastytrade-10.2.3 → tastytrade-11.0.0}/docs/api/market-data.rst +0 -0
- {tastytrade-10.2.3 → tastytrade-11.0.0}/docs/api/market-sessions.rst +0 -0
- {tastytrade-10.2.3 → tastytrade-11.0.0}/docs/api/metrics.rst +0 -0
- {tastytrade-10.2.3 → tastytrade-11.0.0}/docs/api/order.rst +0 -0
- {tastytrade-10.2.3 → tastytrade-11.0.0}/docs/api/search.rst +0 -0
- {tastytrade-10.2.3 → tastytrade-11.0.0}/docs/api/session.rst +0 -0
- {tastytrade-10.2.3 → tastytrade-11.0.0}/docs/api/streamer.rst +0 -0
- {tastytrade-10.2.3 → tastytrade-11.0.0}/docs/api/utils.rst +0 -0
- {tastytrade-10.2.3 → tastytrade-11.0.0}/docs/api/watchlists.rst +0 -0
- {tastytrade-10.2.3 → tastytrade-11.0.0}/docs/conf.py +0 -0
- {tastytrade-10.2.3 → tastytrade-11.0.0}/docs/data-streamer.rst +0 -0
- {tastytrade-10.2.3 → tastytrade-11.0.0}/docs/img/netliq.png +0 -0
- {tastytrade-10.2.3 → tastytrade-11.0.0}/docs/installation.rst +0 -0
- {tastytrade-10.2.3 → tastytrade-11.0.0}/docs/instruments.rst +0 -0
- {tastytrade-10.2.3 → tastytrade-11.0.0}/docs/make.bat +0 -0
- {tastytrade-10.2.3 → tastytrade-11.0.0}/docs/market-data.rst +0 -0
- {tastytrade-10.2.3 → tastytrade-11.0.0}/docs/market-sessions.rst +0 -0
- {tastytrade-10.2.3 → tastytrade-11.0.0}/docs/sync-async.rst +0 -0
- {tastytrade-10.2.3 → tastytrade-11.0.0}/docs/watchlists.rst +0 -0
- {tastytrade-10.2.3 → tastytrade-11.0.0}/tastytrade/dxfeed/__init__.py +0 -0
- {tastytrade-10.2.3 → tastytrade-11.0.0}/tastytrade/dxfeed/candle.py +0 -0
- {tastytrade-10.2.3 → tastytrade-11.0.0}/tastytrade/dxfeed/event.py +0 -0
- {tastytrade-10.2.3 → tastytrade-11.0.0}/tastytrade/dxfeed/greeks.py +0 -0
- {tastytrade-10.2.3 → tastytrade-11.0.0}/tastytrade/dxfeed/profile.py +0 -0
- {tastytrade-10.2.3 → tastytrade-11.0.0}/tastytrade/dxfeed/quote.py +0 -0
- {tastytrade-10.2.3 → tastytrade-11.0.0}/tastytrade/dxfeed/summary.py +0 -0
- {tastytrade-10.2.3 → tastytrade-11.0.0}/tastytrade/dxfeed/theoprice.py +0 -0
- {tastytrade-10.2.3 → tastytrade-11.0.0}/tastytrade/dxfeed/timeandsale.py +0 -0
- {tastytrade-10.2.3 → tastytrade-11.0.0}/tastytrade/dxfeed/trade.py +0 -0
- {tastytrade-10.2.3 → tastytrade-11.0.0}/tastytrade/dxfeed/underlying.py +0 -0
- {tastytrade-10.2.3 → tastytrade-11.0.0}/tastytrade/py.typed +0 -0
- {tastytrade-10.2.3 → tastytrade-11.0.0}/tastytrade/search.py +0 -0
- {tastytrade-10.2.3 → tastytrade-11.0.0}/tests/__init__.py +0 -0
- {tastytrade-10.2.3 → tastytrade-11.0.0}/tests/test_dxfeed.py +0 -0
- {tastytrade-10.2.3 → tastytrade-11.0.0}/tests/test_instruments.py +0 -0
- {tastytrade-10.2.3 → tastytrade-11.0.0}/tests/test_market_data.py +0 -0
- {tastytrade-10.2.3 → tastytrade-11.0.0}/tests/test_market_sessions.py +0 -0
- {tastytrade-10.2.3 → tastytrade-11.0.0}/tests/test_metrics.py +0 -0
- {tastytrade-10.2.3 → tastytrade-11.0.0}/tests/test_search.py +0 -0
- {tastytrade-10.2.3 → tastytrade-11.0.0}/tests/test_utils.py +0 -0
- {tastytrade-10.2.3 → tastytrade-11.0.0}/tests/test_watchlists.py +0 -0
|
@@ -5,6 +5,6 @@ Since Tastytrade certification sessions are severely limited in capabilities, th
|
|
|
5
5
|
## Steps to follow to contribute
|
|
6
6
|
|
|
7
7
|
1. Fork the repository to your personal Github account and make your proposed changes.
|
|
8
|
-
2. Export your username, password, and account number to the following Github Actions repository secrets: `
|
|
8
|
+
2. Export your username, password, and account number to the following Github Actions repository secrets: `TT_SECRET`, `TT_REFRESH`, and `TT_ACCOUNT`. The account should be a margin account.
|
|
9
9
|
3. Make sure you have at least one share of long $F in your account, which will be used to place the OCO complex order (nothing will fill), as well as at least $2 of buying power.
|
|
10
10
|
4. Run `make install` to create the virtual environment, `make lint` to format your code, and `make test` to run the tests locally.
|
|
@@ -6,7 +6,7 @@ Fixes ...
|
|
|
6
6
|
## Pre-merge checklist
|
|
7
7
|
- [ ] Code formatted correctly (check with `make lint`)
|
|
8
8
|
- [ ] Code implemented for both sync and async
|
|
9
|
-
- [ ] Passing tests locally (check with `make test`, make sure you have `
|
|
9
|
+
- [ ] Passing tests locally (check with `make test`, make sure you have `TT_REFRESH`, `TT_SECRET`, and `TT_ACCOUNT` environment variables set)
|
|
10
10
|
- [ ] New tests added (if applicable)
|
|
11
11
|
|
|
12
12
|
Please note that, in order to pass the tests, you'll need to set up your Tastytrade credentials as repository secrets on your local fork. Read more at CONTRIBUTING.md.
|
|
@@ -9,16 +9,25 @@ on:
|
|
|
9
9
|
jobs:
|
|
10
10
|
build:
|
|
11
11
|
runs-on: ubuntu-latest
|
|
12
|
+
strategy:
|
|
13
|
+
max-parallel: 1
|
|
14
|
+
matrix:
|
|
15
|
+
python-version:
|
|
16
|
+
- "3.10"
|
|
17
|
+
- "3.11"
|
|
18
|
+
- "3.12"
|
|
19
|
+
- "3.13"
|
|
20
|
+
- "3.14"
|
|
12
21
|
steps:
|
|
13
|
-
- uses: actions/checkout@
|
|
14
|
-
- name:
|
|
15
|
-
uses:
|
|
22
|
+
- uses: actions/checkout@v5
|
|
23
|
+
- name: Install uv and Python
|
|
24
|
+
uses: astral-sh/setup-uv@v6
|
|
16
25
|
with:
|
|
17
|
-
|
|
18
|
-
|
|
26
|
+
enable-cache: true
|
|
27
|
+
python-version: ${{ matrix.python-version }}
|
|
19
28
|
- name: Setup uv venv
|
|
20
29
|
run: |
|
|
21
|
-
uv sync
|
|
30
|
+
uv sync --locked --all-extras --dev
|
|
22
31
|
- name: Lint with ruff
|
|
23
32
|
run: |
|
|
24
33
|
uv run ruff check tastytrade/ tests/
|
|
@@ -32,8 +41,8 @@ jobs:
|
|
|
32
41
|
run: |
|
|
33
42
|
uv run pytest --cov=tastytrade --cov-report=term-missing tests/ --cov-fail-under=95
|
|
34
43
|
env:
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
TT_USERNAME_SANDBOX: ${{ secrets.TT_USERNAME_SANDBOX }}
|
|
38
|
-
TT_PASSWORD_SANDBOX: ${{ secrets.TT_PASSWORD_SANDBOX }}
|
|
44
|
+
TT_REFRESH_SANDBOX: ${{ secrets.TT_REFRESH_SANDBOX }}
|
|
45
|
+
TT_SECRET_SANDBOX: ${{ secrets.TT_SECRET_SANDBOX }}
|
|
39
46
|
TT_ACCOUNT: ${{ secrets.TT_ACCOUNT }}
|
|
47
|
+
TT_REFRESH: ${{ secrets.TT_REFRESH }}
|
|
48
|
+
TT_SECRET: ${{ secrets.TT_SECRET }}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
3.10
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: tastytrade
|
|
3
|
-
Version:
|
|
3
|
+
Version: 11.0.0
|
|
4
4
|
Summary: An unofficial, sync/async SDK for Tastytrade!
|
|
5
5
|
Project-URL: Homepage, https://github.com/tastyware/tastytrade
|
|
6
6
|
Project-URL: Documentation, https://tastyworks-api.rtfd.io
|
|
@@ -44,7 +44,6 @@ Classifier: Operating System :: Unix
|
|
|
44
44
|
Classifier: Programming Language :: Python
|
|
45
45
|
Classifier: Programming Language :: Python :: 3
|
|
46
46
|
Classifier: Programming Language :: Python :: 3 :: Only
|
|
47
|
-
Classifier: Programming Language :: Python :: 3.9
|
|
48
47
|
Classifier: Programming Language :: Python :: 3.10
|
|
49
48
|
Classifier: Programming Language :: Python :: 3.11
|
|
50
49
|
Classifier: Programming Language :: Python :: 3.12
|
|
@@ -52,11 +51,12 @@ Classifier: Programming Language :: Python :: 3.13
|
|
|
52
51
|
Classifier: Programming Language :: Python :: 3.14
|
|
53
52
|
Classifier: Topic :: Internet :: WWW/HTTP
|
|
54
53
|
Classifier: Topic :: Software Development :: Libraries :: Python Modules
|
|
54
|
+
Classifier: Typing :: Typed
|
|
55
55
|
Requires-Python: >=3.9
|
|
56
|
-
Requires-Dist: httpx>=0.
|
|
57
|
-
Requires-Dist: pandas-market-calendars>=
|
|
58
|
-
Requires-Dist: pydantic>=2.9
|
|
59
|
-
Requires-Dist: websockets>=15
|
|
56
|
+
Requires-Dist: httpx>=0.28.1
|
|
57
|
+
Requires-Dist: pandas-market-calendars>=5.1.1
|
|
58
|
+
Requires-Dist: pydantic>=2.11.9
|
|
59
|
+
Requires-Dist: websockets>=15.0.1
|
|
60
60
|
Description-Content-Type: text/markdown
|
|
61
61
|
|
|
62
62
|
[](https://tastyworks-api.readthedocs.io/en/latest/?badge=latest)
|
|
@@ -92,12 +92,11 @@ $ pip install tastytrade
|
|
|
92
92
|
|
|
93
93
|
## Creating a session
|
|
94
94
|
|
|
95
|
-
A session object is required to authenticate your requests to the Tastytrade API.
|
|
96
|
-
You can create a real session using your normal login, or a certification (test) session using your certification login.
|
|
95
|
+
A session object is required to authenticate your requests to the Tastytrade API. See [here](https://tastyworks-api.readthedocs.io/en/latest/sessions.html) for information on how to set up an OAuth application.
|
|
97
96
|
|
|
98
97
|
```python
|
|
99
98
|
from tastytrade import Session
|
|
100
|
-
session = Session('
|
|
99
|
+
session = Session('client_secret', 'refresh_token')
|
|
101
100
|
```
|
|
102
101
|
|
|
103
102
|
## Using the streamer
|
|
@@ -31,12 +31,11 @@ $ pip install tastytrade
|
|
|
31
31
|
|
|
32
32
|
## Creating a session
|
|
33
33
|
|
|
34
|
-
A session object is required to authenticate your requests to the Tastytrade API.
|
|
35
|
-
You can create a real session using your normal login, or a certification (test) session using your certification login.
|
|
34
|
+
A session object is required to authenticate your requests to the Tastytrade API. See [here](https://tastyworks-api.readthedocs.io/en/latest/sessions.html) for information on how to set up an OAuth application.
|
|
36
35
|
|
|
37
36
|
```python
|
|
38
37
|
from tastytrade import Session
|
|
39
|
-
session = Session('
|
|
38
|
+
session = Session('client_secret', 'refresh_token')
|
|
40
39
|
```
|
|
41
40
|
|
|
42
41
|
## Using the streamer
|
|
@@ -39,7 +39,6 @@ A simple, reverse-engineered, sync/async SDK for Tastytrade built on their (now
|
|
|
39
39
|
account-streamer
|
|
40
40
|
data-streamer
|
|
41
41
|
market-data
|
|
42
|
-
backtest
|
|
43
42
|
market-sessions
|
|
44
43
|
watchlists
|
|
45
44
|
|
|
@@ -49,7 +48,6 @@ A simple, reverse-engineered, sync/async SDK for Tastytrade built on their (now
|
|
|
49
48
|
:hidden:
|
|
50
49
|
|
|
51
50
|
api/account
|
|
52
|
-
api/backtesting
|
|
53
51
|
api/dxfeed
|
|
54
52
|
api/instruments
|
|
55
53
|
api/market-data
|
|
@@ -131,7 +131,7 @@ Note that to cancel complex orders, you need to use the ``delete_complex_order``
|
|
|
131
131
|
Notional market orders
|
|
132
132
|
----------------------
|
|
133
133
|
|
|
134
|
-
Notional orders are slightly different from normal orders. Since the market will determine both the quantity and the price for you, you need to pass
|
|
134
|
+
Notional orders are slightly different from normal orders. Since the market will determine both the quantity and the price for you, you need to pass ``value`` instead of price, and pass ``None`` for the ``quantity`` parameter to ``build_leg``.
|
|
135
135
|
|
|
136
136
|
.. code-block:: python
|
|
137
137
|
|
|
@@ -145,3 +145,23 @@ Notional orders are slightly different from normal orders. Since the market will
|
|
|
145
145
|
]
|
|
146
146
|
)
|
|
147
147
|
resp = account.place_order(session, order, dry_run=False)
|
|
148
|
+
|
|
149
|
+
Cryptocurrency orders
|
|
150
|
+
---------------------
|
|
151
|
+
|
|
152
|
+
Cryptocurrency orders should use the special ``IOC`` TIF:
|
|
153
|
+
|
|
154
|
+
.. code-block:: python
|
|
155
|
+
|
|
156
|
+
order = NewOrder(
|
|
157
|
+
time_in_force=OrderTimeInForce.IOC,
|
|
158
|
+
order_type=OrderType.NOTIONAL_MARKET,
|
|
159
|
+
value=-Decimal(100), # buy $100 of ETH
|
|
160
|
+
legs=[
|
|
161
|
+
Leg(
|
|
162
|
+
instrument_type=InstrumentType.CRYPTOCURRENCY,
|
|
163
|
+
action=OrderAction.BUY_TO_OPEN,
|
|
164
|
+
symbol="ETH/USD",
|
|
165
|
+
),
|
|
166
|
+
],
|
|
167
|
+
)
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
Sessions
|
|
2
|
+
========
|
|
3
|
+
|
|
4
|
+
Creating an OAuth application
|
|
5
|
+
-----------------------------
|
|
6
|
+
|
|
7
|
+
A session object is required to authenticate your requests to the Tastytrade API. Tastytrade uses OAuth logins, which allow you to connect applications (third-party or private) to your trading account to use the API.
|
|
8
|
+
|
|
9
|
+
To get started, create a new OAuth application `here <https://my.tastytrade.com/app.html#/manage/api-access/oauth-applications>`_. Check all the scopes you plan to use, add `http://localhost:8000` as a valid callback, and create the application. **Save the client secret**, you'll need it later!
|
|
10
|
+
|
|
11
|
+
Generating an initial refresh token
|
|
12
|
+
-----------------------------------
|
|
13
|
+
|
|
14
|
+
In order to generate an initial refresh token, you have two options. The easiest way is to simply generate one from Tastytrade's website: go to OAuth Applications > Manage > Create Grant to get a new refresh token, **which you should also save**.
|
|
15
|
+
|
|
16
|
+
The other option (which is actually the only option for sandbox accounts) is to run this helper code:
|
|
17
|
+
|
|
18
|
+
.. code-block:: python
|
|
19
|
+
|
|
20
|
+
from tastytrade.oauth import login
|
|
21
|
+
login(is_test=True)
|
|
22
|
+
|
|
23
|
+
This will open up a web interface in your browser where you'll be prompted to paste your client ID and client secret. These credentials will then be used to connect your application to Tastytrade. After following the steps in your browser, you should see your new refresh token in the browser and in the console.
|
|
24
|
+
|
|
25
|
+
At this point, OAuth is now setup correctly! Doing these steps once is sufficient for **indefinite usage** of ``Session`` for authentication to the API, since refresh tokens never expire. From now on you can simply authenticate with your client secret and refresh token.
|
|
26
|
+
|
|
27
|
+
Creating a session
|
|
28
|
+
------------------
|
|
29
|
+
|
|
30
|
+
.. code-block:: python
|
|
31
|
+
|
|
32
|
+
from tastytrade import Session
|
|
33
|
+
|
|
34
|
+
session = Session('client_secret', 'refresh_token')
|
|
35
|
+
|
|
36
|
+
These session objects can be used to make API requests:
|
|
37
|
+
|
|
38
|
+
.. code-block:: python
|
|
39
|
+
|
|
40
|
+
from tastytrade import Account
|
|
41
|
+
|
|
42
|
+
accounts = Account.get(session)
|
|
43
|
+
|
|
44
|
+
Note that OAuth sessions make API requests using a special session token, which has a duration of only 15 minutes. However, since the refresh tokens last forever, you can call ``Session.refresh()`` to refresh the session token whenever needed. The session object will keep track of session expiration time for you to make it easier to know when to refresh:
|
|
45
|
+
|
|
46
|
+
.. code-block:: python
|
|
47
|
+
|
|
48
|
+
from tastytrade.utils import now_in_new_york
|
|
49
|
+
|
|
50
|
+
if now_in_new_york() > session.session_expiration:
|
|
51
|
+
session.refresh()
|
|
52
|
+
print(Account.get(session))
|
|
53
|
+
|
|
54
|
+
A sandbox account for testing can be created `here <https://developer.tastytrade.com/sandbox/>`_, then used to create a session in the same way:
|
|
55
|
+
|
|
56
|
+
.. code-block:: python
|
|
57
|
+
|
|
58
|
+
from tastytrade import Session
|
|
59
|
+
session = Session('client_secret', 'refresh_token', is_test=True)
|
|
@@ -24,7 +24,6 @@ classifiers = [
|
|
|
24
24
|
"Programming Language :: Python",
|
|
25
25
|
"Programming Language :: Python :: 3",
|
|
26
26
|
"Programming Language :: Python :: 3 :: Only",
|
|
27
|
-
"Programming Language :: Python :: 3.9",
|
|
28
27
|
"Programming Language :: Python :: 3.10",
|
|
29
28
|
"Programming Language :: Python :: 3.11",
|
|
30
29
|
"Programming Language :: Python :: 3.12",
|
|
@@ -32,6 +31,7 @@ classifiers = [
|
|
|
32
31
|
"Programming Language :: Python :: 3.14",
|
|
33
32
|
"Topic :: Software Development :: Libraries :: Python Modules",
|
|
34
33
|
"Topic :: Internet :: WWW/HTTP",
|
|
34
|
+
"Typing :: Typed",
|
|
35
35
|
]
|
|
36
36
|
requires-python = ">=3.9"
|
|
37
37
|
license = {file = "LICENSE"}
|
|
@@ -39,10 +39,10 @@ authors = [
|
|
|
39
39
|
{name = "Graeme Holliday", email = "graeme@tastyware.dev"},
|
|
40
40
|
]
|
|
41
41
|
dependencies = [
|
|
42
|
-
"httpx>=0.
|
|
43
|
-
"pandas-market-calendars>=
|
|
44
|
-
"pydantic>=2.9
|
|
45
|
-
"websockets>=15",
|
|
42
|
+
"httpx>=0.28.1",
|
|
43
|
+
"pandas-market-calendars>=5.1.1",
|
|
44
|
+
"pydantic>=2.11.9",
|
|
45
|
+
"websockets>=15.0.1",
|
|
46
46
|
]
|
|
47
47
|
dynamic = ["version"]
|
|
48
48
|
|
|
@@ -58,14 +58,14 @@ dev = [
|
|
|
58
58
|
"pytest>=8.3.3",
|
|
59
59
|
"pytest-aio>=1.5.0",
|
|
60
60
|
"pytest-cov>=5.0.0",
|
|
61
|
-
"ruff>=0.
|
|
61
|
+
"ruff>=0.13.2",
|
|
62
62
|
"pyright>=1.1.401",
|
|
63
63
|
"sphinx>=7.4.7",
|
|
64
64
|
"enum-tools[sphinx]>=0.12.0",
|
|
65
65
|
"autodoc-pydantic>=2.2.0",
|
|
66
66
|
"proxy-py>=2.4.9",
|
|
67
67
|
"sphinx-immaterial>=0.12.5",
|
|
68
|
-
"mypy>=1.
|
|
68
|
+
"mypy>=1.18.2",
|
|
69
69
|
]
|
|
70
70
|
|
|
71
71
|
[tool.setuptools.package-data]
|
|
@@ -77,8 +77,11 @@ where = ["tastytrade"]
|
|
|
77
77
|
[tool.ruff.lint]
|
|
78
78
|
select = ["E", "F", "I"]
|
|
79
79
|
|
|
80
|
+
[tool.coverage.run]
|
|
81
|
+
omit = ["tastytrade/oauth.py"]
|
|
82
|
+
|
|
80
83
|
[tool.pyright]
|
|
81
|
-
pythonVersion = "3.
|
|
84
|
+
pythonVersion = "3.10"
|
|
82
85
|
include = ["tastytrade", "tests"]
|
|
83
86
|
exclude = ["**/__pycache__"]
|
|
84
87
|
typeCheckingMode = "strict"
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import logging
|
|
2
2
|
|
|
3
3
|
API_URL = "https://api.tastyworks.com"
|
|
4
|
-
|
|
4
|
+
API_VERSION = "20251026"
|
|
5
5
|
CERT_URL = "https://api.cert.tastyworks.com"
|
|
6
6
|
VAST_URL = "https://vast.tastyworks.com"
|
|
7
|
-
VERSION = "
|
|
7
|
+
VERSION = "11.0.0"
|
|
8
8
|
|
|
9
9
|
__version__ = VERSION
|
|
10
10
|
version_str: str = f"tastyware/tastytrade:v{VERSION}"
|
|
@@ -18,9 +18,4 @@ from .account import Account
|
|
|
18
18
|
from .session import Session
|
|
19
19
|
from .streamer import AlertStreamer, DXLinkStreamer
|
|
20
20
|
|
|
21
|
-
__all__ = [
|
|
22
|
-
"Account",
|
|
23
|
-
"AlertStreamer",
|
|
24
|
-
"DXLinkStreamer",
|
|
25
|
-
"Session",
|
|
26
|
-
]
|
|
21
|
+
__all__ = ["Account", "AlertStreamer", "DXLinkStreamer", "Session"]
|