Skip to content

Commit cf11861

Browse files
committed
Add coverage badge. Fix the docs configuration.
1 parent c8c4951 commit cf11861

File tree

10 files changed

+27
-79
lines changed

10 files changed

+27
-79
lines changed

README.rst

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,9 @@ pyrh - Unofficial Robinhood API
1111
:target: https://github.com/robinhood-unofficial/pyrh/actions?query=workflow%3Abuild+branch%3Amaster
1212
:alt: build
1313

14+
.. image:: https://codecov.io/gh/robinhood-unofficial/pyrh/branch/master/graph/badge.svg
15+
:target: https://codecov.io/gh/robinhood-unofficial/pyrh
16+
1417
.. image:: https://img.shields.io/pypi/v/pyrh?style=plastic
1518
:target: https://pypi.org/project/pyrh/
1619
:alt: pypi version

docs/api.rst

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,5 +8,6 @@ API Reference
88
:toctree: stubs
99

1010
Robinhood
11-
SessionManager
11+
load_session
12+
dump_session
1213
exceptions

docs/conf.py

Lines changed: 1 addition & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -5,17 +5,6 @@
55
# https://www.sphinx-doc.org/en/master/usage/configuration.html
66

77

8-
def _get_version() -> str:
9-
from pathlib import Path
10-
from tomlkit import parse
11-
12-
pyproject_path = Path(__file__).resolve().parent.joinpath("../pyproject.toml")
13-
with open(pyproject_path) as file:
14-
pyproject = parse(file.read())
15-
16-
return str(pyproject["tool"]["poetry"]["version"])
17-
18-
198
# -- Project information -----------------------------------------------------
209

2110
project = "pyrh"
@@ -25,7 +14,7 @@ def _get_version() -> str:
2514
exclude_patterns = ["stubs/*"] # ignore stubs from checks
2615

2716
# The full version, including alpha/beta/rc tags
28-
release = _get_version()
17+
release = "2.0"
2918

3019
# -- General configuration ---------------------------------------------------
3120

docs/stubs/pyrh.Robinhood.rst

Lines changed: 2 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -14,20 +14,13 @@ pyrh.Robinhood
1414
.. autosummary::
1515

1616
~Robinhood.__init__
17-
~Robinhood.adjusted_equity_previous_close
1817
~Robinhood.adjusted_previous_close
1918
~Robinhood.ask_price
2019
~Robinhood.ask_size
2120
~Robinhood.bid_price
2221
~Robinhood.bid_size
2322
~Robinhood.cancel_order
2423
~Robinhood.dividends
25-
~Robinhood.equity
26-
~Robinhood.equity_previous_close
27-
~Robinhood.excess_margin
28-
~Robinhood.extended_hours_equity
29-
~Robinhood.extended_hours_market_value
30-
~Robinhood.from_json
3124
~Robinhood.fundamentals
3225
~Robinhood.get
3326
~Robinhood.get_account
@@ -36,7 +29,6 @@ pyrh.Robinhood
3629
~Robinhood.get_news
3730
~Robinhood.get_open_orders
3831
~Robinhood.get_option_chainid
39-
~Robinhood.get_option_market_data
4032
~Robinhood.get_option_marketdata
4133
~Robinhood.get_option_quote
4234
~Robinhood.get_options
@@ -49,14 +41,11 @@ pyrh.Robinhood
4941
~Robinhood.instrument
5042
~Robinhood.instruments
5143
~Robinhood.investment_profile
52-
~Robinhood.last_core_equity
53-
~Robinhood.last_core_market_value
5444
~Robinhood.last_trade_price
5545
~Robinhood.last_updated_at
5646
~Robinhood.last_updated_at_datetime
5747
~Robinhood.login
5848
~Robinhood.logout
59-
~Robinhood.market_value
6049
~Robinhood.options_owned
6150
~Robinhood.order_history
6251
~Robinhood.place_buy_order
@@ -70,7 +59,7 @@ pyrh.Robinhood
7059
~Robinhood.place_stop_limit_sell_order
7160
~Robinhood.place_stop_loss_buy_order
7261
~Robinhood.place_stop_loss_sell_order
73-
~Robinhood.portfolios
62+
~Robinhood.portfolio
7463
~Robinhood.positions
7564
~Robinhood.post
7665
~Robinhood.previous_close
@@ -83,7 +72,6 @@ pyrh.Robinhood
8372
~Robinhood.submit_buy_order
8473
~Robinhood.submit_sell_order
8574
~Robinhood.symbol
86-
~Robinhood.to_json
8775
~Robinhood.user
8876

8977

@@ -96,3 +84,4 @@ pyrh.Robinhood
9684

9785
~Robinhood.authenticated
9886
~Robinhood.login_set
87+
~Robinhood.token_expired

docs/stubs/pyrh.SessionManager.rst

Lines changed: 0 additions & 33 deletions
This file was deleted.

docs/stubs/pyrh.dump_session.rst

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
pyrh.dump\_session
2+
==================
3+
4+
.. currentmodule:: pyrh
5+
6+
.. autofunction:: dump_session

docs/stubs/pyrh.exceptions.rst

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,9 @@ pyrh.exceptions
1818
.. autosummary::
1919

2020
AuthenticationError
21-
InvalidInstrumentId
21+
InvalidCacheFile
22+
InvalidOperation
2223
InvalidOptionId
2324
InvalidTickerSymbol
24-
LoginFailed
25-
RobinhoodException
25+
PyrhException
26+
PyrhValueError

docs/stubs/pyrh.load_session.rst

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
pyrh.load\_session
2+
==================
3+
4+
.. currentmodule:: pyrh
5+
6+
.. autofunction:: load_session

poetry.lock

Lines changed: 2 additions & 14 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pyproject.toml

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,6 @@ autodocsumm = { version = "^0.1.13", optional = true }
3131
sphinx = { version = "^2.4.4", optional = true }
3232
sphinx-autodoc-typehints = { version = "^1.10.3", optional = true }
3333
sphinx_rtd_theme = { version = "^0.4.3", optional = true }
34-
tomlkit = {version = "^0.5.11", optional = true }
3534

3635
# Main Dependencies
3736
marshmallow = "^3.5.1"
@@ -68,9 +67,8 @@ requests-mock = "^1.7.0"
6867
# Automation
6968
towncrier = "^19.2.0"
7069

71-
7270
[tool.poetry.extras]
73-
docs = ["sphinx", "sphinx-autodoc-typehints", "sphinx_rtd_theme", "autodocsumm", "tomlkit"]
71+
docs = ["sphinx", "sphinx-autodoc-typehints", "sphinx_rtd_theme", "autodocsumm"]
7472
notebook = ["notebook", "python-dotenv"]
7573

7674
[tool.black]

0 commit comments

Comments
 (0)