DEV Community

Cover image for I Published a Python Package in 2019. Revisiting It in 2026 Reminded Me of Something
Diksha Rawat
Diksha Rawat

Posted on

I Published a Python Package in 2019. Revisiting It in 2026 Reminded Me of Something

You know how elders always start with "In those days..." πŸ˜„

Well, consider this my version of that.

Because in 2019, building and publishing your own Python package wasn't something many developers around me were doing. There was no AI to guide you, no tools generating everything automatically.

You figured things out yourself. And when it finally worked, it meant something.

That little package I built back then made me genuinely proud of myself.
Revisiting it in 2026 brought a smile back to my face.

How It Started

Back in 2019, I was a few years into my career and preparing for technical interviews.

Back then, interviewers loved asking Python logic questions, not just to see if you could write code, but whether you truly understood how things worked.

While practicing problems, I noticed something interesting.

Python has packages for almost everything. But not for counting set bits in a range of natural numbers.

So I built one. πŸ˜„

What is a Set Bit?

A set bit is simply a binary digit that equals 1.

Example:

3 in binary = 011 β†’ 2 set bits
7 in binary = 111 β†’ 3 set bits

At this point you might be thinking, Why do we even need this? πŸ˜„

Honestly, I had the same thought later. But 2019-me probably needed it for something and decided to solve the problem.

My package counts set bits in:

  • a single number
  • or across a range of natural numbers

…with one simple function call.

Building it in 2019, No AI, Just Google

I figured everything out the hard way.

  • Python package structure
  • PyPI publishing
  • Documentation
  • Versioning

All through Google, Stack Overflow, and trial-and-error.

No ChatGPT.
No Claude.
No AI assistant.

Just curiosity, patience, and a lot of browser tabs. πŸ˜„

I wasn't a fresher building a toy project.
I was a working developer who noticed a small gap and decided to fill it.

And when the package finally went live on PyPI, I felt genuinely proud.

Maybe nobody would ever use it.

But that was never really the point.

Fast Forward to 2026

That little project stayed somewhere in the back of my mind.

So recently I went back to it.

Looking at the old code with fresh eyes, and with AI helping this time, I realised there were things I could improve:

  • missing input validation
  • no error handling
  • incomplete docstrings

So I cleaned it up and published v1.1.1 of:

setbitcounter-pkg πŸš€

What Revisiting It Taught Me

The code I wrote in 2019 wasn’t perfect.
But it was real.

I built something from scratch, published it, and moved forward in my career.

Coming back to it in 2026 reminded me of something important.

It reminded me of the version of myself who was curious enough to explore, patient enough to learn, and motivated enough to build.

Today we have AI that can help us build almost anything.
But back then, you had to really want to figure things out.

And that curiosity still matters.

Try It Yourself

Install the package:

pip install setbitcounter-pkg

Example usage:

from setbitcounter.countset import countsetbit

print(countsetbit(7))       # 3
print(countsetbit(1, 10))   # 17
Enter fullscreen mode Exit fullscreen mode

PyPI
https://pypi.org/project/setbitcounter-pkg/

GitHub
https://github.com/diksha-rawat/SetBitCount

Do you have an old project you’re proud of?
Drop it in the comments. I would love to see it! πŸ‘‡

Top comments (0)