News for hackers. Stuff that matters.

cyrusaf

Re:GC Fun at Twitch on Friday November 15, 2019 @09:33PM (#21550598)
The blog post is also available on Medium: https://medium.com/twitch-news/go-memory-ballast-how-i-learn...
Great article! I found the section on "GC Assists" very informative:

> You can think of this like a tax that your goroutine must pay for allocating during a GC cycle, except that this tax must be paid upfront before the allocation can actually happen.

Re:Go 2 Error Values draft implementation – planned for v1.13 on Wednesday December 12, 2018 @03:37AM (#18662319)
Sum types would add much needed compiler safety to returned errors and optional values. We often see nil pointer dereferences during runtime due to the usage of pointers as optional types.
It's very unlikely they store their passwords in plaintext. They were probably logging during login requests and didn't realize the whole request body was being logged. Can happen if you have a proxy/load balancer with logging enabled.
It's possible their truncate also restarted the sequence: "TRUNCATE TABLE users RESTART IDENTITY;"

https://stackoverflow.com/questions/13989243/sequence-does-n...

Although, I am confused about how sign ins created new users. When they say sign ins, do they mean new accounts?

This is not what happened. The tokens were mapped to user IDs and when people signed in, the db created new users which may have had the same IDs as old deleted accounts. When they restored the DB, these tokens pointed to other users and granted access to these other users' accounts. Quite an unfortunate situation. May have been mostly avoidable if UUIDs were used instead of incrementing IDs, but hindsight is 20/20.
Re:Twirp: A new RPC framework for Go on Tuesday January 16, 2018 @06:35PM (#16163943)
Hopefully these will be implemented soon by the community. Open source rules :)
Re:Twirp: A new RPC framework for Go on Tuesday January 16, 2018 @04:01PM (#16162537)
HTTP 1.1 + json support for twirp opens up a lot of doors too. It's easy for the browser to natively hit a twirp service without the need for large packages such as https://github.com/improbable-eng/grpc-web.
Re:Ask HN: What is your Golang web-dev tech stack? on Tuesday December 05, 2017 @02:00PM (#15854608)
HTTP: - gRPC for microservices - graphql for combining microservices for the frontend

DB: - dynamodb/psql depending on features. aws-sdk or base go sql package. - redis for caching. go-redis package.

Stats/logging: - statsd/graphite/grafana - sirupsen/logrus for logging

I usually write a wrapper for packages that will automatically report stats + logging.

I think you would be better off using more well known statistics for betting (ie. multivariate regressions, t-tests, etc..). These stats methods are less of a black box than ML (neural networks, etc..) so you'll be able to understand why they have chosen specific bets and you'll be able to tweak them easier.

ML is often just stats under the hood in most cases -- I think I am targeting neural networks specifically with this comment.

Re:Uber Paid Hackers to Delete Stolen Data on 57M People on Wednesday November 22, 2017 @02:53AM (#15755084)
In person I use a thumb drive. You could encrypt the credentials using PGP and send it to a coworker if they are remote.

Sometimes I just go on google hangouts and share my screen if I'm feeling lazy.

Re:Ryzen is for Programmers on Tuesday May 02, 2017 @01:18AM (#14244117)
I don't see this as a comparison between Ryzen and Intel. He compares a custom built PC with a 2017 3.6 GHz 8 core Ryzen to an older 2013 2.3 GHz 4 core i7. He could have replaced his Ryzen CPU with a similar priced intel processor and seen the same performance.
Re:EPA Science Under Scrutiny by Trump Political Staff on Wednesday January 25, 2017 @07:36PM (#13487675)
I think many would make the argument that not enough is being done environmentally and that more action needs to be taken. Cutting funding to the EPA and lifting restrictions are reversing the progress that we have made environmentally in the past couple decades.
Re:Teaching AI to race using NNs and genetic algorithms on Tuesday August 30, 2016 @05:59PM (#12394294)
I disagree about changing the track. It should be changed every iteration. If the track is not changed every iteration, the NN might develop to work in specific scenarios (only turning left for example) and when run on a different track, might fail miserably.
Re:Google launches voice typing in Google Docs on Thursday February 25, 2016 @05:44AM (#11173610)
I wouldn't be surprised to see it shipping with Chrome sometime in the near future.
Re:Unreal Engine 4.10 is Released on Thursday November 12, 2015 @02:20AM (#10551760)
butt stuff?
Re:Keep Out – A WebGL Game on Thursday September 17, 2015 @02:48AM (#10231928)
I'm curious as to why more WebGL games aren't popular? Is it due to the infancy of the WebGL scene or is WebGL just not capable of creating great games yet?
Re:Ask HN: Should I use Polymer for my next project? on Thursday July 23, 2015 @04:05AM (#9934535)
I used Polymer for a project a few months ago and I ran into browser support issues. Polyfills helped for most browsers, but my application wasn't working on iOS Safari. I'm not sure if that is still the case, but if so, I would choose to use a different framework such as Angular (easy to pick up) or React (slightly more difficult to pick up).
I think it has to do a lot with moderation. If someone is going to take full doses of psychedelics multiple times per week, I have no doubt in my mind that they could go through serious mental health issues. But that is not to say that occasional use is very safe. In fact, occasional use can be extremely helpful to many people.

I'm curious as to what the effect of frequent micro-dosing is...

Re:Xbox and PlayStation hit by 'hack' on Thursday December 25, 2014 @07:36PM (#8797612)
Is it possible that the xbox/playstation servers are overloaded from all the new consoles? Or is it confirmed that both servers are getting ddosed?
Re:Skeletal Tracking Beta on Wednesday May 28, 2014 @12:57PM (#7811376)
You could use JS to make AJAX calls to PHP, since it has a JS library.
Re:Skeletal Tracking Beta on Wednesday May 28, 2014 @12:57PM (#7811370)
How is this technology so much more accurate than Microsoft's Kinect? That's awesome! I love seeing the new guy develop a better product than a old giant.