News for hackers. Stuff that matters.
Re:Show HN: Learn to Code with Interactive Challenges by Method-X on Tuesday May 16, 2017 @08:39AM (#14349069)
Hey wjvdhoek, I'm the guy working on this project. I agree mandatory registrations are indeed very annoying (and 95% of the time completely unnecessary). My reasoning behind requiring user registration is for security. Since code is being executed on my server, I want to be extra careful.

That being said, you have an idea I never thought of. I could simply let any user make X number of attempts and then prompt for registration. It's not as annoying that way and still secure. And yes, it's definitely hurting conversion BUT I couldn't think of any other way to set things up. If anyone else has suggestions on this, I'm all ears!

Re:Show HN: Learn to Code with Interactive Challenges by noxToken on Tuesday May 16, 2017 @08:58AM (#14349164)
It is kind of soul crushing to work on a problem only to be denied execution. Thankfully, I ran an easy JS challenge that was a one-liner. Had I done a a harder challenge that took 10 or 20 minutes, I would have been rather upset.

I understand why you put the registration further into the process. People have already invested time, so they might as well register so that the time isn't wasted. This is markedly different from how the rest are. They either put registration up front (HackerRank) or you're required to validate your own code (cryptopals). Aside from intentionally infecting my computer with malware or something, I couldn't think of a more negative user experience from a code challenge site.

These types of sites are far from unique. They are basically a dime a dozen. But now my experience is, "Don't make the same mistake I did. It gives you an input field to submit a challenge, but it will not validate your answer until you register. Either register up front, or don't bother."

Edit: This post was intended to be constructive, but I can see how it can be interpreted otherwise. See here[0] for more info. Apologies!

[0]: https://news.ycombinator.com/item?id=14349780

Re:Show HN: Learn to Code with Interactive Challenges by happy-go-lucky on Tuesday May 16, 2017 @09:36AM (#14349422)
> These types of sites are far from unique. They are basically a dime a dozen.

That's not constructive criticism. You can't always create something that's unique and not a dime a dozen.

Re:Show HN: Learn to Code with Interactive Challenges by noxToken on Tuesday May 16, 2017 @10:23AM (#14349780)
It's not meant to be flippant, although I see I should have chosen better wording. It's meant to go right into the next point: I spent time solving a challenge, but the site will not let me validate it without creating an account.

Sometimes the challenges take 30 seconds. Other times, you may spend over 30 minutes working on something more challenging. Who wants to spend time working on a challenge only to be told, "Wait a sec. You need to register before I tell you if you were correct." If I am presented with an input field, I would expect that I am allowed to submit that input. And that's where the dime a dozen comment comes from. If I try to accomplish the task your site has given me but there's an unexpected roadblock imposed by the site itself, why would I stay on that site when I can go elsewhere?

If registration is required, it should say so up front. Allow users to browse challenges. Even allow users to view the full challenge text. However, disable the input field if they must register first. It otherwise implies that I can solve the challenge without an account. You don't want to mislead your potential users.

I supposed I should have said something like, "There are many code challenge sites available. It is imperative to give users a positive experience, because users can easily go elsewhere for something similar." I did not mean to be insulting.

Re:Show HN: Learn to Code with Interactive Challenges by Method-X on Tuesday May 16, 2017 @10:37AM (#14349893)
What about putting a small banner / notice right above the code editor that explains the user must register before executing code? I'm honestly not intentionally trying to create an annoying site, it's just when you have users running code you legitimately have to take some security precautions. I'll put some thought into how I can communicate this to the user... My favorite idea so far is to just let the user execute code X number of times and then prompt for registration.
Re:Show HN: Learn to Code with Interactive Challenges by lgas on Tuesday May 16, 2017 @11:27AM (#14350299)
Having an account tied to the execution of the code does nothing to help with security. I can still register with a bogus email account and then run code anonymously. This doesn't inconvenience attackers, only legit users.
Re:Show HN: Learn to Code with Interactive Challenges by happy-go-lucky on Tuesday May 16, 2017 @11:41AM (#14350417)
> This doesn't inconvenience attackers, only legit users.

You just nailed it.

Re:Show HN: Learn to Code with Interactive Challenges by noxToken on Tuesday May 16, 2017 @10:54AM (#14350044)
I am sympathetic to your reasoning. I am terrible at design, but I think almost anything would be better than what you have. An obvious banner works well. Allowing a few attempts works well, but in that case, how do you rate limit someone executing code without an account?
Re:Show HN: Learn to Code with Interactive Challenges by PapaFragrant on Tuesday May 16, 2017 @09:25AM (#14349347)
This is a little bit overly dramatic.
Re:Show HN: Learn to Code with Interactive Challenges by wjvdhoek on Tuesday May 16, 2017 @09:14AM (#14349265)
The security-rationale is a fair point, haven't thought of that ;)

Without knowing how you run the code server-side, are there any languages/challenges that are presumably safe? Maybe you could offer the Javascript challenges without the requiring the user to register.

Re:Show HN: Learn to Code with Interactive Challenges by zoidb on Tuesday May 16, 2017 @09:17AM (#14349289)
"Since code is being executed on my server, I want to be extra careful." If you mean security I think your concern isn't necessary, if nothing else you will have less people using your site so whatever issues you do have will take longer to surface. If the concern is performance or loading your backend that may be valid but is also a great problem to have! I would try to get as many people to use it as possible OR at least make the first challenge or two available to anonymous users.
Re:Show HN: Learn to Code with Interactive Challenges by Method-X on Tuesday May 16, 2017 @09:45AM (#14349495)
Also a really good suggestion. Thank you.
Re:Show HN: Learn to Code with Interactive Challenges by happy-go-lucky on Tuesday May 16, 2017 @08:50AM (#14349120)
Should users have any reputation before creating new challenges or making translations?
Re:Show HN: Learn to Code with Interactive Challenges by Method-X on Tuesday May 16, 2017 @08:56AM (#14349151)
This would make for a great anti-spam mechanism. Kind of like the ultimate captcha. If quality / spam ever (inevitably) becomes an issue, I will absolutely require a minimum REP / XP.
Re:Show HN: Learn to Code with Interactive Challenges by happy-go-lucky on Tuesday May 16, 2017 @09:06AM (#14349201)
I asked the question because as of now it looks like any registered user can create new challenges and/or translations.