Python Bytes is a weekly podcast hosted by Michael Kennedy and Brian Okken. The show is a short discussion on the headlines and noteworthy news in the Python, developer, and data science space.

#375 Pointing at Countries

March 19, 2024 00:24:56 21.13 MB Downloads: 0
Topics covered in this episode:
Watch on YouTube

About the show

Sponsored by ScoutAPM: pythonbytes.fm/scout

Connect with the hosts

Join us on YouTube at pythonbytes.fm/live to be part of the audience. Usually Tuesdays at 11am PT. Older video versions available there too.

Michael #1: pycountry

  • A Python library to access ISO country, subdivision, language, currency and script definitions and their translations.
  • pycountry provides the ISO databases for the standards:
    • 639-3 Languages
    • 3166 Codes for representation of names of countries and their subdivisions
    • 3166-1 Countries
    • 3166-3 Deleted countries
    • 3166-2 Subdivisions of countries
    • 4217 Currencies
    • 15924 Scripts

Brian #2: Does Python have pointers?

  • Ned Batchelder
  • Turns out, this is really the description of “what’s a variable in Python?” that helps to make sense of the “variables as names” model in Python, especially for people coming from languages that use pointers a lot.
  • You can use id() to find out what a variable points to
  • You just can’t do the reverse of access it given an id.
  • There’s no “dereference” operator.
  • See also Python Names and Values, also by Ned
    • Should be required reading/viewing for all Python curriculum.

Michael #3: ingestr

  • ingestr is a command-line application that allows ingesting or copying data from any source into any destination database.
  • Works on both MongoDB and Postgres and many more.
  • incremental loading: append, merge or delete+insert

Brian #4: Make your terminal nice

  • David Lord
  • David’s switched to Fish and Starship
  • I tried switching to Fish several times, and I guess I’m good with zsh.
    • Although I admire the brave comic sans motto: “Finally, a command line shell for the 90s”
  • But I’m finally ready for Starship, and it takes almost no time to set up
  • Plus it’s fast. (Has it always been Rust?)

Extras

Brian:

  • Doing some groundwork for a SaaS project, using SaaS Pegasus
    • I just talked with Cory from Pegasus for an upcoming PythonTest episode
    • I haven’t decided whether to save up SaaS episodes for one big series, or spread them out.
    • But mostly I’m excited to get my project started.

Michael:

Joke: Anti-social engineer