HNHacker News
TopNewBestAskShowJobs

jmconfuzeus

200 karma · joined April 6, 2021

Python (Django, Django REST Framework) and Javascript (Typescript, React) developer from Mauritius.

I'm available for work.

Find my website at https://joshkaramuth.com

submissionscomments
jmconfuzeus··on Ask HN: how would you explain how/when you use Jamstack to a python backend dev?
I'd never use Jamstack.

Why?

Because Jamstack is used to build websites.

Any websites can be built 100x faster and cheaper using Wordpress + Elementor or Webflow.

If you're a freelancer, you can charge clients the same amount of money for less work while also keeping them more happy.

How will they be happier?

Because Jamstack requires a CDN, a build pipeline, and headless CMS. Too many moving parts = less robust infrastructure and higher maintenance costs.

Wordpress on a VPS is a single moving part.

When should you still use Jamstack anyway?

If you like cocktail parties with other developers, mentioning Jamstack might get you some attention.

jmconfuzeus··on V 0.3
> performance of C on the web > Simplicity: the language can be learned in less than an hour

This sounds like a killer language. Gonna try it out on a small project.

Hopefully it lives up to it's promises.

Anyway, congrats on 0.3.

jmconfuzeus··on How I would sell OpenBSD as a salesperson
Should have asked him to drink pineapple juice before the meeting.
jmconfuzeus··on “Code” 2nd Edition
This is the book I used to teach myself basic CS back in 2010.
jmconfuzeus··on Ask HN: Which programming games helped you become a better programmer?
If you want to learn assembly or how computers work at a lower level, play TIS-100 by Zachtronics.
jmconfuzeus··on Ask HN: What game do you wish existed?
A game where you fight massive dragons in space in your spaceship.

I'm talking dragons like Rayquaza from Pokemon.

If someone doesn't build this then someday I'll learn some C++ so that I can build it myself.

jmconfuzeus··on Taskwarrior
I switched from Todoist to Taskwarrior a while ago and it's been great.

One thing I wish it had is a way to mark tasks as "Undone" instead of having to delete them. It's great for reporting and finding weak points in my schedule.

jmconfuzeus··on A database for 2022
That was a fun read but I'm missing something here. I've never worked on large scale systems and I don't understand why they didn't choose My or Postgre SQL.

Some comments say that it's because they're complicated but what exactly is complicated about them?

Can someone with more experience explain to me what would have happened if, for example, they used PostgreSQL from the beginning?

P.S Apologies if this is a stupid question.

Edit: Looks like I hurt someone's feelings in this comment.

jmconfuzeus··on Yandex warns of bond repayment and supply risks
I hope development on Clickhouse doesn't go south.
jmconfuzeus··on SPAs Were a Mistake
You seem to be mistaken about what SPAs are. Github is simply a traditional Rails app that uses Javascript to enhance client side interaction.

A ton of web apps provide data visualization features without being SPAs by simply using libraries like D3.

I don't know what kind of apps you're building but claiming that everyone needs to start using SPAs instead of traditional progressive enhancement with Javascript is not right.

jmconfuzeus··on SPAs Were a Mistake
The Basecamp guys created Hey which is a mail app not implemented as a SPA. It's probably the fastest mail app I've ever seen while delivering around 40kb of javascript.

If Hey is a toy app you then you must be working on some truly alien projects from the future or something.

jmconfuzeus··on SPAs Were a Mistake
Big tech companies love wasting money and developing a SPA is a good way to do that.

Whether users prefers SPAs or not is debatable. Amazon, Github, and Aliexpress aren't SPAs because poor usability will cause users to move to competitors. If Hacker news turned into a SPA, I guarantee that it would suck big time.

SPA developers seem to be living in a tiny bubble oblivious of simple solutions to simple problems.

jmconfuzeus··on SPAs Were a Mistake
Progress bars and previews are simply a matter of attaching an events to the http request and file input respectively.

When someone submits a form and navigates back, don't you just re-display the empty form?

If it needs to be a form bounded with the uploaded file (maybe as part of a wizard), then why not ask the server for it instead of storing client side state?

Maybe using Javascript without a SPA looks hard because you're trying to avoid storing state on the server as well as bypass native browser features.

jmconfuzeus··on Dango Views Cheatsheets
Same here. I find that FBVs are more explicit and easier to deal with. That's why it's easier to onboard junior devs in a project built with FBVs.

Many people say that CBVs is Django on Rails but Rails doesn't use multiple inheritance or complicated MRO.

jmconfuzeus··on Use of Google Analytics declared illegal by French data protection authority
For people interested in hosting their own Plausible analytics instance. Use this Ansible bundle[0] against your Debian 11 server.

It takes a few minutes to complete and you can start tracking visits in a privacy friendly manner quickly.

[0]https://github.com/confuzeus/ansible-plausible

