HNHacker News
TopNewBestAskShowJobs

anonyfox

2,005 karma · joined August 7, 2013

https://anonyfox.com
submissionscomments
anonyfox··on Yandex open sourced it's BI tool DataLens
Since the discussion started in the comments already, I have a similar question: any recommendations for a solution (don’t care if OSS or not) that has the best UX for nontechnical people to assemble some data and reports anyhow? I have Salesforce, some mariadb/postgres and (optionally) hubspot as data sources.

I can buy or manually provision anything, no technical hurdles or policies from that side. My absolute focus is the raw UX for business people.

Suggestions?

anonyfox··on Strong arrows: a new approach to gradual typing
I have listed a few points here in the other comment: https://news.ycombinator.com/item?id=37596258

as a more general/subjective/emotional note:

The very pragmatic take on FP makes code in most cases so much easier to reason about. Immutability, no magic coming from some dark corner of the codebase unexpectedly, thinking in steps of data transformation from the get go, piping operator to make this visually pleasant, handling edge cases with pattern matches right at the function head level explicitly, ... and to have stateful stuff, there is OTP right on your fingertips with GenServer/Actor/ETS/... .

And a genserver basically is only just another module that implements certain callbacks and then gets spawned. Modelling some scenarios are are breeze with that. And when I feel like I need some better syntax for some exotic problem I am dealing with, I can bend and stretch my language constructs via hygienic macros right away.

And the whole experience is _extremely_ polished in terms of DX. docs, tests, doctests, interactive shell, a AOT-compiler, a JIT-runtime, and some very high-quality ecosystem bangers, like phoenix/livebook/membrane/boradway/Nx/Axon/... . Its like best of all worlds, and definitively the _very best_ choice for orchestrating stuff, which is a boon when you run into a problem you'd rather not use elixir for. Like building a native extension in rust/zig for some raw CPU task is a breeze.

Its not so much the individual feature (no matter which one) but the overall package.

anonyfox··on Strong arrows: a new approach to gradual typing
Maybe more like different layers could do different strategies? I can't even imagine what could happen to the BEAM itself if there are the same amount of ressources put on it like in our modern JS engines that have come a loooong way. Its already an amazing piece of tech in itself, but I wonder what an army of experts could do ontop of it.
anonyfox··on Strong arrows: a new approach to gradual typing
By this I mean taking the code logic snippets and slap a dedicated new liveview UI on it within your phoenisx app - which isn't too hard since the initial ui in the livebook is pretty bare bones. Yes its rebuilding the whole thing technically, but probably really quick to do
anonyfox··on Strong arrows: a new approach to gradual typing
absolutelt hard agree on livebook, but I think thats not an immediate thing every webdev needs.

but speaking from recent practice, it is laughably simple and kinda mindblowing for non-experts in this stuff. Like, I klick me a few smart cells to interact with external data and get a connection/data, write a few straightforward logic modules to do something, and a super simple form for users of this thing (like two inputs and a submit button, and an event handler) and I can eliminate a business workflow or report. I can call a dev into it ad-hoc to help with a code snippet like a liveshare-coding-session. And finally I deploy it to a bookmarkable URL with a password.

Maybe an hour worth of work, _including_ talking with people while fleshing this out in quick iterations as-we-speak.

I mean people kinde get how cool phoenix is for one reason or the other, but livebook is really killing it for me. It's hard to talk with business people about tech internals no matter how awesome, but its a different game with lightweight livebooks. If you also happen to have phoenix as your actual product/app, linking the livebook indeed is nice to directly call functions instead of rewriting those snippets in SQL... but the endgame here is when the livebook starts to become unwieldly due to increasing feature requests, it can be integrated into a phoenix app rather easily, since a dev starts out with working code to begin with (and can play with it interactively).

anonyfox··on Strong arrows: a new approach to gradual typing
I don't thinks that would be a helpful discussion right here. Any one point there might come someone who points at some external "solution" (package, tool, ...) that might also do the same feature in some way for X, ignoring the fact that there are lot of Y without that particular thing still, but leads into derailing the argument anyways.

