<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Jonas G Mwambimbi</title>
    <description>The latest articles on DEV Community by Jonas G Mwambimbi (@jonas1015).</description>
    <link>https://dev.to/jonas1015</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F3821707%2F5ac63ce7-aaa7-4fc0-94de-28cdc7dbac59.jpeg</url>
      <title>DEV Community: Jonas G Mwambimbi</title>
      <link>https://dev.to/jonas1015</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/jonas1015"/>
    <language>en</language>
    <item>
      <title>How I stopped re-resolving dependencies without rewriting pip</title>
      <dc:creator>Jonas G Mwambimbi</dc:creator>
      <pubDate>Thu, 11 Jun 2026 17:02:39 +0000</pubDate>
      <link>https://dev.to/jonas1015/how-i-stopped-re-resolving-dependencies-without-rewriting-pip-1jkp</link>
      <guid>https://dev.to/jonas1015/how-i-stopped-re-resolving-dependencies-without-rewriting-pip-1jkp</guid>
      <description>&lt;p&gt;I got tired of watching pip think for at least 45 seconds before I could write a single line of code only to get back to waiting for dependency resolution and/or installation, so I built a hack that remembers the answer.&lt;/p&gt;

&lt;h3&gt;
  
  
  What was the issue really?
&lt;/h3&gt;

&lt;p&gt;I built a plug-and-play FastAPI engine &lt;a href="https://github.com/jonas1015/chacc-api" rel="noopener noreferrer"&gt;ChaCC‑API&lt;/a&gt; that loads modules with their own &lt;code&gt;requirements.txt&lt;/code&gt;. With every restart, it re‑resolved every module's dependencies. Like running &lt;code&gt;pip install&lt;/code&gt; over and over.&lt;/p&gt;

&lt;p&gt;In development, with a medium‑sized module, that meant &lt;strong&gt;45 seconds&lt;/strong&gt; of waiting. Even when nothing changed.&lt;/p&gt;

&lt;p&gt;Restart server? Wait. Edit a module? Wait. Add a module? Wait again.&lt;/p&gt;

&lt;h3&gt;
  
  
  Then this happened:
&lt;/h3&gt;

&lt;p&gt;I built &lt;a href="https://github.com/jonas1015/chacc-dependency-manager" rel="noopener noreferrer"&gt;chacc-dependency-manager&lt;/a&gt;. It does one smart thing though very small :)&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Cache the result of &lt;code&gt;pip-compile&lt;/code&gt;.&lt;/strong&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight python"&gt;&lt;code&gt;&lt;span class="n"&gt;cache_key&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nf"&gt;hash&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;requirements&lt;/span&gt; &lt;span class="o"&gt;+&lt;/span&gt; &lt;span class="n"&gt;python_version&lt;/span&gt; &lt;span class="o"&gt;+&lt;/span&gt; &lt;span class="n"&gt;os&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="n"&gt;cache_key&lt;/span&gt; &lt;span class="ow"&gt;in&lt;/span&gt; &lt;span class="n"&gt;cache&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
    &lt;span class="n"&gt;pinned&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;cache&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="n"&gt;cache_key&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;           &lt;span class="c1"&gt;# use saved answer
&lt;/span&gt;&lt;span class="k"&gt;else&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
    &lt;span class="n"&gt;pinned&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nf"&gt;run_pip_compile&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;          &lt;span class="c1"&gt;# solve once (slow)
&lt;/span&gt;    &lt;span class="n"&gt;cache&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="n"&gt;cache_key&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;pinned&lt;/span&gt;

&lt;span class="c1"&gt;# Only install what's actually missing
&lt;/span&gt;&lt;span class="nf"&gt;install_missing_packages&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;pinned&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;No extra resolver runs. No unnecessary &lt;code&gt;pip install&lt;/code&gt; calls. Just &lt;strong&gt;remember the plan, then do only what's needed&lt;/strong&gt;.&lt;/p&gt;

&lt;h3&gt;
  
  
  Does it work?
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;First run (or after requirements change):&lt;/strong&gt; ~45 seconds (resolve + install)&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Cache hit (no changes):&lt;/strong&gt; &lt;strong&gt;&amp;lt;2 seconds&lt;/strong&gt; (skip resolution, install only missing packages – usually nothing)&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;In my dev workflow, that 45‑second wait on every restart is now gone when dependencies are stable.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;But be real:&lt;/strong&gt; If you're actively editing &lt;code&gt;requirements.txt&lt;/code&gt;, you'll pay the price if not worse each time you change it. This hack shines when you're &lt;em&gt;not&lt;/em&gt; changing dependencies often, exactly my case.&lt;/p&gt;

&lt;h2&gt;
  
  
  What it won't do
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;Resolve conflicts – still uses &lt;code&gt;pip-compile&lt;/code&gt; for that.&lt;/li&gt;
&lt;li&gt;Make cold installs faster – first run is full price.&lt;/li&gt;
&lt;li&gt;Beat &lt;code&gt;uv&lt;/code&gt; in a speed contest - if you're starting fresh, just use &lt;code&gt;uv&lt;/code&gt;. It's faster and smarter.&lt;/li&gt;
&lt;li&gt;Warn you about version conflicts across modules – those will still surface at install time.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;It's a tiny caching wrapper for a specific modular workflow. That's it.&lt;/p&gt;

&lt;h2&gt;
  
  
  Try it if you're tired of waiting
&lt;/h2&gt;

&lt;p&gt;Standalone or try and use &lt;a href="https://github.com/jonas1015/chacc-api" rel="noopener noreferrer"&gt;ChaCC‑API&lt;/a&gt; (toggle &lt;code&gt;ENABLE_PLUGIN_DEPENDENCY_RESOLUTION&lt;/code&gt;) to see it in action.&lt;/p&gt;

