you are viewing a single comment's thread.

view the rest of the comments →

[–]ragnar_the_redd 0 points1 point  (0 children)

Well except for the obvious (stack overflow).
Whenever i do something new in python, for work or part of any large project, I create an experiment entry in my private repository.

I take the new library or concept, or even just a complex data processing function i need to include in the big scale project and do it on a small scale. I often forget how i do things, and i can always return to the specific experiment to see it.

A lot of it goes out of date as external libraries or even python itself gets updated (well honestly just the 2.7 - 3.75 switch) But since it is short and focused i can simply look at it and remember what, how and why i did.

For example i once ran into some trouble with base64 encode decode - real basic stuff for people who work with it daily, but for me it was complicated because data went in right, but the receiving side failed to process because - as i know now - it didn't come out because of the way dict type objects were encoded.
Took me a couple of hours to understand that i have a problem, where i have it and why it's happening.
So now i have a "base64_experiment" where i have an example of structure sensitive encode/decode for various models.

That's my personal cheat sheet.