-
Hi.. I'm learning Python and trying to take my knowledge to the next level by using APIs to pull data of interest (which Fantasy Data happens to be). When I run 'yahoofantasy login' on my Command Prompt (Windows 10) after having installed the library/package I run into an error. I know the package was downloaded and installed successfully because I can run the following code "from yahoofantasy import Context" successfully and when I run ctx = Context() it Raises the ValueError asking me if I've already run 'yahoofantasy login' already. So that's all there in my system... This is the text I am receiving after typing 'yahoofantasy login' into my Command Prompt: " 'yahoofantasy' is not recognized as an internal or external command, operable program or batch file." I then tried running it from within Python via the command line but then received a Syntax Error. I am seriously a novice with a strong grip on the fundamentals of the language, but I am really trying earnestly to learn how to leverage APIs. Maybe this is too advanced for my current knowledge. Any assistance would be appreciated! I've already logged into the Yahoo Developer app and created a new app and I can see my Client ID and Client Secret there. No idea about the refresh token though. |
Beta Was this translation helpful? Give feedback.
Replies: 4 comments
-
Ah yes, this is something that bites newcomers quite a bit I've found. It's actually a Python/system issue, not so much an issue with this library. The problem is your system doesn't know where to find the So either one of two things probably happened here.
I'm going to close this since it's not an issue with this particular library, but rather python basics in general. Good luck! |
Beta Was this translation helpful? Give feedback.
-
Thanks! And sorry for raising an issue as I realize it implies something was wrong with the code :-) .. it was the only way I could figure out how message/comment. |
Beta Was this translation helpful? Give feedback.
-
No problem at all! GitHub did roll out something called Discussions somewhat recently but I don't have it turned on for this repository, so an issue is totally fair game. |
Beta Was this translation helpful? Give feedback.
-
you inspired me 😄 just turned on discussions and converted this thread to one - seems like a perfect place for it! |
Beta Was this translation helpful? Give feedback.
Ah yes, this is something that bites newcomers quite a bit I've found. It's actually a Python/system issue, not so much an issue with this library.
The problem is your system doesn't know where to find the
yahoofantasy
executable. This was installed somewhere when you ranpip install yahoofantasy
. But unless that directory is in your PATH it won't know where to find it.So either one of two things probably happened here.
pip install yahoofantasy
or you got an error when you did.I'm going to close this since it's not an issue with this particular lib…