HN user

_odey

885 karma
Posts5
Comments234
View on HN
Ruby 4.0.0 Preview2 8 months ago

The NEWS link details a bit more:

https://github.com/ruby/ruby/blob/v4_0_0_preview2/NEWS.md

What is interesting to me is the `Ractor.shareable_proc` changes that solved a bug for a use case I was having. And in general fixes for Ractors make them more appealing to use right now, even though they have not removed the `Experimental` flag from them. They are still missing a built-in concurrency primitive like channels or a lock free queue; I'm curious what they will settle on, Ractor::Port is nice but not enough.

OK, so based on this video, I've turned on EasyEffects, added an Equalizer, set the input source to "Easy Effects Source" in the system settings, started playing pink noise, then tried to adjust the dials until the input looked closer to a horizontal line (it's very chaotic so that is hard to do).

As some sections of the video highlight it ended up needing to dip the mids and boots the lows and highs. This is my end result (so far, I'm probably going to tweak this continuously):

    Preamp: -1 db
    Filter 1: ON PK Fc 27.782795 Hz Gain -3.36 dB Q 1.7848856
    Filter 2: ON PK Fc 49.40557 Hz Gain 1.09 dB Q 1.7848856
    Filter 3: ON PK Fc 87.85691 Hz Gain 5.04 dB Q 1.7848856
    Filter 4: ON PK Fc 156.23413 Hz Gain 6.43 dB Q 1.7848856
    Filter 5: ON PK Fc 277.82794 Hz Gain 3.76 dB Q 1.7848856
    Filter 6: ON PK Fc 494.0557 Hz Gain -1.19 dB Q 1.7848856
    Filter 7: ON PK Fc 878.5691 Hz Gain -5.54 dB Q 1.7848856
    Filter 8: ON PK Fc 1562.3413 Hz Gain -3.96 dB Q 1.7848856
    Filter 9: ON PK Fc 2778.2793 Hz Gain -2.97 dB Q 1.7848856
    Filter 10: ON PK Fc 4940.557 Hz Gain 0.3 dB Q 1.7848856
    Filter 11: ON PK Fc 8785.69 Hz Gain 4.35 dB Q 1.7848856
    Filter 12: ON PK Fc 15623.413 Hz Gain 8.7 dB Q 1.7848856
There's also an Output amp of -2.5dB that does not appear in the export for some reason.

TUXEDO InfinityBook Pro 15 - Gen10 - AMD Laptop Speakers.

It does make a positive difference (why don't they teach us this in school? ;) ). Please note I am music illiterate.

EDIT: it looks like changing the input source has no actual effect, just need to make sure the internal microphone's volume is not muted, and have to keep system setting window open while doing this, maybe the microphone is no longer on when the window is closed?. Linux is weird sometimes.

Congratulations on your release!

Just a few questions:

1. I've never felt the need to use anything else apart from ruby's Net::HTTP, while I see every project I've worked on in the past add in stuff like faraday or httparty for doing JSON REST calls. Apart for the convenience aspect of it in terms of lines of code, is there any advantage for me to use your gem in such cases? (for example performance?)

2. I'm confused as to why you would need to do something special for fibre aware scheduling. Is it the case that ruby considers anything traversing into C world as "CPU bound" even when it sits idle and you need to instruct it otherwise?

3. How does it behave with ractors? I mean does it work called inside a ractor or when I'm initialising a "client" object in the main body, then trying to pass it to many ractors for them to use it in parallel. Prior to ruby 3.4 I've had issues even trying to use `pp` inside a ractor so I'm not expecting miracles, just curious how things are progressing in that area.

This is used for scenarios where you don't want to hardcode port numbers, like when running multiple projects on your machine at the same time.

Usually you'd have a reverse proxy running on port 80 that forwards traffic to the appropoiate service, and an entry in /etc/hosts for each domain, or a catch all in dnsmasq.

Example: a docker compose setup using traefik as a reverse proxy can have all internal services running on the same port (eg. 3000) but have a different domain. The reverse proxy will then forward traffic based on Host. As long as the host is set up properly, you could have any number of backends and frontends started like this, via docker compose scaling, or by starting the services of another project. Ports won't conflict with eachother as they're only exposed internally.

Now, wether you have a use for such a setup or not is up to you.

Just tried it, I can write an email from one of my addresses: something@example.pro, other@example.pro, another@example.pro.

But not from an alias: something+johnny@example.pro, other+spoon@example.pro, another+kettle@example.pro.

Addresses are limited in number, 5 on my plan. Aliases are unlimited.

For the second, they've already implemented a feature on their web client to download emails locally so you can search in the body of the messages.

See: https://proton.me/support/search-message-content#the-index-o...

1. I can't write an email from an alias. For example I can't send an email from something+yourservice@example.pro. This is possible from Thunderbird using their bridge, but not from their email app on Android. I can reply to an email and it will preserve the alias, but I can't write one from scratch.

2. Emails are not downloaded locally on Android so I can't access them when internet is not available.

These 2 have been consistent issues for me over the 3 years I've used them, and when I've contacted their customer support about it I was told they have no intention of fixing them.

The optimal way to use linkedin is to add as many people as possible from as many companies as possible that you're interested in. This way, when you want to apply for a job at any such company you have people already working there whom you can message directly and ask for a recommendation.

Just don't forget to unfollow everyone you connect with as well... there's only so many times a man ca read stories of how the dog was the CEO all along...

I don't use copilot but Claude integrated in Spacemacs through gptel.

On difficult things (new conceprs I don't already know): -100% efficiency. I just end up reading the manual/code and figure out things by myself.

On day to day things: +20% efficiency, mainly because it's a faster search/reminder.

On simple things (like boilerplate): +300% efficiency. It eliminates the tedious, boring bits for me so I have more time and brainpower to focus on the first category.

How I reached these numbers? gut feeling.

How I get consistent results? I add project files as context and then write as detailed prompt as I possibly and reasonably can (this does take time). Rubbish in => rubbish out, so it's important to prompt well. I've found out that I need multiple successive prompts to get good results with refinments, rewriting in place always gave me poor results.

Overall, it's a boost but since nowadays I tend to spend my time in the first category mainly, I don't end up getting that much out of it. The 10% people claim seems right to me.

I guess I'm more motivated to do the boring bits as I'm not the one actually doing them, just reviewing, and they fly by faster, but how do you even quantify that? enjoyment points?

Personally I preffer to use minitest and use dependency injection rather than the magic "allow to_receive and_return" parts of rspec. This makes my code more reusable.

But don't get me wrong, I won't refuse using rspec if it's already set up for a project, just wish it wasn't the go to default. I do believe the ruby + rails code people write would be better architected and more reusable with minitest + D.I. rather than rspec.

A note on one of the changes: "New package EditorConfig. This package provides support for the EditorConfig standard..."

Honestly the only reason to use this, and don't get me wrong, it's a huge reason, is to ensure windows users don't add CRLFs in their commits, and mess up diffs. Set `end_of_line = lf` and you're done.

`charset = utf-8` and `trim_trailing_whitespace = true` are also nice, but not as disruptive as `end_of_line`.

The other (indentation related) functionality should honestly be handled by language specific linters instead, as they can be syntax aware and allow for better control. I always disable those in practice.

This is the CLI tool to use during CI: https://github.com/editorconfig-checker/editorconfig-checker

Once upon a time I worked at an outsourcing company called Endava, in Bucharest. I was one of the "benched" engineers (basically hired as an Erlang engineer and kept around without work to be available once the client needed me, so I could jump in immediately; this is how they operate).

One of the guys I had lunch with, outside of my project's team (the aquarium as it was known) told me the story, that they had a new project, the client gave them the archive of the code, but even though they requested Gitlab access, they have not received anything for 2 weeks and they were tired of copy pasting files in between their laptops.

What I did was to install a Linux VM on one of their laptops, set up a bare git repository in there, showed how to use the domain name associated with their laptop on the internal network as a git remote, and have them use it as a "local" git setup. They loved it!

I'm really proud of that moment :)

EDIT: this might not be 100% local, and you still technically have a server (the VM), but is close I think. I do use a local git with a bare repo in my ~ that is backed up to a USB stick for throwaway projects sometimes.

Automatically delete new accounts that have not verified their email within 24h.

Automatically delete verified accounts that have not made a purchase in the first month.

Automatically delete accounts that have not generated a "lead" in the first year.

Replace "lead" with whatever makes sense for your system.

Also maybe put Cloudflare WAF on your signup flow and set it to a high security level.

"From the moment I understood the weakness of my flesh, it disgusted me. I craved the strength and certainty of steel. I aspired to the purity of the Blessed Machine.

Your kind cling to your flesh, as if it will not decay and fail you. One day the crude biomass that you call a temple will wither, and you will beg my kind to save you. But I am already saved, for the Machine is immortal…"

This is basically what was going through my mind while browsing this website ;)

Your child is burnt out, potentially depressed, from 12 years of continuous, unrelenting school work with unnecessary, overly strict parenting from your side. They don't need an internship, they need a hiatus, and especially the acceptance from your side that doing this is not a failure and that you support them in their recovery.

Luckily for me, I went through my "World of Warcraft (private servers of course)" phase in highschool so by the 2nd year of university I had enough time to get it out of my system and gain back the energy to focus on internships and my career. Other people I know that went through this later in life (World of Tanks, League of Legends) did not have the span of time necessary to recover and they ended up dropping out or needing to repeat a year.

What I needed really, right after highschool was a year off, and I mean really "OFF". No pressure, no expectations, just recovery. Unfortunately, many people don't really grasp the concept of mental health. Neither me nor my parents knew about mental health as a concept at the time, so it was pure luck that I got burnt out early and had time to adjust (4 years) before the last year of university where consequences would have been way bigger.

iTerm2 3.5.0 2 years ago

"- Clipboard content reporting via control sequence OSC 52 is now supported, but requires user consent to enable."

This pairs well with the recently released neovim 0.10 support for OSC 52 to interact with the clipboard.