Better HN
topnewbestaskshowjobs
Log inSign up

hivacruz

274 karma · joined Dec 22, 2017 (8y ago) · 109 submissions

Submissions

comment 2mo ago · link · parent

I recently upgraded an old website[1] stuck on Rails 4.2 / Ruby 2.4 (yeah, I know) to Rails 8.1 / Ruby 4.0 and it's still awesome as it was in the first days of Rails 2.3 back in the days. Such a great framework and language to work with!

railsdiff.org was really helpful to upgrade in addition to the official documentation, especially now with LLMs that can process all these text and assist you in the process.

[1]: https://news.ycombinator.com/item?id=49587692

2.

Show HN: Whatthemovie.com, a movie-still guessing game(whatthemovie.com ↗)

4 points · by hivacruz · 3mo ago · discuss

3.

Kiji Proxy: Detect/mask private infos in requests to AI services(github.com ↗)

1 points · by hivacruz · 6mo ago · discuss

comment 10mo ago · link · parent

I do the same. I was thinking about creating read-only kubeconfigs for him to make sure it can't do bad stuff but with a good SKILL.md, it works perfectly.

comment 11mo ago · link · parent

I “learned” to code in Visual Basic 6 to create programs mainly for AOL chat rooms (games, etc.) when I was a kid. I was more of a script kiddie than anything else, but I got hooked pretty quickly. Good times!

comment 1y ago · link · parent

I don't think it is "focused" on the JSON part of Redis, they have added a lot of commands from Redis, not only JSON. They are also working on storing vectors too for instance.

As for the drivers compatible, if you mean "clients", in our case we use the official Python Redis client with Kvrocks and it works perfectly with the commands we use.

comment 1y ago · link · parent

We use it for a year now in production and so far so good. We couldn't handle anymore having huge instances with a lot of RAM to hold data in Redis.

It looks like a normal database to me: disk storage for most of the data, and some cache in memory to speed up read queries. Everything is customizable.

I'm still waiting for a nice way to deploy it in a Kubernetes cluster, like a Helm Chart to easily setup a cluster with primaries and replicas. Also, the lack of keys eviction like LRU is problematic for us in some cases, it would be a nice addition.

comment 1y ago · link · parent

I guess a senior engineer might be "linked" to a single kind of tasks (backend, frontend etc) while a staff engineer has knowledge in a lot of domains and can be the "bridge" for projects that need people from many different teams

comment 1y ago · link · parent

Instead of taking a image every 5 seconds from the video and embed it, you could detect when there are enough changes between frames to decide to embed or not. One frame, one scene, one vector.

For instance, Ffmpeg can do that with the filter `select=gt(scene,0.3)`. It selects the frames whose scene detection score is greater then 0.3 (the scene change detection score are values between 0 and 1).

https://ffmpeg.org//ffmpeg-filters.html#select_002c-aselect

comment 2y ago · link · parent

Did you do use the same method, i.e. split by chunks each article and vectorize each chunk?

comment 2y ago · link · parent

PHP is a great language to learn OOP, classes, interfaces, abstract classes, traits, managing dependencies and unit tests. I'm not using it anymore but I learned basically everything with it a decade ago. Thanks PHP!

comment 2y ago · link · parent

How does it compare to Kvrocks, which use RocksDB as the storage backend too?

https://github.com/apache/kvrocks/

comment 2y ago · link · parent

Not affiliated (not my first comment about this) but we are using KVRocks[1] for now at work, which is based on RocksDB by Meta and it works nicely. Developers are nice and reactive and the Redis commands support is large.

We picked this project because of our RAM usage that was exploding with Redis.

The only downside for us right now is the Kubernetes support. There is an operator and a controller being made but no Helm Chart yet to deploy Kvrocks with master and replicas easily. That will be awesome.

[1]: https://github.com/apache/kvrocks

comment 2y ago · link · parent

For a few recruitments, we asked the candidates to create a front app like this with React. It was quite nice as we could quickly see how they use the library, what they know etc.

Simple app but funny game.

comment 2y ago · link · parent

As an alternative YouTube Front-end, there is also Piped[0][1]

[0]: https://github.com/TeamPiped/Piped

[1]: https://piped.video

comment 2y ago · link · parent

Can't agree more. When you read the plot, it looks really strange but the movie is really worth it.

comment 3y ago · link · parent

For those interested in an alternative to Redis on disk, compatible with the Redis protocol, have a look on Kvrocks[1] which was recently accepted in the Apache foundation. It is based on RocksDB and works quite nicely for us.

[1]: https://github.com/apache/kvrocks

comment 3y ago · link · parent

They use the Twitter internal GraphQL endpoints.

comment 3y ago · link · parent

We use Kvrocks[0] at work. It is Redis on disk, powered by "RocksDB" (hence the name) and compatible with most of the Redis clients since it respects the Redis protocol. It was incubated by Apache earlier this year.

It works great and the development is really active.

[0]: https://kvrocks.apache.org

comment 4y ago · link · parent

The author made a post about it: https://kau.sh/blog/jekyll-footnote-tufte-sidenote/

comment 4y ago · link · parent

I understand that. And this is what I like in Black. But the single quotes thing is really up to debate. When you use it with other tools such as flake8 or pylint, you have to disable a bunch of things to make them work together because no one agrees on this point.

comment 4y ago · link · parent

IIRC, the -S only avoid single quotes to get switched to double quotes. What I meant was allowing Black to switch double-quotes to single quotes automatically.

comment 4y ago · link · parent

This is a great tool. I wish there was some settings to use single quotes instead of double quotes.

comment 5y ago · link · parent

Great software. I have been using it for a few years now (and even made a few themes for it). The WYSIWYG mode is really the best feature for me and what made me picked this editor. I don't like the "Live Preview" mode on most of the editors because it opens a new window or make the main window really large.

Something I like too (not sure if it exists somewhere else) is the ability to copy/paste an article (let's say from medium) directly in the WYSIWYG mode. You basically get your article just like it is being displayed on medium: h1 detected, paragraphs, bold etc. OOTB. Really nice.

comment 5y ago · link · parent

I thought HTTP 2 fixed the problem of multiple downloads of small files/dependencies?

The creator of Rails talks about it here: https://world.hey.com/dhh/modern-web-apps-without-javascript...

comment 5y ago · link · parent

I used this library to get familiar with Go. It is indeed very powerful and really easy to create a scraper.

My main concerns though were about testing. What if you want to create tests to check if your scraper still gets the data we want? Colly allows nested scraping and it's easy to implement but you have all your logic into one big function, making it harder to test.

Did you find a solution to this? I'm considering switching to net/http + GoQuery only to have more freedom.

comment 5y ago · link · parent

I like writing bugs. You learn a new thing every time you fix one of them.

comment 5y ago · link · parent

I thought I have started too many workflows in a short time and got temporarily restricted!

By the way, just discovered a nice library to test GitHub Actions locally: https://github.com/nektos/act

comment 5y ago · link · parent

I can't work now. I'm definitely an impostor!

comment 5y ago · link · parent

Use teddit.net, it works great
1234