jmconfuzeus··on The EARN IT act is back, and it’s more dangerous than ever
The return of Gestapo.
jmconfuzeus··on Jolie: A drop-in replacement of Django Admin
Using Bootstrap is a great idea because trying to work with the CSS that comes with the default admin when you're adding custom views is sucky.

But I don't think most people will use this instead of the default because the admin is only used by the internal development team anyway.

Django makes it so easy to add CRUD to models that using the admin doesn't make much sense in most cases.

jmconfuzeus··on Show HN: My free Ruby book (CC license)
This is one of the best Ruby books I've ever read. I like your DGAF attitude where you get straight to the point and aren't afraid to give opinions.

It's a shame that this post didn't get upvoted more.

jmconfuzeus··on Rich: A Python library for rich text and formatting in the terminal
I haven't thought about making it public because it's just a matter of using the get_url command to download the binaries into /usr/bin and then outputting a .bashrc and /etc/bash.bashrc that contains aliases for every command like "alias cat=bat".
jmconfuzeus··on Rich: A Python library for rich text and formatting in the terminal
I started to keep an Ansible playbook to setup everything for me. Basically, it replaces most of the core utils with modern alternatives like like cat -> bat, grep -> ripgrep, top -> htop, and so on.

That way, I don't have manually install everything for new systems or when I'm doing a clean install on one of my existing systems.

jmconfuzeus··on How to start a successful freelance business as a software developer (2017)
The last phrase was sort of a joke and I'm not sure whether I should feel guilty or not.

Anyway, what I've found is that people who speak out against "bad words" are quite toxic. It's obvious that autistic in this sense isn't the clinically diagnosed condition but in that of slang. If I say that you're like a pig, it doesn't mean that you go oink oink. And yet, educated people will take everything you say literally and turn into missionaries.

Reminds me of the time when the church destroyed pretty much every text on Greek philosophy simply because they said that the soul doesn't exist.

jmconfuzeus··on How to start a successful freelance business as a software developer (2017)
If you work full time for a company, you get your paycheck at a regular interval. If you don't get it, you can complain to your accounting department or to the government in severe cases.

If a client decides he's not going to pay you for whatever reason, he can just block you on Slack, email, and everywhere else. Sometimes you can use a contract but good luck executing the clauses when you're on the other side of the planet. Even if you're able to sue, it takes months or years and a massive amount of energy. You might even lose if the other lawyer's able to find any loopholes in your contract.

Personally, I think this is too much for a single person to handle. How are you going to have enough energy left to do actual creative work if you have to deal with all of that? If you decide to start an agency and have your own legal department, then it's another story. There are some agencies who derive the majority of their revenue from legal actions anyway.

jmconfuzeus··on Harmful Defaults in Django
It's highly unlikely that will you execute unnecessary queries from view code because usually you'll have a context like {"pizzas": page_obj.object_list}. You'll almost never execute something like:

  for pizza in pizzas:
      print(pizza.topping.name)
But you'll certainly do the following in templates:

  {% for pizza in pizzas %}
    <p>{{ pizza.topping.name }}</p>
  {% endfor %}
I also don't understand why you want to avoid 3rd party packages, especially if it helps you write better code.
jmconfuzeus··on Harmful Defaults in Django
Nothing I wrote is controversial. I explained my thought process at length but you flat out rejected everything without explaining why. I wonder who's creating controversy here.
jmconfuzeus··on Harmful Defaults in Django
That's the point. Instead of worrying about whether you're accessing a related attribute, join everything and evaluate the QuerySet before passing it to context.

You'll never have to worry about whether {{ pizza.topping.name }} is hitting the database ever again, especially, if you install django-zen-queries because it will raise an exception if you try to.

jmconfuzeus··on Harmful Defaults in Django
If you want to build highly interactive apps with React then you should consider django-graphene instead of DRF. REST wasn't designed for JSON apis.
jmconfuzeus··on Harmful Defaults in Django
Django's ORM is one of the best out there but you'd be surprised to know how many people don't know about things like prefetch_related.

There are whole DjangoCon conference talks that go in length into these features even though I find them obvious.

Makes you realize how many beginners the Django community actually has.

jmconfuzeus··on Harmful Defaults in Django
I agree. A warning should be the minimum because I don't see why anyone would consider hitting the database when accessing template context normal.
jmconfuzeus··on Harmful Defaults in Django
If my payment logic is getting too coupled, I can easily extract it because I use one migration file per model and separate code using regular Python packages.

I can easily extract the logic into it's own app if I need to publish it to PyPi for others to enjoy as well.

Of course, if you code is getting coupled, then you need to revise your design process.

jmconfuzeus··on Harmful Defaults in Django
I'm sorry you didn't find it useful. No need to dissuade others from reading it, especially beginners, because it will help them write better Django code.
← PreviousPage 3 of 4Next →