emiliobrazil / portfolio_analysis

The "PythonPortfolioAnalyzer" is a Git repository that forms a vital part of the final project for the "Programming 2" course. This project aims to develop a Python application that empowers users to calculate the risk and return of a stock portfolio, making it an essential tool for investors and financial analysts.
Apache License 2.0
0 stars 1 forks source link

GUI don't work #30

Closed henriqueassis2003 closed 10 months ago

henriqueassis2003 commented 10 months ago

GUI dont't work

when GUI executed in:

github-codespaces Linux-Pycharm Linux-VS code Windows-Pycharm WIndows-Vscode

occur the same error

Traceback (most recent call last): File "/workspaces/portfolio_analysis/bin/tkinterguiversion.py", line 132, in <module> usr_portfolio = Portfolio(brazilian_stocks, "Meu portifolio") File "/workspaces/portfolio_analysis/bin/CL_portfolio_management/CL_portfolio_management.py", line 48, in __init__ self.add_stock(s[0],s[1]) File "/workspaces/portfolio_analysis/bin/CL_portfolio_management/CL_portfolio_management.py", line 92, in add_stock self.__setitem__(symb, quatity) File "/workspaces/portfolio_analysis/bin/CL_portfolio_management/CL_portfolio_management.py", line 68, in __setitem__ elif self.is_valid_symblo(symb): File "/workspaces/portfolio_analysis/bin/CL_portfolio_management/CL_portfolio_management.py", line 185, in is_valid_symblo return type(sym) is str and CLfnc.is_valid(sym) AttributeError: module 'CL_finance' has no attribute 'is_valid'

please fix it

this error is creating much problems in GUI devolpement, because with this error, the GUI can't be executed

In my opinion the error location is in:

finance lib or portfolio management lib

because I didn´t make any modficiation in the code, and from night to day, the code broke

if the error is in my code, why this event occur magically?

morgadogs commented 10 months ago

Are you sure it's not your environment? Have you used git pull? Emilio ran this code and it worked Wednesday.

morgadogs commented 10 months ago

Are you sure it's not your environment? Have you used git pull? Emilio ran this code and it worked Wednesday.

He ran both his code (portfolio_management) and the GUI. They were working just fine after he made a fix on Wednesday.

henriqueassis2003 commented 10 months ago

I used git pull and the code still in same state.

I created a new folder to git, used

git clone [repository link]

after I done the download and I installed all libraries

the code still in same state

morgadogs commented 10 months ago

I used git pull and the code still in same state.

I created a new folder to git, used

git clone [repository link]

after I done the download and I installed all libraries

the code still in same state

So I don't know what the problem is, sorry

emiliobrazil commented 10 months ago

@henriqueassis2003 try to execute the

python tkinterguiversion.py

from the bin folder