Skip to content

Instantly share code, notes, and snippets.

View froi's full-sized avatar

Froilán Irizarry Rivera froi

View GitHub Profile
froi /
Created February 28, 2024 18:33
Decode URLs with Python
import urllib.parse
print(f"URL has been decoded: {decoded_url}")
froi / Makefile
Last active January 15, 2024 05:51
Base Makefile for Python projects
mypy: ## Run the MyPy type checker
@poetry run mypy src
ruff: ## Lint project using Ruff
@poetry run ruff check .
lint: mypy ruff
format: ## Format project using Ruff --fix
@poetry run ruff check --fix .
froi /
Last active July 20, 2023 03:45
semver dependency spec
froi /
Last active July 19, 2023 19:32
from pydantic import BaseSettings
class Settings(BaseSettings):
"""Setting / configuration class that inherits from Pydantic BaseSettings
This will first check for environment variables of the same name, if none are found
the default values are applied.
More info:
froi / poetry-install-compilation-log
Last active May 5, 2023 01:05
nullptr_t: Error log for Poetry install of Python packages that need some sort of compilation
❯ poetry install --only=main
Installing dependencies from lock file
Package operations: 20 installs, 0 updates, 0 removals
• Installing grpcio-tools (1.48.2): Failed
Command '['/Users/froi/Library/Caches/pypoetry/virtualenvs/projecte-5wzozpT2-py3.8/bin/python', '-m', 'pip', 'install', '--use-pep517', '--disable-pip-version-check', '--prefix', '/Users/froi/Library/Caches/pypoetry/virtualenvs/projecte-5wzozpT2-py3.8', '--no-deps', '/Users/froi/Library/Caches/pypoetry/artifacts/4c/f1/a9/934e68c4bc7e032f327f4bc871af52e86a4f31a91e0e3b33ac131d84f7/grpcio-tools-1.48.2.tar.gz']' returned non-zero exit status 1.
froi /
Last active May 25, 2022 20:48
gcp helper commands
#!/usr/bin/env zsh
# These commands can be configured somewhat in ~/.cbtrc
# full docs at
# Delete all rows in a table
cbt -instance ${instance} \
froi /
Last active February 23, 2022 17:59
GitHub PR template


Jira and GitHub Issues

froi /
Created January 3, 2022 20:57
Documentation section of a pull request template


Creating and maintaining documentation is increadibly important. When needed, as part of this PR you need to tackle this too.

  • Documentation was created. URL to docs:
  • Documentation was updated. URL to docs:
  • Changes did not need documentation updates.
froi /
Last active June 30, 2021 04:34
Command to test gpg key
#!/usr/bin/env sh
echo "1234" | gpg --no-use-agent -o /dev/null --local-user <KEYID> -as - && echo "The correct passphrase was entered for this key"