Really!? You are so good and you have done all by yourself? Dang, that's beyond motivating 😅
Yes.
I am not even good.
The stuff I build is far from industry standard.
What seems impressive now, will look like a joke another month in.
Once you've built a few things, you'll notice.
Repetition -> learning.
Sometimes I do totally unrelated stuff and suddenly I understand something that I tried weeks ago...
Sessions/Requests are still a bit obscure for me, though, but I can't hope to understand everything immediately, so I'll keep checking the docs and experimenting with different API call to strengthen my knowledge.
Yeah... I can tell by your comments on the code, that it hasn't 'clicked' for you.
Thing is: that has nothing to do with HIVE, but you just need more practice with Python and code in general.
...and there are enough Python tutorials out there.
If something isn't clear, I am happy to help, but I can't also try to teach Python in my tutorials.
That with
statement is very pythonic and it's powerful.
Other languages don't even have that concept...
For now: Please trust me, it's the cleanest way to go about it.
I use it for reasons and they will become clearer when I continue.
It's worth exploring...
I love your approach, tbh: it challenges the reader to actively learn and this is by far more efficient than just reading an explanation.
That's it. Feels good that it worked for you.
But it really only works, when people actually try to use it.
Tagging @slobberchops for good measure here.
Still far from clicking, but slowly I'll get it :)
100% trust! I know that "with" is very powerful and I was using it to open a file, but from your code I learned that it can do much more, so yup, just from a few lines of yours thare's a lot of stuff which are very much worth exploring!
Your comments and posts are already way much more than what I was hoping to find :)
...and close it.
with
keeps any session (writing files, accessing databases, http sessions) open and closes it, too. This leads to cleaner structure and cleaner code.(The other way would be using
open()
andclose()
functions, which can lead to all sorts of trouble)btw did you manage to use condenser's get_accounts function?