TIL: Python tips and tricks collection

This blog post is a collection of Python tips and tricks that I have found useful over the years. I will keep updating this entry as I learn more.

  • How to add a custom CA Root certificate to the CA Store used by pip in Windows?

    pip config set global.cert path/to/ca-bundle.crt
    pip config list
  • Generate requiements.txt
    Use pipreqs

    pip install pipreqs
    pipreqs /path/to/project

    or pip freeze. But, freeze saves all packages in the environment including those that you donĀ“t use in your current project!

    pip freeze

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.