HN user

fizzbatter

798 karma
Posts2
Comments343
View on HN

It's worth it, imo. I was in your boat a few months back and hated every minute of it. With that said, i'm still not 100%. I semi-regularly see syntax that makes me go "Wat is what!?", but then i sit for a moment and understand it. Rust introduces a lot of visual baggage and that seems to cause me syntax blindness.. not enjoyable.

Unfortunately though, i'm back on Go. I want to be on Rust, but i had to pick a language for work and i can't ask my Team to go through what i did. Rust, despite the safety, is too unnatural for our larger codebase.

Luckily i think Rust has seated itself as the language we will use if the need is truly there. Unfortunately though, not everything.. just the specific things that need it.

I can't wait for someone to write a great book on Nix. I was so lost in it. I had it running on my home server, and needing to compile my own things because of what Nixpkgs lacked was a constant struggle.

It was a very frustrating experience. A frustration which was led by the fact that i could tell how powerful Nixos was - if only i could grok it.

If you need more complex logic, you simply wouldn't use `try!()`. Try! is intended for those `if error then return` checks, just like with Go's `if err != nil { return err }`.

If the error needs to be checked for a specific type (like a timeout) and then retried X times, you don't use the simple `if err != nil {...}`, you hand write something:

    let barRes = try!(foo()).bar();
    match barRes {
      Err(MyError::Timeout(_)) => // .. some retry code
    }
Note that the above code is woefully incomplete (i'm not checking all possible match values, for example), but it should give you the gist of the idea.

edit: Man, the guy (or wo-guy) has a problem and we all pounce :)

Seven years of Go 10 years ago

plus it can catch things compilers don't, such as null pointer exceptions.

Note, that it depends on the language. In the case of Go, yes. In Rust? Definitely not.

Seven years of Go 10 years ago

Besides, Go is not any safer than C when it comes to data races. I care about those a lot too.

Agreed. It may be safer in the realm of "oops i forgot to free memory", but i've had more panics than i could count in Go.

Seven years of Go 10 years ago

Not only that, but there's simply no guarantees. You can abuse a function in any way you see fit in Python, and the only one that suffers is your runtime sever :(

Optional types in 3.5 look awesome - but i don't want to lose duck typing. I want Go-interfaces in Python.

Seven years of Go 10 years ago

I don't know how, but frankly i'd love to eliminate all simple panics. Nil pointers and channels seem two big culprits, offhand.

Granted, i left out nil pointer/interface panics because it seems unrealistic given how difficult it was for Rust to get rid of nil pointers. I'm not sure Go 2.0 could do it and still be considered Go.

Seven years of Go 10 years ago

Type safety mainly, i think. Performance is a definite concern, but they have a lot of internal applications and the stability of them varies. I offered up that less dynamic languages would provide more speed and reliability to boot.

I know Python got types in 3.5, though i'm not sure if it has Go-like Interfaces (Traits in Rust). If not, i think it really should.

I do firmly believe they'll be quite happy with Go though. Rust, not so much.

Seven years of Go 10 years ago

I had to pick something i was familiar with too. We need this on a shorter timeframe (when is that not true? haha), and evaluating a language is hard.

As it is, this was a partial reason against Rust for me. After my time learning Rust, i'm still not 100% confident in my ability on it. My lack of experience and thusly productivity-hit is a real factor i had to calculate. Moreso with the rest of the team.

With Scala/etc i would be learning it new myself, and it was a gamble i wasn't going to take. Especially because our application is not intensive to specific problems that some languages excel in (concurrency, etc).

I'm sticking my neck out choosing a language, so i wanted to be quite sure i make the right choice for us. Well, as best i can - i am new in this shop after all.. i hope i made the right one :)

Seven years of Go 10 years ago

So, i was a Go developer for ~4 years, then for the last 4 months or so i've been learning and using Rust. The pure joy of some things with Rust was astounding.

Now, i joined a new job and they're in need of a new language for some backend tasks - the choice was mine. Rust or Go? The backend tasks were heavy API servers - nothing amazing, we don't do groundbreaking work. Python was their existing language, but they weren't too happy with it.

