Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

calculate prices from csv #96

Merged
merged 47 commits into from
Feb 5, 2022
Merged
Changes from 1 commit
Commits
Show all changes
47 commits
Select commit Hold shift + click to select a range
43e1fe5
calculate prices from csv
scientes Dec 13, 2021
74077df
Merge branch 'main' into prices-from-csv
scientes Dec 13, 2021
f2729c7
fixed linting except line to long
scientes Dec 13, 2021
13fa82e
fixed for multiple coins
scientes Dec 19, 2021
9afb70a
added sql migration and extra function
scientes Dec 25, 2021
8e21d8a
bugfix (prices were inverted db) and migration fix
scientes Dec 25, 2021
9c52dd8
fixed missing inversion
scientes Dec 31, 2021
f74327d
formatting
scientes Dec 31, 2021
5112a14
Prices from csv (#3)
Griffsano Dec 31, 2021
45b6a39
FIX type annotation of group_by
provinzio Jan 2, 2022
7c0f924
REFACTOR add newline
provinzio Jan 2, 2022
dc852ee
REFACTOR get_price_from_csv
provinzio Jan 2, 2022
62b861c
ADD docstring to _sort_pair
provinzio Jan 2, 2022
5124ebe
RENAME reciprocal bool to inverted
provinzio Jan 2, 2022
3d10f3d
ADD comment in get_price when price is missing
provinzio Jan 2, 2022
30fe876
TODO ADD rudimentary patch functions
provinzio Jan 2, 2022
9ea7822
boilerplate
scientes Jan 7, 2022
e711b47
removed classes and replaced get_price occurrences
scientes Jan 9, 2022
0dd0132
refractored db functions
scientes Jan 9, 2022
33876f2
fixed patch function
scientes Jan 9, 2022
ab15eaa
fixed imports and flake added patch 001
scientes Jan 10, 2022
7265ee7
fix iosort
scientes Jan 10, 2022
7bb7bd8
Prices from csv (#5)
Griffsano Jan 28, 2022
179bb05
Refactor logging patching info
provinzio Feb 5, 2022
acc215b
CHANGE get_tablenames does not query §version table per default
provinzio Feb 5, 2022
1419746
UPDATE transfer platform parameter
provinzio Feb 5, 2022
d70559f
REFACTOR function docstrings
provinzio Feb 5, 2022
09a81e5
FIX mypy linting error
provinzio Feb 5, 2022
a06f735
Reorder preamble of set_price_db
provinzio Feb 5, 2022
e99a7aa
UPDATE assert db exists before setting new price
provinzio Feb 5, 2022
cd33058
ADD helper functions to get patch func names/versions
provinzio Feb 5, 2022
b54c366
REFACTOR patch databases
provinzio Feb 5, 2022
63b3959
ADD create database in book.py when missing
provinzio Feb 5, 2022
c400a4c
AUTOFORMAT database.py
provinzio Feb 5, 2022
78046f4
Avoid circular import
provinzio Feb 5, 2022
7b81aa9
CHANGE update_version create §version table when missing
provinzio Feb 5, 2022
700ea26
Merge remote-tracking branch 'origin/main' into prices-from-csv
provinzio Feb 5, 2022
0f2e7fb
UPDATE format of warning message
provinzio Feb 5, 2022
a6fc0eb
UPDATE reword debug message
provinzio Feb 5, 2022
7cae5c3
ADD debug message when updating db version
provinzio Feb 5, 2022
f932e0c
CHANGE Create db not in book, but on set_price when db is missing
provinzio Feb 5, 2022
0b93b3b
UPDATE duplicate price warning, add db price for comparison
provinzio Feb 5, 2022
81b4e30
AUTOFORMAT price_data
provinzio Feb 5, 2022
53753d6
ADD comment to price_data when querying new price
provinzio Feb 5, 2022
16dabab
FIX database type for price
provinzio Feb 5, 2022
c1538cf
ADD set_price_db parameter to overwrite already existing prices
provinzio Feb 5, 2022
9f906b1
FIX linting errors
provinzio Feb 5, 2022
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
ADD comment to price_data when querying new price
  • Loading branch information
provinzio committed Feb 5, 2022

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
commit 53753d6a68efa729ccca389d7f5da33b42787498
1 change: 1 addition & 0 deletions src/price_data.py
Original file line number Diff line number Diff line change
@@ -496,6 +496,7 @@ def get_price(

# Check if price exists already in our database.
if (price := get_price_db(db_path, tablename, utc_time)) is None:
# Price doesn't exists. Fetch price from platform.
try:
get_price = getattr(self, f"_get_price_{platform}")
except AttributeError: