My profile picture

A little corner of the internet ☕

Welcome to my personal TIL journal, where I share small discoveries, technical gotchas, and opinions from the world of software engineering. Expect bite-sized reads about Python, Java, cloud infrastructure, and all the little things that make us better developers — one rabbit hole at a time.

☕ AI Isn't Going Back in the Box
☕ AI Isn’t Going Back in the Box ☕ Not a passing curiosity I don’t think AI is going away.
🐍 Python: `is` vs. `==` — Same Value, Different Object
🐍 Python: is vs. == — Same Value, Different Object Two lists contain exactly the same elements. You compare them, and Python says they’re equal. Then you use is, and Python says they’re different. Is Python contradicting itself? Nope. You’re asking two different questions. The discovery: Equality isn’t identity Take a look: first = [1, 2, 3] second = [1, 2, 3] print(first == second) # True print(first is second) # False == asks whether the objects compare equal in value. For lists, that means they contain corresponding equal elements.
🧳 Git stash: I said everything!
🧳 Git stash: “I said everything!” You have to switch branches. You run git stash, expecting a pristine working tree. Your edited files disappear. Your brand-new file stays right where it is, staring at you. Git isn’t being passive-aggressive. You just didn’t ask it to stash untracked files.
☕ Java records: immutable-ish, like a chocolate shell
☕ Java records: immutable-ish, like a chocolate shell Java records are lovely. Less boilerplate, clear intent, and no 47-line class just to carry a name and a list. But there’s a small catch: a record doesn’t automatically make everything inside it immutable. 🧠 The plot twist public record User(String name, List<String> roles) {} The record’s component fields are final. But if roles refers to a mutable ArrayList, that list can still change.
🏃 GitLab CI: cache is not an artifact
🏃 GitLab CI: cache is not an artifact You made your pipeline faster with caching. Beautiful. Then another job needs a compiled file, the cache doesn’t contain it, and suddenly your pipeline is doing interpretive dance. Let’s separate two jobs that look similar but aren’t.
🪣 Amazon S3: deleted… or just hiding?
🪣 Amazon S3: deleted… or just hiding? You delete an object from an S3 bucket with versioning enabled. It disappears from the usual view. You celebrate. The data is gone. Except S3 may have just put a tiny digital sticky note on it saying: “Don’t show this one.” 🧠 The principle In a versioning-enabled S3 bucket, a normal delete request without a version ID typically creates a delete marker as the current version.
🥫 Spring Boot: stop blaming application.yml
🥫 Spring Boot: stop blaming application.yml The app works locally. In staging, a feature flag is wrong, the port is unexpected, or the service is calling an endpoint nobody remembers configuring. You open application.yml. It looks perfect. Time to interrogate the YAML? Not yet. It may have an alibi. 🧠 The principle Spring Boot can read configuration from several places: configuration files, environment variables, Java system properties, command-line arguments, and more.
🐍 Python dataclasses: the list that wanted roommates
🐍 Python dataclasses: the list that wanted roommates You create two objects. You update the list in one. Somehow, the other object knows about it. Congratulations: your objects are sharing. Unfortunately, nobody asked them to. 🧠 The tiny trap Python’s ordinary class attributes can be shared between instances. Dataclasses protect against many mutable-default mistakes by rejecting unhashable defaults, including a plain list, in current Python versions. So this raises a ValueError:
🍱 Terraform state: the file you shouldn't casually commit
🍱 Terraform state: the file you shouldn’t casually commit You avoided hardcoding a password in Terraform. Nice. You added sensitive = true. Even nicer. So the secret is safe now, right? Well… not necessarily. 😬 🧠 The principle Terraform state tracks managed infrastructure and can contain resource attributes and sensitive values. Terraform plan files can also contain sensitive data. Marking a value as sensitive helps redact it in certain CLI and UI output. It does not, by itself, stop Terraform from storing that value in state or plan files.
🚀 GitLab CI/CD: Stop Waiting for Jobs You Don't Need
🚀 GitLab CI/CD: Stop Waiting for Jobs You Don’t Need Your application builds in two minutes. Unit tests take three. A static analysis job takes another four. Unfortunately, your deployment doesn’t need to wait for all three jobs to finish. It only needs the build and tests.