dogweather

dogweather

Anyone know about work along the lines of HAL?

Dave, I hate to interrupt, but I’ve detected a fault in one of my circuits.

I’ve stumbled on a need for this as well as a way to implement it: Software that re-runs its test suite on itself after updating its fixtures based on new environmental factors. The next step (which I’ll start working on) is software that fixes itself.

I realized that maybe people in the Elixir/Erlang community may have done work in this area, given the hot-swappable nature of the system. Anybody heard of work like this? It’s been surprisingly tricky to search for because I end up with lots of hits for automated testing, which is only a lower-level component of what I’m talking about.

EDIT: It looks like self-healing might be the thing I’m after.

Showing Posts 1 to 10

Zesky665

Zesky665

Correct me if I’m interpreting this incorrectly, but isn’t what you’re describing like a CI pipeline that runs when certain conditions are met rather than on code commit?

I’m interested since I working on an app that tests test quality and this might be in the same wheelhouse.

xlphs

xlphs

I know some embedded engineers write code that checks memory content at runtime to ensure the code being executed is actually what is supposed to be executed. Something to do unstable hardware. And of course fixing that after detecting mismatch.

dogweather

dogweather OP

Actually, it’s a piece of an ETL pipeline that will run daily. And so I’d it to refuse to run if the input format has changed too much. It’s Haskell that I’m going to try implementing in Elixir: GitHub - public-law/nevada-revised-statutes-parser: Parses the Nevada NRS into well formed JSON · GitHub

My tests mostly run on fixtures which are full files: nevada-revised-statutes-parser/test/fixtures at master · public-law/nevada-revised-statutes-parser · GitHub

dimitarvp

dimitarvp

Have you looked at mix test.watch?

A far cry from HAL but it allows you to have your tests re-ran as you are modifying your code.

dogweather

dogweather OP

Thanks! I’ve wanted an Elixir equivalent of Haskell’s stack test --file-watch

dimitarvp

dimitarvp

You should probably view this in context. Any “true” AI – like a sentient, intelligent being – that is much better and more durable than us, will likely have a stream of consciousness. Part of that includes continuously pulling diagnostic information and evaluating it; sort of like you will know if you suddenly got a leg cramp in the next milliseconds of it happening.

Truth is, having an artificially sentient entity will mean a lot of not-so-energy-efficient activities happening all the time; it cannot just react to things, it has to take the initiative and continuously process sensory information… sort of like us.


To create a software that fixes itself you’ll need a ton of specifications, goal-oriented programming, and you also must have a feedback mechanism (which answers the question “is the result of this function correct”?). I am not saying it’s impossible; it definitely is possible. And you’ll also probably need some logic programming as well (Prolog).

gausby

gausby

If you code for the “happy” path—and make your pattern matches really strict—you will see it in your error logs every time your application encounter something unexpected. You can then decide on what to do in these discovered cases.

Besides the stuff that is build in to OTP (i.e. Supervision), patterns such as safety-valves and fuses can help you detecting and handling errors in regards to third-party systems—this way you can detect if something is wrong in your circuits and act accordingly :slight_smile:

Cochonours

Cochonours

Safe healing, I think it could if you meant to automatically get back in time instead of trying to invent a new patch to fix itself. Like, if a test fails or that some of the web pages display errors, you could code something using git bissect that would find the culprit and go back in time enough to work again, until YOU fix the problem and push the fixed version.

Zesky665

Zesky665

Isn’t this just a more complicated way to do CI?

Cochonours

Cochonours

It’s only more complicated because nobody coded that yet. But indeed it would merge some aspects of CI into the server itself. That’s probably not a very good idea except for a fun project (for some definition of fun).

— All posts loaded —

Where Next? Top

Trending in Questions Top

katta
I having some trouble figuring out if I have set myself too strict of standards for my production server. Currently I can handle 75% of r...
New
achenet
Hello, I’m trying to build a basic Phoenix web-app, and I’d like to use Tailwind. However, when I launch mix phx.server, I get an error...
New
Cxx-mlr
I’m working on a small exercise involving update_in/3, and I came up with this solution: data = %{ name: "Periodic Table", category:...
New
ChrisAmelia
I’ve got trouble wrapping my head around the order in which functions are called in this snippet (from Phoenix’s authentication): toke...
New
dillonoconnor
Is there any way to avoid the Hologram compiler running when using iex? It seems like the front-end code could potentially be disregarded...
New
thiagogsr
** (ArgumentError) expected :max_attempts to be a positive integer, got: {:@, [line: 10, column: 19], [{:max_attempts, [line: 10, column:...
New
unaware8150
Hello folks! So at work, we are seeing some situations where we have to define some “fixed” strings that are used across the codebase in...
New

Other Trending Topics Top

GenericJam
Edit: 2026 May 15 - This post is archived. Mob is alive!! Main docs: mob v0.7.11 — Documentation A bit of explanation for the slightly c...
New
mudasobwa
I am happy to introduce the very α version of the new programming language compiled to BEAM. Welcome Cure. It has literally three kille...
New
garrison
Hobbes is a low-level distributed database for the Elixir programming language. Hobbes provides a simple, safe, and scalable storage lay...
New
budgie
A little off-topic, but I feel like people here have a good head on their shoulders. I used to be quite good at making software. Was luc...
New
KristerV
Hey. Is there anyone here who creates agents in their apps? Not talking about using agents, but creating them. I’m finding it pretty diff...
New
mcass19
ExRatatui lets you cook up rich terminal UIs in Elixir, powered by Rust’s ratatui via Rustler NIFs. Build interactive terminal applicatio...
New

We're in Beta

About us Mission Statement

Options

Thread Display Mode




Thread Preview

Skip Thread Previews