Elixir (and esp. Phoenix for web dev) is more like the culmination of the best ideas and heavily draws/depends on the last decades of real-world experience. Most stuff isn't (or shouldn't) be surprising, but the point is that everything you might need for the vast majority of projects is right there, nicely packaged up into a unified nice thingy.

But to give you a few of _my_ top points:

1. Architecture and DX for complex interactions: there is no need to bring in supplemental infrastructure crutches (Redis, AWS whatever service, ...) in many cases to begin with. OTP, which is like a core library always available, already includes the building blocks for things like cache servers, application clustering and supervision strategies, ... .

2. Reliability and availability: this tech is the original one achieving the "nine-nines" of uptime record. To get an idea of how, https://www.youtube.com/watch?v=JvBT4XBdoUE this talked is packed and excellent, and also highlights a few things why it can achieve my point 1 above.

3. "SPA-like" interactivity with full server side rendering without all the pains of exposing/consuming a dedicated HTTP API in between, or overcomplicated nuances of rendering pipelines (also see react server components) to achieve SSR/CSR in a way that not sucks or is noticeably slow. Liveview is tried to be replicated in other stacks, but they don't come close in reality today or complicate the apps' infrastructure with additional crudges. And don't get me started on the integration testing story compared with SPA+Backend setups.

4. Agents/Message passing parallelism (not only concurrency, but also distributed!) at your fingertips, which makes modeling current "async problems" kinda trivial. OTOH, building something like a proper async-based web framework in rust is quite a pain in the ass, with lots of type fiddling needed, instead of doing the solution you actually want to deliver with it.

5. Some absolutely awesome takes on some typical libraries. Take the ORM options for javascript/typescript (all with severe tradeoffs, and analysis paralysis ontop). Take Rails' ActiveRecord with lots of magic and while great to get started becomes quickly bloated (iE fat models) in bigger projects. And then Ecto got it "just right" with slim schemas, changesets, and basically pure functions + pipelines. Any "model" can be used within new usecases by adding new changesets/validations explicitly and easily, there is no "general" validation right on the model level you have to tiptoe around, and starting If-cascades.

anonyfox··on Strong arrows: a new approach to gradual typing
I cannot support much in terms of money or time currently, but somehow I'd wish there are ways to speed this up.

Sure, sponsoring from big corps comes with their own problems, but maybe that would be an option? There are quite some that use Elixir (or BEAM in general) out there...

Idk what would be the best approach.

But I am very convinced that Elixir and the wider ecosystem (not only phoenix liveview) is (or could be) the very best "default" web app stack we have right now in general. It solves _so many_ problems of other comparable tech stacks right out of the box, one way or the other, and is the only one I've noticed a sentiment of pure joy from seasoned devs that also lasts well after the novelty wears off.

At this point it looks "only" like a number problem to become mainstream (again a number problem). No idea how to solve it, just felt I needed to share my thoughts as a data point here.

Like the type system here: I'd _kill_ to have this exact implementation today rather than _maybe in a few years_. And yes, I can draw comparison to Typescript, Rust and Haskell which I used for projects in the past. Its like combining the very beast ideas (and adding some more) into one awesome thing.

anonyfox··on Erlang/OTP 26.1 Released
While I agree with the sentiment, there are two superpowers in the mix for me (pun intended):

1. Erlang / BEAM itself as the runtim with lots of powerful capabilities (what you probably are talking about) - you need to know this stuff at some point to fully leverage the technology

2. Elixir the language (+ excellent modern tooling) ontop, which really helps to significantly speed up productivity/average code quality - I don't like to over-reductionist approach here, DX is also an important thing to consider instead of the raw foundation

anonyfox··on Notes on existential risk from artificial superintelligence
Risk ultimately is a statistics game. There is a certain percent chance of some defined outcome, in this case a bad one. And many factors change the numbers on a daily basis, most of them unknown in advance.

