mastodon.cc is one of the many independent Mastodon servers you can use to participate in the fediverse.
Mastodon for Art

Administered by:

Server stats:

68
active users

#refactoring

1 post1 participant0 posts today

Master thesis by Hendy Liang: "Property-Based ASTs: Enabling Language Parametricity in Refactoring Tools"

"By leveraging Tree-Sitter, a parser generator that creates parsers that produce generic, property-based ASTs, this research adapts Renaissance, an existing industrial refactoring tool, to support multi-language extensibility with minimal additional effort."

repository.tudelft.nl/record/u

repository.tudelft.nlProperty-Based ASTs | TU Delft Repository

Je suis un développeur logiciel expérimenté (20+ :) indépendant, mentor et coach, je serai disponible en février.
Si vous cherchez un coup de main pour dompter une base de code sauvage, préparer une grosse évolution ou plus généralement développer un logiciel maintenable, c'est le bon moment :)

J'interviens principalement de deux façons:
* intégré à l'équipe, je fais le taf avec vous en pair programming
* et/ou en accompagnement, je vous guide dans vos réflexions et l'implémentation (qq heures/semaine)

* tous langages/technos/environnements
* remote only ou Ambert
* déplacement ponctuel ok
* freelance

I was going gung-ho on this #software project and then realized I needed to insert a layer of abstraction. I'm now on the second full day of #refactoring and each thing I touch makes me think of 3 other things.

I don't regret it--I'm already better off--but, UGH. When can I push forward again?!

In other #ThingUmbrella related news: I've completed the weekend round — 65+ commits — of restructuring & splitting up some larger packages, with the result of there being nine more of them now. 198 in total! Another side effect of this effort is generally fewer dependencies, incl. for some select other core packages (partially by choosing to intern small functions/functionality, in cases where it made sense...)

The new packages (but existing functionality!) are:

- thi.ng/bidir-index : Bi-directional map/index data structure
- thi.ng/disjoint-set: Disjoint Set data structure w/ path compression (useful for union-find tasks)
- thi.ng/object-utils : Plain JS object & map manipulation
- thi.ng/pixel-convolve: Extensible image convolution, preset kernels, normal map generation
- thi.ng/pixel-dominant-colors: k-means based dominant color extraction from images
- thi.ng/sorted-map: Skiplist-based sorted map & set data structures
- thi.ng/sparse-set : Sparse set data structure
- thi.ng/trie : Trie-based map data structure w/ prefix search/query
- thi.ng/uuid : Binary & string-based UUID v4 generation

The packages which have been split up have received major version updates w/ notices on both readmes & changelogs:

- thi.ng/adjacency
- thi.ng/associative
- thi.ng/pixel
- thi.ng/random

In case you missed it, please see this issue for more context:

github.com/thi-ng/umbrella/iss

thi.ng/bidir-indexBi-directional index mapping arbitrary keys to numeric IDs & vice versa

github.com/CleanCocoa/Declarat

I changed the way a "word range" is detected to be, hopefully!, more readable.

#Refactoring weird code is always an adventure: commit by commit I'm making progress, not knowing what the actual end result will look like. When tests break, revert one step, or at least use the debugger to understand the failure better and maybe fix the faulty logic.

I didn't anticipate that the change would look like *this*.

But it's better than what was there before.

GitHubRefactored WordRange string iteration by DivineDominion · Pull Request #10 · CleanCocoa/DeclarativeTextKitBy DivineDominion

Line must go down! Maintenance weeks are over![1]

Software maintenance, large scale refactoring, creating/improving documentation, deduplicating code are some the most boring & thankless tasks, but also so essential, especially on projects of the scale of thi.ng/umbrella (with almost 4100 source files)

Yesterday was #ReleaseFriday, most prominently featuring new major version & expansion of thi.ng/geom (and its 20+ support packages) — I will write about it more in coming days.

Part of this major release cycle also included a repo-wide round of various cleanups, incl. updating & reviewing 425 code snippets in doc strings and preparing them for extraction[2], fixing links in docs, enforcing naming conventions for package internals across all 190+ packages, deduplicating and refactoring internals in dozens of projects, updating examples, building tools to generate diagrams for readmes etc.

These have been some intense few weeks, but I'm super glad it's all done (for now)!

Happy coding! :)

[1] The hours of tech debt auto-calculated in this diagram are a bit pointless (completely OTT and containing alot of false positives), but the graph still nicely shows the effort & progress involved... Btw. the chart is from here:

codeclimate.com/github/thi-ng/

[2] Wherever possible, code examples/snippets in project readme's and docstrings embedded in source code can be extracted into their own source files via thi.ng/tangle and then run directly (e.g. via bun.sh). You can find more info in this section of the main readme:

github.com/thi-ng/umbrella/blo

Since today is the 20th anniversary of my first blog post, I'm going to embarrass myself by re-publishing it:

Big Refactorings

When attempting a pervasive refactoring in a large system, it's tempting to do the full refactoring in a localized part of the system and leave other parts for another day - perhaps because you run out of time or get bored. You can assuage your conscience by marking the remaining places with todo comments or deprecating old methods.

#refactoring #redgreen #tdd

1/5

Like @jaredwhite I saw this these ads for Copilot all over Github the other day. "code 55% faster with copilot" indieweb.social/@jaredwhite/11

What if I spend 90% of my time refactoring? A LLM is not a refactoring tool! That's the topic of my latest youtube video: youtu.be/iXGBIX8gudE

Do you agree?

Indieweb.Social Jared ⚛️ "Order of Hooks" 🪝😱 (@jaredwhite@indieweb.social)Attached: 1 image da fuq is this GitHub 😡

Want a nice _and_ reliable #calendar application for #GNOME and #Linux desktops (& #mobile!) in general, based on the @EvolutionGnome data server?

Know some #C #programming and looking for a well-scoped challenge to get your feet wet and put those skills to use in #opensource?

#GNOMECalendar could really use your help to write unit tests, so that we can use #TestDrivenDevelopment #TDD #CI for #refactoring all timezones-related code and make it reliable. Now is the time!
fortintam.com/blog/call-for-he

Continued thread

I'll start... In a previous life I was maintaining a tool in which massive analyses of machine code sequences were being calculated, and then subtly (albeit correctly) ignored. This pointless calculation comprised approximately 90-95% of the tool's runtime, on average. One line change, and led to an excellent postmortem.