For weeks (literally) i mulled it over, i really really really wanted to use Rust. Rust gives me a peace of mind that Go never came close to. Unfortunately, Rust does not fit the development speed nor developer experience[1] that this shop has.. and i really felt Go would be the best choice for this place.

My point to this post isn't to make a Rust vs Go comparison.. but rather, a wishlist for the hopefully eventual Go 2.0. I have no idea if/when that will ever be made.. but i hope it will, and i hope they adopt some things from Rust.

1. Channels without panics. Channels are awesome, but Go's design of them means that you have to learn special ways to design your usage of channels so that it does not crash your program. This is asinine to me. So much type safety exists in Go, and yet it's so easy for a developer to trip over channels and crash their program.

2. Proper error handling. I love error checking - i love it in Rust especially. It's very explicit, and most importantly, very easy to check the type of things. Recently i was reading an article about Go errors[2] and it made me realize how messy Go errors are. There are many (three in that article) ways to design your error usage, and worst of all your design doesn't matter because you have to adapt to the errors returned by others. There is no sane standard in use that accounts for the common needs of error checking.

3. Package management. It's a common complaint, i know. But Rust & Cargo is so excellently crafted.. Go just got it wrong. Recently i've been using Glide, and while it's a great tool, there is only so much it can do. It's a tool built to try and put some sanity in a world where there is next to no standardization. We need a Go package manager.. hell, just copy Cargo.

4. Enums. My god, Enums. Such a simple feature, but so insanely welcome and useful in Rust.

You'll note that i didn't list Generics. I know that's high on peoples list, but not mine. To each their own.. please don't start a holy war. (this is likely due to me using Go for ~4 years. I'm quite comfortable without Generics)

[1]: By experience, i mean what they desire/expect. They're a Python shop after all, i didn't want to make a choice that would cause them to spend weeks/months feeling unproductive. [2]: http://dave.cheney.net/2016/04/27/dont-just-check-errors-han...

edit: minor text fixes.

Also, beyond what Karunamon mentions, i want to scan my network, my IoT devices, etc.

Besides, virus scanners are heavy and ugly, i've always hated them. Sure, it's nice to have monitoring of a breech, but why do i have to sit with holes in my security waiting for a breech? Some virus scanners try to monitor downloaded files or weird behavior etc, but i'd much rather scan my computer for holes, than things that have already exploited the security vulnerabilities that i had open.

Sorry, not trying to be harsh. If we have the ability to manually paginage, that would be enough. As it is, it would take me a long time (30m? no idea, honestly) to get to the bottom request on my trackpad.

I want to use the service, but seeing as i can only view the first dozen pages or so with any sanity, it basically makes it impossible.

On this note, i wonder if automated tools like this will become more commonplace. I know next to knowing about security[1], but i'd love for there to be some sort of self-updating simple service i can run that constantly updates and checks my router, home servers, IoT devices, all ports, etc. for known exploits.

Surely a lot of this stuff can be automated. The simpler the tool the better - a single binary would be great. Is this a pipe dream?

edit: I feel like part of the problem would be shipping all the exploits. Legal matters aside, it would at the very least mean having to code exploits for thousands/millions of things. Though, perhaps a pluggable/linkable framework for this security could be a sort of proof of work. Ie, whitehats could publish the exploits by writing the plugin.

edit2: I'm aware that this tool is sort of what i'm talking about, but this mainly focuses on a single unix machine, right? Nor does it support windows. I wonder why we can't just make this ultimately simple? Ie, single binary?

[1]: Well, i know enough to know how little i know.. which is nearly nothing heh.

Good god that's a frustrating UI. Am i blind or is there no meaningful way to find a company you're interested in? Ie, a search.

I used the alphabetical list, but scrolling through what seems like thousands of companies is a bit asinine. What am i missing?

edit: This is bothering me more than it should, so i figured i would try to automate scrolling to the bottom of the page so i can try and find the company i wanted. Once opened devtools, i saw it making requests to an API, looks like i was on page 30:

    http://deathwatch.io/json/US-ALL-SORTED_AZ-30.json
So, i just started poking around the pages of that list. With that said... it seems to stop at page 79. Eg:
    http://deathwatch.io/json/US-ALL-SORTED_AZ-79.json
That works... but this:
    http://deathwatch.io/json/US-ALL-SORTED_AZ-80.json
Does not. It looks like page 79 is on the Cs of the A-Z listing.. hmm

I think the right answer would be to force reboots at the right time, but - and this is the technical challenge - ensure that you can bring the users environment mostly (almost entirely) back to normal. Eg, store memory states, bring everything that the user wants back as it was before the reboot.

That's likely a pipe dream, as apps do a bunch of complicated things - but it seems like a merger of security and UX. I'm not saying it's possible.. just that it seems like the best compromise.

So what? you don't have to innovate to be a success, that's where a lot of HNers get stuck imo.

Sure, i'm not calling Slack amazing - but i very clearly said i use slack, love it, pay for it and recommend it. I used Dropbox too.

I don't think anyone here is claiming Slack isn't a massive success. Nor that the product is any less great because it's not innovative. A comment like:

This time we are saying this after Slack has already established itself. :-]

