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

#2684 [CT] Improve stocks/sia error handling, abstract duplicate code #2723

Merged
merged 5 commits into from Oct 7, 2022

Conversation

catalintoma
Copy link
Contributor

@catalintoma catalintoma commented Oct 6, 2022

Description

How has this been tested?

  • Extended unit tests

Checklist:

Others

  • I have performed a self-review of my own code.
  • I have commented my code, particularly in hard-to-understand areas.

@colin99d
Copy link
Contributor

colin99d commented Oct 6, 2022

Nice work!! Also thanks for adding tests as well!

@colin99d colin99d self-requested a review October 6, 2022 10:25
@colin99d
Copy link
Contributor

colin99d commented Oct 6, 2022

Once tests and linters are good I can merge. Let me know if you need any help.

@catalintoma
Copy link
Contributor Author

catalintoma commented Oct 6, 2022

@colin99d

I noticed this step failed quit fast
Tests / Base Tests - Ubuntu-latest - Python 3.9 (pull_request)

Also wanted to ask if there is any way the linter (other tooling?) detect duplicate code? I think on this controller there were around 40 lines of code duplicated!

If it's not something extremely hard, I would raise an improvement issue for this, I noticed this "code smell" in many places

@colin99d
Copy link
Contributor

colin99d commented Oct 6, 2022

Hmm weird. It looks like Github actions is failing. I will try to run again later.

@colin99d
Copy link
Contributor

colin99d commented Oct 6, 2022

Also, I believe pylint can be configured to check for code duplication. But when I last used it, we got way too many false positives.

@catalintoma
Copy link
Contributor Author

@colin99d can you kick the CI again? Seems like one still failed

@colin99d
Copy link
Contributor

colin99d commented Oct 7, 2022

actions/checkout#944

Something in our CI is broken, but its not our fault. I am downgrading the version we use and then tests should run.

@colin99d colin99d merged commit 002bcb9 into OpenBB-finance:main Oct 7, 2022
@catalintoma catalintoma deleted the bug/2684 branch October 7, 2022 15:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Fix bug
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Bug] /Stocks/SIA - load function doesn't work. Error: 'NoneType' object is not subscriptable
2 participants