Commit Graph

597 Commits

Author SHA1 Message Date
montezdesousa
4d3f5aecfb Bump yfinance to 0.2.4 and fix tests (#3977)
* upgrade yfinance to 0.2.4

* fix some tests failing bc yfinance new date format

* fix remaining tests

* fix tests

* rewrite failing test

* black

* rerecord test

* fix get_1y_sp500 test

* missing import here

Co-authored-by: Henrique Joaquim <h.joaquim@campus.fct.unl.pt>
Co-authored-by: James Maslek <jmaslek11@gmail.com>
2023-01-16 19:24:58 +00:00
montezdesousa
86fd7ae426 Add multiple countries option to events (#3938)
* allow multiple countries in events cmd

* fix test

* fix last test

* black

Co-authored-by: James Maslek <jmaslek11@gmail.com>
2023-01-13 19:10:20 -05:00
montezdesousa
e9b832f779 Fix portfolio returns (#3931)
* fix inception bug and clean some useless attributes

* reorder attributes

* add returns and cumulative returns

* fix cumulative returns

* fix cumulative returns

* remove cumulative ret

* add some doc and encapsule methods

* order detail

* add more details on docstrings

* wrong docstring

* add commnet

* Update portfolio_engine.py

* fix bug with unsupported type

* Fix plot look when using eval and add query to choices (#3881)

* convert index to datetime and update choices

* uncomment economy integration test

* fix treasury concat bug

* fix datasets concat on duplciates

* Lock ruff version so that new lints dont break our CI (#3905)

* Lock ruff version so that new lints dont break our CI

* Bumped pre-commit ruff version

* fix table header

* fix portfolio integration test

* ruff

* fix tests

* rewrite yfinance call

* fix test_draw

* test_stocks_helper

* bt model

* fix comp analysis

* fix ftd

* fix dd

* fix screener

Co-authored-by: James Maslek <jmaslek11@gmail.com>
Co-authored-by: Colin Delahunty <72827203+colin99d@users.noreply.github.com>
Co-authored-by: hjoaquim <h.joaquim@campus.fct.unl.pt>
2023-01-13 17:25:53 -05:00
montezdesousa
9438329378 Rewrite and skip yfinance tests (#3953)
* economy

* fix futures

* fix stocks tests

* skip unfixable tests

* fix ark
2023-01-13 19:41:45 +00:00
Mert Nuhuz
4303bdc682 Issue #3882 Fixed (#3885)
* Fix plot look when using eval and add query to choices (#3881)

* convert index to datetime and update choices

* uncomment economy integration test

* fix treasury concat bug

* fix datasets concat on duplciates

* Issue #3882 Fixed

* 2 files reformatted by black

* tests added

* Lock ruff version so that new lints dont break our CI (#3905)

* Lock ruff version so that new lints dont break our CI

* Bumped pre-commit ruff version

* fixed mypy errors

Co-authored-by: montezdesousa <79287829+montezdesousa@users.noreply.github.com>
Co-authored-by: Colin Delahunty <72827203+colin99d@users.noreply.github.com>
Co-authored-by: James Maslek <jmaslek11@gmail.com>
2023-01-12 10:14:58 -05:00
Luqman
547b0742c2 Gitflow - Autodoc (#3922) 2023-01-11 16:49:20 +01:00
montezdesousa
c6b2ec5857 Integration tests refactor (#3781)
* generate integration tests report

* new console report

* simple run_scripts

* move tests script to folder

* add skipping

* always display skips

* func name

* allow running from relative path

* rename some vars and time

* typo

* change portfolio supress and warning

* uncomment economy test

* rename test controller

* multiprocessing

* display test progress and available

* rename func

* mypy

* should not be here

* small changes

* type hinting and docstrings

* new subprocesses default

* forget context and chunksize

* clean len skipt

* small comment

* fix subproc default with v

* minor change

* fix path

* better this way

* make output visible

* allow only sequential run with verbose mode

* change message

* detail

* include andrew idea

* limit multiprocessing to clone version

* fix for package application

* must be up here

* allow verbose with multiprocessing but warn

* update readme

* move tests to core

* Update README.md

* Update README.md

* move readme outside

* Update README.md

* Update README.md

* Update README.md

* Update README.md

* Update README.md

* Update README.md

* Update README.md

* Update README.md

* Update README.md

* parse subproc arg

* Update README.md

* Fix plot look when using eval and add query to choices (#3881)

* convert index to datetime and update choices

* uncomment economy integration test

* fix treasury concat bug

* fix datasets concat on duplciates

* Lock ruff version so that new lints dont break our CI (#3905)

* Lock ruff version so that new lints dont break our CI

* Bumped pre-commit ruff version

* Delete glossary base command

* move scripts

* ruff

* update pyproject.toml

* update yfinance

* fix futures and economy test, rewrite

* rewrite stocks test yfinance dependent

* refactor sia to yfinance 0.2...

* fix last failing sia tests

* black

* update reqs

Co-authored-by: James Maslek <jmaslek11@gmail.com>
Co-authored-by: Colin Delahunty <72827203+colin99d@users.noreply.github.com>
Co-authored-by: Chavithra PARANA <chavithra@gmail.com>
2023-01-11 14:23:43 +00:00
Luqman
2a0c0c0cf0 Feature/gitflow (#3900) 2023-01-09 11:43:49 +01:00
Luqman
54188fd725 Testing Gitflow (#3899)
* testing gitflow

* Name changes

* Testing python changes

* Added Checkout to Base test
2023-01-09 10:17:40 +01:00
James Maslek
93f440a31c Adds historical end date on the ca menu (#3867)
* #3835 add end date for historical

* Add to terminal function

* Add to other ca functions and update tests

* missed the controller test

* Add helper function for start and end date

* test for helper function

* default end = today

Co-authored-by: montezdesousa <79287829+montezdesousa@users.noreply.github.com>
2023-01-05 11:24:39 -05:00
Nate
052c16f87e Added single block data from Blockchain.com (#3406)
* Added single block data

* Added single block data tests to test_blockchain_model.py and test_blockchain_view.py

* Made changes requested by reviewer.

* Updating with some of the new changes.  Still have some to fix.

* Changed everything requested except a couple I need help on.

* Finished the last two changes.

* Resolving

* Added function for sdk and fixed a linter issue.

* Formatting

* Fixed tests

* tests

* Fix tests

Co-authored-by: jose-donato <43375532+jose-donato@users.noreply.github.com>
Co-authored-by: James Maslek <jmaslek11@gmail.com>
2023-01-04 10:20:44 -05:00
jose-donato
d9267da380 Adds command to check top hackernews stories (#3841)
* fix(docs): added margin between sections

* feat: added hn command

* fix: added log decorator

Co-authored-by: James Maslek <jmaslek11@gmail.com>
2023-01-03 16:56:24 -05:00
Henrique Joaquim
306d0ec9bd Fix issue on loading stock (#3860)
* fix the issue for inexistant ytd dataframe

* fixing tests
2023-01-03 09:15:12 -05:00
Florian Drinkler
2873bbbadd Update blcp display name (#3808)
* Update blcp display name

* fix test_print_help

Co-authored-by: James Maslek <jmaslek11@gmail.com>
Co-authored-by: Henrique Joaquim <h.joaquim@campus.fct.unl.pt>
2022-12-22 20:46:35 +00:00
James Maslek
0e8a8013aa Fix polygon cash statement + fmp stuff (#3809)
* Fix polygon cash statement

* FMP bugfix and regenerate some tests

* fix vomma

* Fix unreported futures bug with capitalization
2022-12-21 12:04:45 +00:00
James Maslek
a3419d0844 deps update (#3800) (#3801)
* deps update (#3800)

* statsmodels

* delete very old files

* Lots o tests

* etf tests

* OPtions tests

* Pin psutil for m1 build

* stocks rewrite expected

* pyproject comments + portfolio test

* disc/ark view test

* dcf coe

* dcf view

* stocks screener

* dcf model

* etf controller

* insider views

* dps view

* ca menu

* stocks/qa

* skip bt tests

* get rid of pymongo from .spec

* One last skip

* Allow finviz to be 1.4.4

* oops forgot to get rid of my debugging

* remove bson from spec because no more pymongo

* make requirments txt and requirements be finviz 1 4 4

* try hidden import

* Gray sweatpants

* Add files to spec

* Revert "Allow finviz to be 1.4.4"

This reverts commit 9581993b4f.

* Revert "Pin psutil for m1 build"

This reverts commit 07fa2d1be0.

* Revert "statsmodels"

This reverts commit 2e431b5d34.

* Revert "deps update (#3800)"

This reverts commit d9fb8a288c.

* Re-solve dependencies

Co-authored-by: Henrique Joaquim <h.joaquim@campus.fct.unl.pt>
Co-authored-by: Theodore Aptekarev <aptekarev@gmail.com>
2022-12-20 23:45:29 +01:00
jose-donato
917b2bb44c Fix test wordrwap (#3788)
* fix: wordwrap

* fix: test
2022-12-15 15:50:04 -05:00
DidierRLopes
8b1ac6c858 Add parameter to automatically color a table based on positive and negative numbers (#3603)
* automatically color table based on values - parameter added to print_help_text

* fix act cmd

* disable warning

* improve code for coloring + allow row/col select coloring

* update timestamp date

* cleanup

* start implementing tests

* ignore branches

* pylint disable

* pylint

* remove tests

* remove unused imports

* remove .txt files

* type ignore

Co-authored-by: James Maslek <jmaslek11@gmail.com>
Co-authored-by: Henrique Joaquim <h.joaquim@campus.fct.unl.pt>
2022-12-12 19:23:06 -05:00
kajdo
fedeeaad18 FEAT: EPS and Revenue Estimations from Seeking Alpha (#3402)
* FEAT: EPS and Revenue Estimations from Seeking Alpha

* initial pytest for seekingalpha model and view

* added fa_controller tests for seekingalpha views

* integration tests for epsfc and revfc

* FIX: handling of "no data found"

* merge

* number format fix

* format change according to black linter

* fixed unit tests because prev. recordings didn't match anymore

* change to match linter rules

* fixes

* delete website files"

* update codespell

* Flake

Co-authored-by: kajdo <juergen.kajdocsy@gmail.com>
Co-authored-by: James Maslek <jmaslek11@gmail.com>
Co-authored-by: Colin Delahunty <72827203+colin99d@users.noreply.github.com>
2022-12-12 17:55:20 -05:00
Henrique Joaquim
0e79f3fbc8 Changing packaging version (#3764)
* changing packaging version

* removing LegacyVersion

* removing unused import

* Update test cache

* Revert cache

* pin packaging

* update version

* Fix tests

Co-authored-by: james <jmaslek11@gmail.com>
Co-authored-by: Chavithra PARANA <chavithra@gmail.com>
2022-12-12 16:32:13 -05:00
James Maslek
b4b4c1f0d8 Temporary fix for finviz analyst function (#3732)
* Temporary fix for finviz analyst function

* test

* ignore the version mypy stuff

* space

* wrong lines lol
2022-12-08 12:17:16 -05:00
nicktids
1251bda052 Remove case sensitive path files (#3684)
* Delete test_get_fundraising[ETH].txt

warning: the following paths have collided (e.g. case-sensitive paths
on a case-insensitive filesystem) and only one from the same
colliding group is in the working tree:

  'tests/openbb_terminal/cryptocurrency/due_diligence/txt/test_messari_model/test_get_fundraising[ETH].txt'
  'tests/openbb_terminal/cryptocurrency/due_diligence/txt/test_messari_model/test_get_fundraising[eth].txt'

* Delete test_get_governance[ETH].txt

warning: the following paths have collided (e.g. case-sensitive paths
on a case-insensitive filesystem) and only one from the same
colliding group is in the working tree:

  'tests/openbb_terminal/cryptocurrency/due_diligence/txt/test_messari_model/test_get_governance[ETH].txt'
  'tests/openbb_terminal/cryptocurrency/due_diligence/txt/test_messari_model/test_get_governance[eth].txt'

Co-authored-by: James Maslek <jmaslek11@gmail.com>
Co-authored-by: DidierRLopes <dro.lopes@campus.fct.unl.pt>
2022-12-05 16:20:50 -05:00
James Maslek
f47d15088f Bug fixing (#3680)
* ycrv bug

* fred search multiple, test fix

* ba/interest to allow multiple words

* Fixes #3642

* Date logic

* debug
2022-12-02 14:34:40 -05:00
James Maslek
e044c82e7c Fix #3628 (#3653) 2022-11-29 14:30:11 -05:00
Colin Delahunty
58fb984b70 Forecast test (#3636)
* Fixed some tests

* Fixed some tests

* Finished fixing tests

* Fixed pylint

Co-authored-by: James Maslek <jmaslek11@gmail.com>
Co-authored-by: martinb-bb <105685594+martinb-bb@users.noreply.github.com>
2022-11-29 10:11:04 -05:00
Chavithra
d712fce7cb ETF : update choices (#3610)
* Moving Docker folder into Build

* Workflows : update Docker

* Docker : update compose image version

* Docker : fix volumes path

* etf/disc : update choices

* etf/scr : update choices

* etf/scr : update choices

* ETF : update choices

Co-authored-by: James Maslek <jmaslek11@gmail.com>
2022-11-28 13:20:57 -05:00
Pedro Chaves
d2622528e5 Fixed dates on yield curve functions, test functions and doc strings (#3617)
* Fixed dates on yield curve functions, and doc strings

* black

* black

* unused import

* keeping the valid_date verification

Co-authored-by: hjoaquim <h.joaquim@campus.fct.unl.pt>
2022-11-28 12:15:49 -05:00
Henrique Joaquim
cca3b31856 Fix dashboards (#3577)
* updating dependencies

* poetry export

* removed breakline from input

* Export dependencies

* Workflow

* Tests

* Workflow

* Dependencies update

* Linting

* Tests readme

* Dependencies update

* Workflow update

* Linting

* Workflow update

* Fix import

* Tests

* Linting

* Workflow update

* Re-solve the dependencies with poetry 1.1.13

* Workflow update

Co-authored-by: James Maslek <jmaslek11@gmail.com>
Co-authored-by: Chavithra PARANA <chavithra@gmail.com>
Co-authored-by: Theodore Aptekarev <aptekarev@gmail.com>
2022-11-28 12:13:22 -05:00
James Simmons
caf2f853c3 stocks/scr/set fixes and error catching changes. (#3614)
* fixes to set

* test fixes

* fixing finviz_view

* removing \n to match styleguide

* removing \n to match styleguide

Co-authored-by: hjoaquim <h.joaquim@campus.fct.unl.pt>
2022-11-28 09:26:43 -05:00
James Simmons
f0d965d3d1 Double exit bug fix on ca menu (#3607) 2022-11-27 20:32:47 -05:00
James Maslek
d633b42a41 Etf bug fix (#3589)
* Etf fix

* docstring

* tests
2022-11-26 20:16:22 +00:00
DidierRLopes
0c89ee639b One text was missing from en.yml (#3568)
* smallest fix in the world

* fixes test

Co-authored-by: Colin Delahunty <72827203+colin99d@users.noreply.github.com>
2022-11-26 11:41:10 +00:00
Colin Delahunty
9f7635faee New Integration Tests (#3377) 2022-11-25 22:18:52 -05:00
montezdesousa
7480c5efe0 Fix portfolio optimization SDK bugs (#3582)
* Small improvement to text handling

* fix plot and engine

* change msg

* fix po engine

* fix rc

* fix error

* opt pytest

* bug fix

Co-authored-by: colin99d <colin99delahunty@gmail.com>
Co-authored-by: minhhoang1023 <40023817+minhhoang1023@users.noreply.github.com>
Co-authored-by: James Maslek <jmaslek11@gmail.com>
2022-11-25 18:10:48 -05:00
teh_coderer
79046608b6 Docs Fix (#3543)
* Update generate_terminal_markdown.py

* updates

* update workflows

* Automated Change

* tests

* tests

* Automated Change

* Update test_generate_docs.py

* Automated Change

* updates

* Automated Change

* Update gen-docs.yml

* Update test.yml

* Automated Change

* Update test.yml

* Automated Change

* Update generate_sdk_markdown.py

* Automated Change

* test

* Automated Change

* testtt23

* Automated Change

* Update generate_sdk_markdown.py

* Automated Change

* Automated Change

* added empting reference folders before autogen docs

* updates

* Automated Change

* update tests gitactions

* Automated Change

* up

* Automated Change

* Automated Change

* update pytest

* Automated Change

* tests

* Automated Change

* examples update

* Automated Change

* Update generate_sdk_markdown.py

* Automated Change

* Update test.yml

* Update generate_sdk_markdown.py

* strip

* Automated Change

* Workflow : check test update

* Automated Change

* Automated Change

* Automated Change

* Update test.yml

* Automated Change

* Update test.yml

* Automated Change

* Automated Change

* up

* Automated Change

* Update generate_sdk_markdown.py

* Automated Change

* update workflows

* fix guides

* testing

* Update gh-pages.yml

* Update gh-pages.yml

Co-authored-by: tehcoderer <tehcoderer@users.noreply.github.com>
Co-authored-by: Jeroen Bouma <jer.bouma@gmail.com>
Co-authored-by: Chavithra PARANA <chavithra@gmail.com>
Co-authored-by: Chavithra <Chavithra@users.noreply.github.com>
Co-authored-by: jose-donato <43375532+jose-donato@users.noreply.github.com>
Co-authored-by: jose-donato <jose-donato@users.noreply.github.com>
2022-11-25 17:19:08 -05:00
Henrique Joaquim
7a9cf08acc Fix crypto candle (#3558)
* improve crypto.candle

* added raw and examples

* linting

* disable too many args

* format volume if in use

* consistency on dd.candle

* fixed tests as default arg changed

* fixed tests

* Revert "fixed tests"

This reverts commit fb7df62000.

* Revert "Revert "fixed tests""

This reverts commit 8b568d24e5.

* Revert "Revert "Revert "fixed tests"""

This reverts commit 04353b0d11.

* Revert "Revert "Revert "Revert "fixed tests""""

This reverts commit a181e0acdc.

* fixed tests

* wrong branch

* removing changes

* getting rid of mutable defaults, also changed vs_currency to to_symbol - tks @montezdesousa

Co-authored-by: montezdesousa <79287829+montezdesousa@users.noreply.github.com>
2022-11-25 14:52:45 -05:00
Colin Delahunty
af0eb7b2b9 Forecast and Economy PR (#3500)
* Added fix

* Progressed on forecast, did economy

* Fix python 3.10 code

* Fix economy

* Update choices generation

* Fix economy

* Fix choices generation

* Economy fixes

* Added improvements

* Continued work on improving forecast

* Added fixes

* Continuing

* Got some fixes in

* Added fixes

* Added fixes

* Added fixes

* Added fixes

Co-authored-by: Chavithra PARANA <chavithra@gmail.com>
2022-11-25 06:44:18 +01:00
montezdesousa
b2f0e07349 Fix [Bug] SDK - openbb.crpyto.ov.stables - Error: 'rank' (works in Terminal though) (#3557)
* fix stables

* add examples

* small fix

Co-authored-by: Henrique Joaquim <h.joaquim@campus.fct.unl.pt>
2022-11-24 18:44:59 +00:00
Henrique Joaquim
39f63850ab Improve version check (#3544) 2022-11-23 16:51:17 -05:00
montezdesousa
246fdacc90 Add divs chart to sdk (#3529)
* add divs chart to sdk

* add examples

* fix tests

* fix tests

* fix test

Co-authored-by: James Maslek <jmaslek11@gmail.com>
2022-11-23 14:53:46 -05:00
montezdesousa
99e9489a80 Get data by default on pt_chart (#3528)
* add default data to pt_chart

* add examples

* fix test

Co-authored-by: James Maslek <jmaslek11@gmail.com>
2022-11-23 14:16:02 +00:00
jose-donato
e1962252ad Docs fixes (#3530)
* fix(docs): added margin between sections

* fix: images

* readd old content for examples/images

* fix: codespell

* fix: codespell

* fix: ga

* fix: remove temp lorem ipsum

* fix: docu config for edit page

Co-authored-by: teh_coderer <me@tehcoderer.com>
2022-11-22 14:56:17 -05:00
Colin Delahunty
5c14e280a0 Bug fixes (#3423)
* Got basic testing file done

* Continued progress on new integrated tests

* Allow for dynamic parameters, update docs

* Massive improvements

* Improved CSV file

* Renamed file per James2

* Added fixes

* Added fixes

* Combined the docs

* Renamed file

* Fixed typing issue and simplified code

* Captures output for tests

* Fixes 3418

* Fixed financial statement exports

* Fixed sean seah

* Handle no ticker

* Added fixes

* Removed unwanted changes

* Removed unwanted changes

* Removed unwanted changes

* Fixed tests

* Fixed tests
2022-11-22 08:17:47 -05:00
Colin Delahunty
87458c965d Stocks Suggestor Repair (#3477)
* broken edition

* Fixed issue

* Update StockController

* Update choices generation

* Update parent_classes

* Update choices generation

* Update choices generation

* Update crypto_controller

* Update DefiController

* Update crypto/disc controller

* Update crypto/dd

* Update choices generation

* Update crypto : dd + nft

* Update crypto/onchain

* Update crypto_controller

* Linting

* Update crypto/ov

* Linting

* Update crypto/ov

* Update crypto/qa

* Update crypto/tools

* Update crypto/ta + dd

* Linting

* Update alt

* Tests fix crypto

* Update future

* Update futures

* Refactored through Options

* Tests + Linting

* finished stocks refactor

* Update stocks/sia

* finished stocks refactor

* Added fixes

* Added fix

* Tests

* Fix conditions

* Fix portfolio

* Prepare for merge

Co-authored-by: Chavithra PARANA <chavithra@gmail.com>
Co-authored-by: northern-64bit <75195383+northern-64bit@users.noreply.github.com>
2022-11-21 17:54:26 +01:00
montezdesousa
18d1ce0df5 Add missing qa functions capm, beta, cusum, acf, qqplot, hist, line (#3499) 2022-11-21 10:49:18 -05:00
Henrique Joaquim
976d5dfccc Fix crypto 3327 (#3434)
* removed get_coinpaprika_id from the view

* reorganized a bit

* removed unused functions

* removed unused functions

* removed unused imports

* cleaning

* cleaning

* fix tests

* fix template report

* fix template report

* fixing imports

* fixing imports

* fix report

* fix report

* fix report

* fix tests

* small fixes after merge

* linting

* split find into view and model

* added tests for view

* add tests to model

* black

* unused import

* disbale import oustise top level

* removed view from sdk

* added example
2022-11-21 14:48:40 +00:00
James Maslek
4fc2edf0fb single sdk unit test (#3489) 2022-11-19 14:23:56 -05:00
montezdesousa
1d3e468cb9 Portfolio optimization - plot, show and load endpoints (#3443)
* minor changes

* add spaces to print help

* start _show refactoring

* partial refactor po

* fix ef view

* refactor plot

* remove some unused stuff

* refactor charts

* forgot this

* validate input type

* change func name

* rename some endpoints

* move statics

* turn some args to kwargs

* rewrite equal docstring

* equal docstring again

* add docstrings and move some statics

* fix maxsharpe terminal bug

* refactor show

* fix ef

* add integration tests

* fix category bug

* fill some examples

* add more examples and fix nco

* add more examples

* add one more example

* add examples file

* add examples to load

* add detail to example

* add integration tests

* fix doc

* fix teste

* black

* flake

* pylint

* Linting

* Fix return

* Trying to fix display_plot

* display_rc_chart -> display_rc

Co-authored-by: Chavithra PARANA <chavithra@gmail.com>
2022-11-18 20:56:16 +00:00
montezdesousa
570e579067 Portfolio docstring example fixes and some bugs (#3431)
* fix doctest

* fix some type hints

* reorganize portfolio folders

* fix rfr

* fix vol bug

* fix more docs

* fix failing test

* doc typo

* numpy fix

* pydocstyle

* regenerate website docs
2022-11-18 19:30:55 +00:00
Colin Delahunty
cca41d4f08 Fixing various bugs (#3474)
* Fixed warning message

* Refactored screener menu

* Pylint fix

* Fixed bugs

* With bug

* Choices : update error message

* Fixed issues

* Fixed more bugs

* Fixed more bugs

Co-authored-by: Chavithra PARANA <chavithra@gmail.com>
2022-11-18 09:08:29 -05:00