&lt;p&gt;🔗 &lt;a href="https://github.com/jonas1015/chacc-dependency-manager" rel="noopener noreferrer"&gt;GitHub&lt;/a&gt;&lt;br&gt;&lt;br&gt;
🔗 &lt;a href="https://pypi.org/project/chacc-dependency-manager/" rel="noopener noreferrer"&gt;PyPI&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;What's your "I just want to cache this" story?&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;code&gt;#buildinpublic #pip&lt;/code&gt;&lt;/p&gt;

</description>
      <category>fastapi</category>
      <category>python</category>
      <category>opensource</category>
      <category>software</category>
    </item>
    <item>
      <title>Building ChaCC-API: A personal journey from 2023 to today</title>
      <dc:creator>Jonas G Mwambimbi</dc:creator>
      <pubDate>Fri, 13 Mar 2026 08:15:29 +0000</pubDate>
      <link>https://dev.to/jonas1015/building-chacc-api-a-personal-journey-from-2023-to-today-2oj9</link>
      <guid>https://dev.to/jonas1015/building-chacc-api-a-personal-journey-from-2023-to-today-2oj9</guid>
      <description>&lt;p&gt;I'm excited to share a project that's been years in the making—ChaCC-API&lt;/p&gt;

&lt;p&gt;It's an open-source engine built with FastAPI that lets you run multiple modules without reinventing the setup every time. Think of it as a lightweight, modular backend that handles the heavy lifting so you can focus on building.&lt;/p&gt;

&lt;p&gt;What it does:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Provides a plug-and-play architecture for Python modules&lt;/li&gt;
&lt;li&gt;Comes with a dependency helper (chacc-dependency-manager) that accelerates pip installations&lt;/li&gt;
&lt;li&gt;Packaged for easy install via PyPI and Docker&lt;/li&gt;
&lt;li&gt;Born from a personal need to stop repeating myself&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;I'd love for you to check it out, star the repo if it interests you, or even contribute—whether it's code, ideas, or just letting me know how you might use it. Open source thrives on community, and this project is just getting started.&lt;/p&gt;

&lt;p&gt;Let me share journey behind it...&lt;/p&gt;

&lt;p&gt;I’ve always been fascinated by how software installations work. There was something almost magical about the idea that I could create something people could use, something tangible that would actually bring value to a community. But for a long time, that felt out of reach—too complex, too far beyond my skills.&lt;/p&gt;

&lt;p&gt;It started in 2023. I opened my editor and began a Django project. I had grand ideas, but I was also overwhelmed, inexperienced, and easily distracted. The code sat there, mostly untouched, for months.&lt;/p&gt;

&lt;p&gt;Then, around July 2025, something clicked. Maybe it was the extra time, maybe it was the confidence I’d gained from other projects, or maybe it was the fact that AI tools had made experimentation so much faster. I picked up that old repo and started over—this time with FastAPI.&lt;/p&gt;

&lt;p&gt;I wanted to build a single app, but soon a question crept in: Why should each app be siloed? Why can’t I build an engine that runs installable modules, so I never have to repeat the same setup and functionalities again? That question sparked the core idea behind ChaCC-API.&lt;/p&gt;

&lt;p&gt;Inspired by tools like &lt;a href="https://vman3.vatools.net/docs" rel="noopener noreferrer"&gt;VMan&lt;/a&gt; which I am part of developers and &lt;a href="https://openmrs.org/" rel="noopener noreferrer"&gt;OpenMRS&lt;/a&gt;, I decided to build something for me, a way to package and share modules without reinventing the wheel every time. Along the way, I hit a few snags that led me to create a small helper library: chacc-dependency-manager. It’s really just a pip accelerator, not a full-blown dependency manager, but it solved the immediate problem and taught me a lot about packaging.&lt;/p&gt;

&lt;p&gt;Now, here we are. ChaCC-API is live—new, not yet battle‑tested, and paired with a single module that’s still under active development. But it works and I’m proud of that.&lt;/p&gt;

&lt;p&gt;The screenshot below shows part of the commit history—you can see the long gap, then the burst of activity since last year. Every commit represents a small win, a moment of clarity, or a bug I finally understood. With help of AI tools, I have learned and done a lot that would've taken me years of back and forth.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F3rtk23xl5q61bfsx9rtj.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F3rtk23xl5q61bfsx9rtj.png" alt=" " width="800" height="507"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;If you’re curious, resources are here:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;a href="https://github.com/jonas1015/chacc-api" rel="noopener noreferrer"&gt;ChaCC-API GitHub repo&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://pypi.org/project/chacc-dependency-manager/" rel="noopener noreferrer"&gt;chacc-dependency-manager on PyPI&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://pypi.org/project/chacc-api/" rel="noopener noreferrer"&gt;ChaCC-API on PyPI&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://hub.docker.com/r/jonas1015/chacc-api" rel="noopener noreferrer"&gt;ChaCC-API on Docker&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;This isn’t a product announcement, it’s just me saying: I built something I always wondered about, and that feels really good.&lt;/p&gt;

&lt;p&gt;If you try it out, have ideas, or want to contribute in anyway, I'd genuinely love to hear from you. Let's build something together.&lt;/p&gt;

&lt;p&gt;#personalachievement #opensource #fastapi #python #learningjourney&lt;/p&gt;

</description>
      <category>fastapi</category>
      <category>python</category>
      <category>opensource</category>
      <category>ai</category>
    </item>
  </channel>
</rss>
