Why and how I built the simply server-less @hintjensquotes@botsin.space bot. And my tribute to Pieter.
Recently I setup the Mastodon bot serving quotes of Pieter Hintjens. Pieter was one of the most influential man I ever met. And I do consider his ideas as brilliant, …
While Go comes with go test and a testing package by default, the experience can be better with testify package. Git hub page introduces it as Go code (golang) set of packages that provide many tools for testifying that your code will behave as you intend.
By the end I found the …
While Go comes with go test and a testing package by default, the experience can be better with testify package. Git hub page introduces it as Go code (golang) set of packages that provide many tools for testifying that your code will behave as you intend.
By the end I found the …
While Go comes with go test and a testing package by default, the experience can be better with testify package. Git hub page introduces it as Go code (golang) set of packages that provide many tools for testifying that your code will behave as you intend.
By the end I found the …
The common problem for monorepo and go modules is that the following
It is really easy to miss the go.mod replace directive
In a following text we will learn more about Linux, namespaces and container technologies like Docker or Podman.
The problem While go build is awesome tool, …
Problem Once upon a time I got a task to merge duplicate URLs in our production database. It turned out that there were a lot of same urls like https://example.com?fbclid=1234 and https://example.com?fbclid=5678 we wanted to merge. Code to normalize URL was easy to develop. Code …
Go database/sql defines interfaces for SQL databases. Actual driver must be implemented in own package. And dependency injection is done as a part of import and build system. Lets go deeper to see how it is actually implemented.
This exercise will result in a simple driver backed …
Running go mod download slows down each CI run a lot. More dependencies increases time and it wastes the bandwidth again and again. As we do use special CI containers for the task, then go modules can be downloaded during container build phase and CI build will benefit from it. …
As a long time Firefox user I was horrified to use web browser with very limited blocking capabilities. However Samsung Browser is very handy tool for some sites. However the number of spam, scam, or porn pages and advertisements makes browsing there very unpleasant experience. …
Working on a web project spread in more domains brings you to Cross-Origin Resource Sharing. Browsers use it to if it code from one origin can call HTTP methods placed elsewhere. Responses must contain specific headers, like Access-Control-Allow-Origin, which must match …
I recently joined company as a Python developer. However it turns out there is bigger need to evolve their code written in golang (and PHP and Javascript). I am not an expert in go, so it took me a while to figure things out. However I love to learn new things and to solve new …
Limiting your goroutines How to properly implement goroutine pool in golang with input and output channel(s). Text expects knowledge about golang and about Go Concurency. That means I am not going to explain what goroutine, channel or defer actually are.
Intro Gorutines are some …