I, for one, gladly accept the risks of ASI, because also a great deal of rewards are on the table. Not to mention that some risks also can be avoided through ASI itself!

Not to mention that I would wholeheartedly support artificial life forms as the next evolutionary step of humanity - but this is probably very far future thinking.

anonyfox··on VCMI: Open-Source Engine for Heroes of Might and Magic III
Is there any good iOS port on HMM3 again? There was something many years ago that probably wasn’t maintained anymore for new iOS versions. Would gladly pay!
anonyfox··on Ask HN: How to do literal web searches after Google destroyed the “ ” feature?
confirmed (although I use ecosia instead of bing directly). Now its like:

semantic search + realtime needs = google;

raw searches is ecosia(bing)

and most needs are covered via GPT4 actually. Error debugging + code snippets, general interest explanations, arguing things, evaluating things interactively. Basically everything I don't need hard facts of the last 2 years for.

anonyfox··on Habits of top engineers
this sounds interesting to try for me. Software engineering alone wears off for me after a while on a project to the point I simply cannot type a single line for it if forced. Managament is where I am really good at coming up with ideas/plans/strategies but the day-to-day following-up (including staying calm and friendly in the face of very slow employees sometimes) also is soul crushing and depressing after a while. My sweet spot somehow is in the middle an hopping between projects, mentoring engineers and also doing my own projects on the side or even spearheading initiatives... sometimes.

What cycle times/scheduling works best for you? how do you deal with the dread of picking up a topic again after letting it go mentally?

anonyfox··on Phoenix 1.7 for Elixir: Edit a Form in a Modal
it does[1].

- A phoenix application basically can be seen as a "microlith": monolithic codebase (even with umbrella setups!) and during runtime there a lots of independent processes that scale over clusters of VMs, where partial failure doesn't neccessarily affect the rest. So no truly independent deployments of microservices, but most advantages of the pattern, without HTTP-API overheads or similar, since sending messages between processes is a natural thing to do anyways.

- Liveview extends that by connecting a client with the VM via websocket, where there is only a minor difference between receiving a message from another server process or from the client (handle_info vs handle_event). The data/state lives completely in the users' backend process, so much less cognitive overhead about getting data into the client, you actually don't even think about this topic. Also no JS blobs that get bigger with increasing amounts of pages/components or clever splitting + latency compensation of prefetching, and the SSR performance is spectacular, and also free (see the complexity of ReactServerComponents) and no thinking about the whole topic while doing LV.

- under demanding pressure, the VM behaves optimal for a web app actually. Every LV is its own process on the server, every "thing" ultimately lives in some process, and its all supervised by other dedicated processes that do automatic restarts/... in case of failure, sometimes called "self-healing". Erlang was the original system actually achieving the nine-nies of uptime. Garbage collection is also on a per-process level, not a global stop-the-world thing, with short-lived processes cleaned right away without the local GC kicking in. And the VM itself does aggressive preemptive scheduling. This translates into: quick http responses stay quick even under load, but long-running jobs run even longer when there is pressure - exactly what you want: not blocking visitors' experience with crunching jobs.

- the database story is exceptionally great, you have schemas and separate functions to do stuff with data (validations/...), not a coupled thing like ActiveRecord models - I can have different changesets/rules per usecase on the same schema easily. Can also be used for casting JSON responses, and supports embedding document-like structures (with schema/...) into postgres natively.

- many problems you would reach out for external services to solve have native built-in equivalents. IE you don't need Redis, since there is the built-in (D)ETS. which also is objectively better than redis for caching needs, since there is no serialization overhead between service boundaries, and native language structs are used for keys/values, not just strings, and it can be queried/matched with full power. When you know your full Elixir toolbox, your app becomes much simpler on the highlevel (architecture/infrastructure) and more convenient on the lower (code) levels.

