-
Notifications
You must be signed in to change notification settings - Fork 3.1k
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
Trading hours stock feature #1697
Conversation
Nice one. Couple comments. First is that the And in the stocks menu, I think we can put this up the top section (see image below). (thoughts @DidierRLopes ) When I load in an exchange, we should do some capitalization on the input, so that I could enter nyse or NYSE and it would understand
Also for the exchange function, is it possible to auto complete that field like we have throughout the terminal? And using -h flag throws a small error:
|
Thanks for making some changes! I am still running into an issue with
Additionally, exit needs one more quit, as it just takes us back to the root. (Also on your model and view, check line 1, one of them still says forex) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for contributing !
Looks good overall.
I wonder why this file was deleted ?
website/content/terminal/stocks/_index.md
@@ -1,5 +0,0 @@ | |||
--- |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is there a reason to remove this file ?
@@ -0,0 +1,1093 @@ | |||
from datetime import time |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would replace this python file by a yaml
(or .ini
or json
...) file and load it with a function.
Since it's a data file and not code.
Plus this will allow not having to ignore this file from the codespell
check.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think the only issue left is the linter complaining about some spagetti code here :
openbb_terminal/stocks/tradinghours/bursa_model.py::check_if_open
https://github.com/OpenBB-finance/OpenBBTerminal/runs/6080772850?check_suite_focus=true
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks ready for merging.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not yet. Before we merge can we have:
- AAPL shouldn't be loaded by default, should be empty.
- Autocomplete with 10k tickers doesn't work well, it's too slow and not worthy - we had this discussion internally already.3.
- The colouring scheme is wrong parameters and the value should be [param] and normal by default.4.
- the menu text is not properly aligned and there are 2 white lines instead of 1.5.
- When parsing an argument let's use
.upper()
so we can accept a ticker even with lowercase
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks Chavi!
Description
Summary of the change / bug fix.
Link # issue, if applicable.
Screenshot of the feature or the bug before/after fix, if applicable.
Relevant motivation and context.
List any dependencies that are required for this change.
How has this been tested?
/stocks/th/open
/stocks/th/closed
/stocks/th/all
/stockc/th/symbol MSFT
Checklist:
Others
pre-commit install
.pytest tests/...
.