seems to suggest "we" are somehow wrong.. but i'm not sure where. Is my above statement somehow wrong? Or are you simply linking success and innovation where as i am not?

Hate? Everyone i know loves slack. I love slack. I've used it for my last two companies for (~many) years now. That doesn't make it innovative though, imo.

I can't think of a single feature they've done that is innovative. Attaching a file to a message?. Searching history? These aren't new or special in any way shape or form.

What slack did far more than UI, was UX. Top to bottom, it's a very nice UX. It's why i love Slack.

There's no hate coming from me - i'm just a realist. Slack didn't do anything amazing. It just did things right. Which is unfortunate for all of us users, as it took so many years to do things right. Unfortunately for slack though, they showed what is a good UX.. how hard do you think it is to copy that UX? Not easy, sure, but the template is there. Spend some time copying Slack, and i think you can manage to make Slack.Clone.

For a year or so I smoked casually when i was a teen in the 90s (to look cool) with intermittent bouts of heavy smoking over days at friends homes/etc. Probably average ~1-2 packs a week. One day i just got bored and stopped. Never felt any withdrawal signs.

I'm not countering your point of it being addictive. I was so, so so lucky not to have been hooked by that at all. I don't know if i just didn't smoke enough, or what... but it's one of the few points in my life i feel like i made the right choice. Weirder yet, it wasn't even a choice.. i just sort of stopped.

Not sure about the last crash reports (the os froze until i force restarted it), but other weirdness are things like the keyboard going apeshit. Spazzing out like a variety of buttons are being held down. That's happened 3 times since updating, never before. Another one is all input not working, etc. Both keyboard/pad related though, i assume there's a wonky driver in Sierra but i haven't researched it (and frankly don't want to atm).

I'm not complaining/etc, just saying i'm not getting a crash report on the last two items - and i'm unsure about if i received one the times the OS actually crashed.

Clearly something, but no idea what. I only use a small number of apps (iterm2, neovim, chrome, spotify, etc). Spend most of my day in iterm2, and avoid using new programs because i prefer cli programs.

That is pretty!

I may have to give this a try when the time comes. By far the best looking Linux GUI i've seen yet.

I can't wait to see an a GUI layer made for NixOS though. I really want to be done with stateful OSs, NixOS is so tempting.

Fwiw, i sort of like that. I understand it really sucks not being able to replace chips, especially something as simple as adding RAM, but i've not really seen a super compact laptop also allow me to replace RAM easily. My Macbook Pro Retina is quite compact, and it's proven to be a really important trait.

If someone makes them as compact and replaceable i'm on board, i just haven't seen it. Not saying it's not possible of course :)

One nice thing though is that the "Pro" market for developers is mainly centered around Unix, not OSX. Sure, some devs might like OSX specific tools like a GUI for Git or some such.. but at its heart, most tools are Unix oriented, with plenty of crossover between OSX and Linux.

Sidenote, that is indeed a pretty app! If i was sure i was staying on OSX (probably migrating to Linux), i'd purchase this! Shame i never found it sooner. I use a combination of Todoist and a Pomodoro timer on my phone.