Plurrrr

week 34, 2020

Usage of the Heap Data Structure in Go (Golang), with Examples

Heap is one of the powerful data structures, which optimizes the access to minimum or maximum value within a collection. In this post, we will go over the main characteristics of the data structure itself and understand how we can make use of it with Go (Golang) programming language with the usage heap package from the base library of Go.

Source: Usage of the Heap Data Structure in Go (Golang), with Examples, an article by Tugberk Ugurlu.

Common Python Packaging Mistakes

I think we can all agree that packaging a Python project is harder than it should be. With numerous guides & tutorials out there, people still make mistakes. Some of these mistakes break a project, some just make it less attractive, and some even cause a project to step on the toes of other projects.

As the admin of the wheel-analysis and -browsing site Wheelodex, I see a number of poorly-built wheels each morning as I peruse the day’s new entries. This eventually motivated me to create check-wheel-contents — a program for scanning a wheel for many of the below problems plus several others — in an attempt to get people to clean up their wheels, yet still the poorly-packaged projects persist.

In yet another attempt to get people to fix their broken packages, here now are some of the more frequent types of mistakes I see — along with advice on how to avoid & correct them — in no particular order.

Source: Common Python Packaging Mistakes, an article by John T. Wodder II.

Dynamic SSL Certificate Storage in HAProxy

When you route traffic through an HAProxy load balancer, you gain the ability to terminate SSL at the load balancer. HAProxy encrypts communication between the client and itself and then sends the decrypted messages to your backend servers, which means less CPU work on the servers because there’s no encryption work left to do. HAProxy adds extra SSL functionality too including SNI for choosing the right certificate, ALPN for negotiating the application protocol, OCSP stapling for prefetching certificate revocation statuses, and settings for disabling obsolete versions of SSL and TLS.

Source: Dynamic SSL Certificate Storage in HAProxy, an article by Nick Ramirez.

What's New In DevTools (Chrome 86)

  • New Media panel
  • Capture node screenshots via Elements panel context menu
  • Issues tab updates
  • Emulate missing local fonts
  • Emulate inactive users
  • Emulate prefers-reduced-data
  • Support for new JavaScript features
  • Lighthouse 6.2 in the Lighthouse panel
  • Deprecation of “other origins” listing in the Service Workers pane
  • Show coverage summary for filtered items
  • New frame detailed view in Application panel
    • Frame details for opened windows
  • Elements and Network panel updates
    • Accessible color suggestions in the Styles pane
    • Human-readable X-Client-Data header values in the Network panel
    • Auto-complete custom fonts in the Styles pane
    • Consistently display resource type in Network panel
    • Clear buttons in the Elements and Network panels

Source: What's New In DevTools (Chrome 86), an article by Jecelyn Yeen.

A deep dive into the official Docker image for Python

The official Python image for Docker is quite popular, and in fact I recommend one of its variations as a base image. But many people don’t quite understand what it does, which can lead to confusion and brokenness.

In this post I will therefore go over how it’s constructed, why it’s useful, how to use it correctly, as well as its limitations. In particular, I’ll be reading through the python:3.8-slim-buster variant, as of August 19, 2020, and explaining it as I go along.

Source: A deep dive into the official Docker image for Python, an article by Itamar Turner-Trauring.

Analyzing Python Code with Python

One of the special things about software engineering as a profession is the possibility of ars-poetic work: part of our work is building tools that target our own work; perhaps a few surgeons around the globe can design and meld their own scalpel, but for software engineers building our own tooling is a day to day reality.

Source: Analyzing Python Code with Python, an article by Rotem Tamir.

Python Knowledge Graph: Understanding Semantic Relationships

Knowledge Graphs are very powerful NLP tools and advanced studies in the field of Knowledge Graphs have created awesome products that are used by milions of people everyday: think of Google, Youtube, Pinterest, they are all very important companies in this field and their knowledge graphs results are spectacular to analyze and use.

Source: Python Knowledge Graph: Understanding Semantic Relationships, an article by Marius Borcan.

Haskell mini-patterns handbook

This blog post contains a structured collection of some programming mini-patterns in Haskell with the detailed description and examples, some small “quality of life” improvements that would help everyone on their developer journey.

Source: Haskell mini-patterns handbook, an article by Dmitrii Kovanikov and Veronika Romashkina.

Container processes shouldn't run as root!

Docker containers, and containers as a whole, are really just a regular program wrapped in some extra protections provided by the kernel (namely cgroups etc) to create isolation, and other interesting features.

Unlike VMs, containers run closer to the host operating system, so close they use the same kernel, meaning it’s even more important to protect it.

Source: Container processes shouldn't run as root!, an article by Jake Howard.

An Introduction to Functional Design

Functional programming doesn’t need to be complex, confusing, or theoretical.

Instead, functional programming can be simple, natural, and practical, helping you solve problems with more power and more joy than ever before.

A key to unlocking this potential is understanding functional design, a framework for applying functional programming to real world problems that I have been teaching at Ziverge as well as on my Patreon mentorship program.

Source: An Introduction to Functional Design, an article by John A De Goes.

Why I switched from Vim to Emacs

I have been a loyal Vim user since, well, I don't even remember any longer. Over the years, I tried other editors, but Vim commands and keyboard shortcuts are second nature to me, so much so that I ended up doing :w every time I wanted to save in another application. So, for a long time, I stuck with Vim for all my note-taking and writing. By combining Vim with Markdown syntax, I could easily export my notes to any format for other uses or sharing with my colleagues.

I've always enjoyed working in a terminal, but I usually needed other applications for my email, calendar, and tracking the time I spend on various tasks, which I like to do for numerous reasons. I tried different cloud solutions, kanban boards, and email clients, but I kept looking for a way to do it all in a terminal. I tried some great projects for time tracking and kanban on the command line—but there was always something missing in my workflow. That is until I read an article about using Org mode in Emacs.

I had tried Emacs before and found out there are even more commands and keyboard combinations to keep track of in Emacs than Vim! However, every time I read an article explaining different ways to use Org mode, it seemed like Emacs was the solution I was looking for. So I made another venture into the world of Emacs.

Source: Why I switched from Vim to Emacs, an article by Jimmy Sjölund.