Atomis Development Blog

jdBasic Has No Ecosystem

A colleague told me jdBasic has no ecosystem, so he stays with Python.

Now it has one. lib/ holds 45 modules written in jdBasic itself: 32,000 lines, 5357 assertions in their self tests, green interpreted and compiled with -c. Each module stands in for a Python package, and most are checked against it. The statistics against scipy, the hashes against hashlib, the money against decimal, the cron times against croniter, the QR codes against segno, module for module.

A chart from a CSV

A line chart of revenue by region for 2026, drawn by the SVG module from a data frame
IMPORT DF, SVG

DIM sales = DF.READCSV("sales.csv")
DIM c = SVG.CHART("line", 760, 420)
SVG.SETOPT(c, "title", "Revenue by region, 2026")
SVG.FROMDF(c, sales, "month", ["North", "South", "West"])
SVG.WRITEFILE(SVG.RENDER(c), "chart.svg")

No window, no plotting library. The chart is an SVG file with a tooltip on every point, and it reads on a light and a dark page.

Five modules in one session

A terminal session: a data frame table, a linear trend fitted with FIT, a gross amount and three installments with MONEY, an IBAN and a French VAT id checked with VALID, a PBKDF2 password hash verified with SECRET

A data frame, a least squares trend, 19 percent VAT on an amount parsed from German text, 100 euros in three parts that still add up to the cent, an IBAN and a VAT id with their check digits, a password hash with 600,000 PBKDF2 rounds.

An invoice with a GiroCode

An invoice page served by JDWEB: three lines, net, VAT and total, the checked IBAN and an EPC payment QR code
IMPORT JDWEB, MONEY, VALID, QR

FUNC Invoice(request)
    DIM iban$ = "DE89370400440532013000"
    DIM net = MONEY.PARSE("268,75", "EUR")
    DIM gross = MONEY.PLUS(net, MONEY.TIMES(net, "0.19"))
    DIM giro = QR.EPCMATRIX("Papier & Toner GmbH", iban$, MONEY.DECIMAL$(gross, "EUR"), "COBADEFFXXX", "Invoice RE-2026-0415")
    RETURN "<p>Total " + MONEY.CURRENCY$(gross, "EUR") + "</p>" + _
        "<p>IBAN " + VALID.IBAN$(iban$) + "</p>" + QR.SVG$(giro, 4)
ENDFUNC

JDWEB.GET("/invoice", Invoice@)
JDWEB.SERVE(8080)

The amounts are whole cents, so 19 percent of 268.75 is 51.06 and not 51.0625 rounded somewhere later. The QR code is the EPC payment code banking apps read, encoded in jdBasic with Reed-Solomon over GF(256) and all eight masks scored.

What is in lib/

Every module has a page with its API, a demo and a self test. IMPORT DF and it is there. PKG installs modules into ~/.jdbasic/lib by semver range, with a lock file.

Getting it

The release bundles for Windows, Linux and macOS ship the whole lib/. The index is lib/README.md in the jdBasic repo.

My colleague still writes Python. Just not because jdBasic has no ecosystem.

jdbasic.org, source at github.com/AtomiJD/jdBasic.

← Back to all posts