Skip to content

Instantly share code, notes, and snippets.

View blaggacao's full-sized avatar
Working on an (ad)venture

David Arnold blaggacao

Working on an (ad)venture
View GitHub Profile
blaggacao /
Last active June 24, 2023 16:35
Scrape Colombian CoA for ERPNext
#!/usr/bin/env python
This script scrapes the colombian chart of accounts in two variants from is the most trusted online resource for CoA in Colombia.
Note on Account Types:
account types are mapped on the longest prefix in the 'account_types' dictionary below,
please modify as updates become necessary and rescrape the chart of accounts.
import sys
import json
import re
from dataclasses import dataclass
from json_source_map import calculate
from rich.console import Console
from rich.tree import Tree
from rich.table import Table
blaggacao / flake.nix
Last active October 3, 2021 16:37
{ description = "A mini merge DSL for data overlays";
inputs.nixlib.url = "github:nix-community/nixpkgs.lib";
outputs = { self, nixlib }: let
# Incrementailty of the Data Spine
# --------------------------------
# Te reduce mental complexity in merging chains,
# we must ensure that the data spine of the left
# hand side is not destructively modified.
blaggacao / pyproject.toml
Created December 10, 2019 00:11
name = "dodoo"
version = "0.1.0"
description = "A suck-less Odoo server middleware; batteries included."
authors = [
"David Arnold <>"
license = "LGPL-3.0+"
readme = ''
repository = ""
blaggacao /
Created November 12, 2019 18:24

Keybase proof

I hereby claim:

  • I am blaggacao on github.
  • I am blaggacao ( on keybase.
  • I have a public key ASA_AUKyzpVNocXuVKTUarYDUj6sLILhXlufjq-pPWceKgo

To claim this, I am signing this object:

blaggacao / Studio2PythonFields
Last active May 13, 2021 23:53
Odoo Studio to Python XSLT
<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet version="1.0" xmlns:xsl="" xmlns:foo="" xmlns:bar="">
<xsl:template name="printIndented">
<xsl:param name="text" />
<xsl:param name="indent" />
<xsl:if test="$text">
<xsl:value-of select="$indent" />
<xsl:variable name="thisLine" select="substring-before($text, '&#10;')" />
blaggacao /
Last active July 27, 2019 16:59
pylint-odoo: attribute-string-redundant
# Copyright 2019 David Arnold
# Licensed under the MIT License
import re
from bowler.helpers import print_tree, print_selector_pattern, find_last
from bowler.query import Query
from bowler.types import TOKEN, SYMBOL
from fissix.pytree import Leaf, Node
from fissix.fixer_util import Comma
#!/usr/bin/env python
# -*- coding: utf-8 -*-
import requests
from requests.exceptions import RequestException
from prompt_toolkit import prompt
from prompt_toolkit.completion import FuzzyWordCompleter
blaggacao /
Created June 19, 2019 01:54
One Module On Repo (OMOR) for OCA
SCRIPT=$(realpath -s $0)
urls=$(curl "$1/repos?page=$2&per_page=100" | grep -e 'git_url*' | cut -d \" -f 4)
branch_list="8.0 9.0 10.0 11.0"
--- !Migration
version: 0.2.3
app_version: 10.0
--- !Migration
version: 3.0.0-rc.1
app_version: 12.0
service: odoo
- ../migration.d/