Patrick the purple dragon

dragoncoder047’s blog

random thoughts about nonrandom things

Articles tagged with python

Perhaps It Was Too Complicated

By dragoncoder047

I guess I lied. About five months ago, I posted some thoughts about an upcoming Python interactive fiction engine, where the world model is not actually a tree, but simulated as such by relations. For example, there could be an apple inside of a refrigerator, and while it would make …


Zero-Thickness Tree

By dragoncoder047

In a previous post, I started some mental planning for an interactive fiction engine in Python. I picked it up again last week and started working on a new version. Custom logic is implemented using a tiny Python library I created called json_runner, which as you might guess, is capable …


PICKLE Has Regular Expressions, Apparently

By dragoncoder047

I worked for a while last week on the PICKLE implementation in Python. As I no longer have to work on the garbage collector, after I wrote a little “glue code” I immediately dove into the core functionality of PICKLE: the pattern-matching engine. Once I get the algorithm down, I …


A Very Confusing Data Model

By dragoncoder047

For the past week or two I have been working on a few things simultaneously. I keep prototype code that I’m developing but not quite ready to release yet in private GitHub repositories, and publish them when I’m ready. Lately I’ve been working on two different and …


Schemascii ± 0

By dragoncoder047

I have been working really hard this week on Schemascii. Like, maybe too much. But, I finally got Schemascii to the point that I could (if I wanted) upload it to PyPI and it would be a valid package.

Schemascii is also able to be called as a command-line program …


Schemascii ± 1

By dragoncoder047

I spent the last two days fooling around with my half-idea of a diagramming program, Schemascii. What it’s supposed to do is be able to make a diagram of a circuit (like the ones you might make in Eagle or KiCad before you plan a circuit board) out of …


Pyodide Issues

By dragoncoder047

I am currently working on an online console for Quackery that is using the Pyodide in-browser Python interpreter. The only bad thing is, Python’s input() function blocks until input is provided, which can’t be done in the browser because everything is asynchronous. The only way for it to …


Why I Prefer Python

By dragoncoder047

In developing Phoo today I was unpleasantly presented with yet another reason why I prefer Python. It was when I was working on the new Importer API for loading external modules into Phoo that I accidentally did this:

class Importer { /* stub class */ }
class FetchImporter extends Importer {
    constructor(basePath, fetchOptions = {}) {
        /* no …

Airdrop for non-Apple users

By dragoncoder047

It has come up often where I have a file on my parent’s Mac that I need to send to my computer. Any Apple user would probably just use Airdrop. But I use Linux!… So I created a little Python script that allows sending files between computers with the …