- Everything[2] is packaged up (i believe) in an industry-leading level of polish and quality, from exhaustive docs, awesome testing tools built-in (ExUnit for liveviews is dramatically better to use than something like cypress and getting app configs right for testing modes and you have the fullstack integration testing level by default easily.

- the data processing/ML story is generally great and is quickly catching up to python levels, and the unique capabilities of the VM itself unlock tools like Broadway to build data pipelines to feed into things like ML models. Speaking of, some algorithms like NN have great native libs now, there is a adhoc integration with huggingface (bumblebee), and last but not least some things like evolutionary algorithms are great to design with OTP constructs.

- the language itself is as powerful as a lisp in practice, the only noticable exception being its not homoiconic so you need quote/unqote for macros and AST stuff, but also there are less brackets. But everything you see is a macro ultimately, even defmacro is a macro. create your own DSLs with ease if needed.

---

as a downside, deployment is more complex when you want to leverage the distributed nature of some native features, but you don't need to in general, you can also deploy it like any other ruby/django app iE with a dockerfile and loadbalance it traditionally. Also there is a learning curve in general, since all this stuff _looks_ alien for many devs not used to it, and there are features that don't exist at all in more mainstream languages.

---

[1] except for raw compute tasks, when even Nx doesn't cut it, but then there is rustler for native extensions which works reasonable well!

[2] except for liveview itself - the docs are there but cluttered over many places, and not really within phoenix itself but as an external lib, and there has been lots of changes over time.

anonyfox··on Phoenix 1.7 for Elixir: Edit a Form in a Modal
I recently started to only use liveviews for any page. Yes, I could do a simple controller/template combo, but then after some time comes the feature request for some interactivity, and I have to convert the page to LV manually. Or something like the global navbar needs some dynamic thing, and here you go: either embed a LV in the static page or... do nothing since all pages are LV to begin with. The overhead is pretty minimal IMO, a simple LV that does nothing is a few lines of module code, not much more than a controller route. And by standardizing this (no more deadviews), pipelines/plugs can be simplified, and live_session for seamless navigation becomes much better. Phoenix Deadviews render within a few MS, but still a live_navigate is snappier.
anonyfox··on Things I wish I knew before moving 50K lines of code to React Server Components
Thanks for sharing the Elixir love!

More people should do this openly I think, since it’s still vastly underrated and fellow alchemists seem to be too humble to evangelize!

anonyfox··on Things I wish I knew before moving 50K lines of code to React Server Components
Stop a second before you go into RSCs. Whatever you want to achieve ultimately is much easier/quicker/scalable done in real fullstack (or classic web-) frameworks!

Rails/Django/Laravel/… + Turbolinks/Htmx/… or even sprinkle some light clientside JS for fancyness.

Or go best-of-all-worlds if you happen to know Elixir/Phoenix.

But don’t continue the descent into RSCs, now matter how many people tweet about it. These folks with less than 10y industry experience will run into all the basic problems we had in vanilla PHP sites years ago, I even spotted react components with inline-sql-hooks already. This time with much accidental complexity overhead!

Stay sane instead, ship actual products quickly, and earn that lambo!

anonyfox··on Lie still in bed
Oh, I totally get your point. And of course habits require energy spending (but less and less over time). But with adhd it’s kind of different game.

Like a mental „erectile dysfunction“ - if you *really* are in the mood it can be done, but if not there is no way to force it. (Except for some pills.) it’s not a willpower issue to begin with.

anonyfox··on Divide your life into semesters, even when you’re not in school
Even though not asked for, maybe consider european cities, too, especially the bigger older ones.

They are not skyscraper-level breathtaking like many US cities and not as dense - but have lots of advantages (walkable, good public transport, rich cuisine, higher food quality in general, less homelessness or other social issues, … not even talking about working here with much more vacation/free healthcare/…).

Ultimately you mentioned museums - well Europe has stuff that is thousands of years old. Lots of stuff to see and discover. I personally like to go to authentic medieval festivals or viking meetups for example.

anonyfox··on ChatGPT Enterprise
Or maybe they got urged to offset more operational costs - and I would believe that companies already paying for Microsoft things Wille happily pay for OpenAI in addition just to be safe.
anonyfox··on Divide your life into semesters, even when you’re not in school
If that is your focus, over here (Hamburg, Germany) there also are real (mostly untouched) forests, which also include life. They are not extremely huge but at least many centuries old.

One is like 8min from my door, could even take a bus since there are stops on the edges.

anonyfox··on Divide your life into semesters, even when you’re not in school
there are cities with _lots_ of natural green space, water and thoughtfully gardened recreation parks, though.

Enjoying the transition to fall right now living in such a city.

anonyfox··on Federal study links testicular cancer to ‘forever chemicals’
The counter point is that the vast majority of produced stuff is absolute useless garbage no one actually needs, or a gazillion of ripoffs from each other. Consumerism is a plague not only for people but also for the environment.

I think we can see a „dry-run“ of some product launch, point out dangerous flaws, and repeat until something actually useful is proposed that is not some profit-extraction tradeoff that makes something else worse.

This is rather extreme by intention, the truth probably is somewhere between, but I think most people can’t see how a more regulated system can actually thrive much better than putting people into poverty death loops and destroying the planet in the process.

anonyfox··on Federal study links testicular cancer to ‘forever chemicals’
> that we allowed companies to just make

Isn’t this the default in America (and more countries, sure)?

I prefer the opposite (European) stance the companies have to prove beyond doubt the harmlessness.

(Or be strongarmed by the US or Fall to bribery like everywhere else… but at least there is trying)

anonyfox··on Live worm found in Australian woman’s brain
Have an upvote, still waiting for the Xbox launch, though.
anonyfox··on Live worm found in Australian woman’s brain
As a vegetarian, I also ensure to wash my food. Much less to worry about than meat, though.
anonyfox··on Lie still in bed
ADHD chiming in. That approach just doesn’t work when you have to actively spend nontrivial brain energy to even brush your teeth, every day. There is no such thing as a hackable routine, atomic/keystone habits, or „too lazy to stay on track“.
anonyfox··on Kellogg’s is going to war over Mexico’s nutrition label rules
not an american here. but pure carbs with nothing else (no fiber, vitamins, proteins, fats, ...) is just pure calories without nutrition value... except you're starving.
anonyfox··on Kellogg’s is going to war over Mexico’s nutrition label rules
nutrition labels are a lobbied-for scam. it compares products within _the same category_ against each other. Like, cereals against cereals, and boom: doesn't look too bad! The reality (cereals are pure carbs and not healthy whatsoever) is labelled over and simple-minded consumers think its better than it actually is and buy it.
anonyfox··on On to Elixir
As a Phoenix user, I Call out!

Something like the Django admin in phoenix would be like taking the actual USP of Django away … and it could even be real-time and collaborative by default :-)

anonyfox··on Why Tailwind CSS Won
I am a not-good-at-ui dev, meaning I _can_ build UIs pixel perfect if given some exact design files, but it is incredible hard for me to come up with things on my own. So whenever I build something that is not already defined fully by designers (like: most of the time), I have to use some UI component catalog like bootstrap and start assembling my UI based on the options there, at most I switch a theme file to something more fancy.

I basically was squarely the target group of bootstrap, and used it for lots of projects in all versions. I didn't actually care much about their technical progess (float, flex, css-grid, whatever), I just copypaste from the available widgets and add in my data.

Just LAST WEEK I learned that my favorite web framework (https://phoenixframework.org/) now ships with Tailwind preconfigured by default. I also heard good things about it from trusted colleagues. So, for the next big project I decided to jump in. Still I kind of have concerns: I need "typical components" like cards/tables/grid/... to be only a copypaste away; and I need to allow some designers be able to tweak the overall look and feel, roughly like a theming file where fonts/colors/... are defined at a single place. I hope it will be smooth after all these years of bootstrap and the "muscle memory" of how to compose pages with it.

← PreviousPage 8 of 24Next →