One thing that's interesting about our small team is that we've built expertise in both the frontend (IDE) and the infrastructure (container management and remote development environment protocols). For the IDE, we recently shipped a big rewrite that allowed us to do server-side rendering (important since we're committed to speed) and a plugin architecture based on the ideas behind Redux with a very small core (https://repl.it/blog/ide). Everything in the IDE is a plugin, which is simply a reducer, a receiver, and a React component. The reducer builds up the state required for the plugin to work, the receiver dispatches actions in response to other actions flowing through the system, and the component renders. Even something as core to the IDE as the file tree is built as a plugin with no privileged hooks into the core. For the backend, we've designed a set of protocols and hooks for remote development. The protocol can expand capabilities as you require them. For example, every program starts out using the simple (loop (print (eval (read)))) protocol and then if you decide to use files/modules then it will switch to something that knows how to handle file manipulation and change events. The IDE can also react to what you require, for example, if you open a port then it will open a webview would pop open so you can see the result.
Last but not least, Repl.it has a growing community of aspiring programmers. Some of our hardcore fans are teenage programmers and so we've built a place for them to share, vote on, and discuss their projects (https://repl.it/ibuiltthis?sort=top). One interesting thing that we've noticed about kids on our platform is that they continue to build 90's-style website. I've commented on a recent HN thread with links to some of their creations (https://news.ycombinator.com/item?id=16506825).
I've been using repl.it for a couple of (or more, I suppose) years now, and it's been very helpful to have a simple, reliable REPL to jump into, test things out, and to share code. I've turned students and colleagues to it, too. I'm excited to see where you're taking it. I hope it continues to load and run quickly.
Just wanted to say thanks for building it, and keep up the great work!
Yes we aim for 2 seconds loadtime irrespective of the environment (we maybe a bit of the mark in some cases but not too far off) and part of the post was about reassuring folks like you that although it will increase in power it doesn't mean that it will be slower or more complex.
Could you add an option to copy/clone/use a github public repo?
I would love to "mount" the github repo for tflearn and run the examples.
Ideally, I would love a curated list of public repos per language that lets me explore and learn.
This has so much potential but I'm finding it near unusable right now. I use the Clojure REPL, so some of these issues might be unique to it.
0. No docs. There's plenty of odd and unexplained behavior that needs documenting - at least until stuff is less broken.
1. Can't eval single forms from editor. Whole files only.
2. Can't eval anything from files other than main.
3. Lots of delays and hangs. Very slow. Every eval takes multiple seconds. Some repl starts take 30 seconds.
4. Weird inconsistent behavior. Sometimes it will render function return values from editor eval to the repl, sometimes not.
5. Once you drop a new file, stuff breaks in strange ways. E.g. main.clj no longer seems connected to the user namespace.
6. Can't load other files, (load "other.clj") doesn't find it.
I could go on, but it's currently a mess from my perspective. I swear it used to work pretty well and now it's super broken. Any way I can log these issues and get them worked on?
So because of all the traffic we're getting (on here, Product Hunt, and Tech Crunch) there is a lot of container pool misses and because of the JVM Clojure takes a while to load. We just upped the Clojure pool so it should work now.
To address your points but please feel free to add this to our feedback board too.
>0. No docs. There's plenty of odd and unexplained behavior that needs documenting - at least until stuff is less broken.
This is definitely an area we need to fix but to your other comment there shouldn't be any unexplained behavior. If there is it's a bug. Please report it here: https://repl.it/bugs
>1. Can't eval single forms from editor. Whole files only.
Meaning you want to highlight code and eval it? That's something we've seen requested before and would love to implement.
> 2. Can't eval anything from files other than main.
Yes so if you start adding files we switch to executing code via `lein exec main.clj`. We should probably drop the REPL in the same namespace as well. Do you know if there is an easy way to connect the REPL to a running program?
> 3. Lots of delays and hangs. Very slow. Every eval takes multiple seconds. Some repl starts take 30 seconds.
should be fixed now.
>4. Weird inconsistent behavior. Sometimes it will render function return values from editor eval to the repl, sometimes not.
This should be consistent. It's the first time we hear about this, can you please report it with some repro steps?
> 5. Once you drop a new file, stuff breaks in strange ways. E.g. main.clj no longer seems connected to the user namespace.
Related to point #2
> 6. Can't load other files, (load "other.clj") doesn't find it.
repl.it looks awesome. It'd be interesting to hear more about how you're doing provisioning and orchestration. Are you running a Kubernetes or DC/OS cluster by chance? Are you spinning down idle instances after some time? What actually happens behind the scenes to make a deploy go live? etc
And then some more general questions - Can I hook a CI into the deploy loop? (Maybe that doesn't quite make sense given the model is something like Jupyter notebook meets Glitch.) Also, is there a repo being managed behind the scenes like GitHub does in Gist, and if so, any plans to open access to those?
Great questions and we intend to write about this more in the future. We had to build our own container orchestration mostly for speed and customizability.
A bit of context: for every language/environment we have a Dockerfile (naturally) and a JSON configuration that describe how it runs, how it install packages, how it runs unit tests, how it formats code, etc. When we build the container we insert a program that we call pid1, it's the container's interface to the rest of the world.
The container manager creates pools of these containers with some rudimentary predictive logic to make sure we have enough containers to deliver on our promise of "loads in 2 seconds". When we take a container out of the pool, if we're reviving a container, we mount a GCS-backed fuse filesystem with the user code (it needs to be backed by GCS to handle persistence, say you're writing to a log file, it should be there next time you load your project). We then send the relevant setup command to pid1 (either init, or wakeup) which sets up the repl to start the user app, the repl, or what have you.
> What actually happens behind the scenes to make a deploy go live
We poll the container for published ports and the moment we see an open port we add a record to an etcd which stores the routing state. We then send a command to the client that we published a port, which will react by opening an iframe. Then the iframe or any request to the published url will hit our outer reverse proxy which will query etcd to find the container and if the container is alive we will send the traffic to the relevant container manager which has another reverse proxy which sends the traffic to the container.
If the container however is dead (from idling or because of an error) we revive via picking a container out of one the pools and going through the initialization phase described above.
Finally, we also host our own docker image registery so that we can push new images, whether new languages, new versions or what have you.
There is a lot more to talk about here so I or someone on the team will write a post soon.
Did you move away from Emscripten? I was trying to use repl.it offline recently, and it didn't seem to work. Using Emscripten was one of the coolest parts of the original, and it would be sad if you had to drop that.
Yes, had to move even before started building the more advanced features like hosting. There were some bugs with the JS number type causing weird issues with emscripten. It's been a while so I don't remember the details.
I'm a university professor, and there's no way i can afford personally 1$/month per student. And definitely the school won't allow me the budget. "Use the lab computers", they'll say..
So I don't know how realistically someone can use repl.it for teaching, at least in public/higher education.
yes, there is. in the matter of fact, Scala is one of the top languages requested on Repl.it. We have an open issue for languages requests on our feedback channel here is a link for it https://replit.canny.io/languages-requests
Are Facebook, Google, and all the other name brands you are using to promote your product using your proprietary service, or the older open source stuff? If you have gone closed source, you should only be using names that are using the proprietary product.
It seems like putting "Open Source" on your front page in a big headline is a bit misleading if you are now a proprietary service. Labeling "Open Source" as a key feature seems disingenuous if you used to be open source but are no longer. If the case now is just that you use open source software, I don't think "Open Source" as headline is appropriate, as that is true of almost any company. The implication with listing "Open Source" as a headline is that your product is open source.
Oh, I could see how this could be misleading. So the open-source tech you linked to is outdated -- we moved everything from the client-side to our own infra (because we wanted to do things like open a port). We intend to open source the backend infra too but it takes time for the protocol to stabilize.
The "open-source" section on the homepage is intended to show that some open-source projects (for example Jest https://facebook.github.io/jest/ were repl.it is embedded on the homepage) use us as a playground, for bug reports etc.
Google, for example, uses the Classroom product to spread programming education. I think they have a program where they send teachers to schools to teach computer science. And there teachers wanted to use Repl.it etc.
Just to be clear, Google using the Classroom product doesn't implicitly grant you permission to use their logo on your marketing materials. Did you obtain permission from the listed entities to use their logos?
I probably did, it's been a year though so I'm not entirely sure. For what it's worth this really is not needed and I actually hate the "look at all the logos" sections on websites so I just pushed a fix to remove it.
It’s hard to make a man happy without making another one sad. I hate that it’s true, but look at all the logos you recognize using this product is the only way I can ever get my completely non tech literate boss to sign off on any new tech. :(
Probably a super unpopular opinion here on hn but your boss `aint completely wrong. It's not a bad strategy when considering starting a business relationship with someone or something you don't know much about.
I don't see this as an issue, personally. Part of their product is open-source, and part of it isn't.
In addition, their product can be used to help open-source projects with documentation, code running, etc.
When I read "Open Source" near the bottom, that's what I read (the we help you with your open source projects).
Also, any company is allowed to use names as long as they have an agreement with the company in place. Whether or not those companies use 1 of the company's products or all of them doesn't matter much. You see this a lot on Enterprise-oriented websites. Not all customers who leave case studies will use all the products.
As I understand it, this is no longer the case (as compared to say an open core company). They had some open source software. They abandoned it. They hope to open source their tech in the future, but currently they are closed source proprietary tech on top of the usual Linux, node, etc infrastructure.
They may be used by, or useful for open source projects, but currently they are not what most people would consider an open source company. I think that requires at least an open core, which to my understanding is not currently available.
Is there a cloud (browser) based IDE that allows to run code on a server I specify?
Right now I'm using the remote deployment feature of PyCharm to run tensorflow code on different remote GPU servers, but I'd like to uncouple the IDE from my local machine.
Ideally, I'd like Github to offer such service, so that I can edit the code in my repo right on github.com, specify a remote server to run it on, and seamlessly transfer/run it on that server with a click of a button.
I'm not sure I would either and I'm the CEO. I love Emacs. I'll work to convince myself to use it as my primary IDE and if I did maybe then others would. For now, I'll use it for launching microservices, quick experiments, prototyping, side-projects etc.
However, fun thing to share is that a lot of kids get started programming on Repl.it and continue to use it as their IDE.
I was a huge fan of Repl.it while I was learning Ruby, but I was never able to leverage it into anything other than self-teaching. I have however, wasted many hours trying to get various local IDEs to replicate the experience of Repl.it, so that's gotta count for something.
In the end, I transitioned to Visual Studio Code, but VS Code doesn't have the same inline repl (or I've yet to get it to work correctly). It sucks by comparison, but it has the advantage of actually working locally.
Thanks for the lovely comment. Hopefully you can come back and use us at least for side-projects. Then maybe as you we get better and expand to service all your IDE needs you'll stick around to use it as a primary IDE. We're in it for the long haul and we'll get there.
I like the idea of trying out new languages/frameworks using this. I would be concerned building any serious projects using Repl though. I'm worried about how much 'lock in' there is at the moment. How difficult would it be to move from Repl to AWS for example? My guess is that it would be significantly more difficult than moving from AWS to Azure or something like that. If their service is unique enough it will be a pain to move, I would imagine. But this is obviously also their advantage. I bet this is similar to the when first cloud hosting platform launched. You no longer had to rack the servers yourself but if that company failed, you were screwed. :)
You can build your application in a way that doesn't depend on platform-specific features. In fact most of the frameworks are setup in a generic way. There is a download button, you can click that, get a zip file and you should be able to run it locally.
For the setups that are using platform-specific features we'd like to also minimize the fear of lock-in by open sourcing our development images and the repl protocol.
Props. repl.it has often proven a handy substitute in situations in which I'm otherwise stuck with Cygwin or Git Bash on Windows, which, while they are great tools in their own right, can be a bit finicky when running repls.
This sounds amazing. I don't know how much I would personally use it, but at a minimum I'm going to keep it in mind for telling anyone wanting to learn and do tutorials in anything this supports, as seems far and away the best way to learn w/o fighting with environment. Huge Kudos.
Repls are container-based. We control how much resources each repl can use and so we can control how it much it costs. We do swap out idle repls and wake them up on the first request that comes in (heroku style).
How do you start up these containers so quickly anyways? Do you keep some running hot, or delegate the startup to something like amazon's ECS? I've long wanted to run integration tests en masse in containers, but never figured out how to solve issues around long startup times.
Congratulations, Amasad, really nice work. I was glad to see the inclusion of Web Frameworks, and tried to set up a Classroom for Rails instruction but have a basic question: how are students able to execute rails commands in the IDE? How do you switch between the REPL and console? Thanks!
Hey for now rails is only available in the rails interface because it just came out today. We're adding it to classrooms very soon. BTW feel free to email email@example.com and will happily answer all your questions.
Yes, eventually. As I said in a sibling thread, we intend to open-source our protocol/images so that we can do things like, use your own editor/local setup with Repl.it. Or eject completely from the platform.
It's more that it's awfully tortuous to use Django without it. The syntax for creating and running migrations inside a Python shell isn't very pleasant and all the documentation assumes you're doing all this from a bash shell.
> We know a lot of seasoned users
It's actually the other way around. Seasoned users can work out how to get round the lack of a shell. Beginners will be thoroughly confused.
Just as a possible user.. I use Rubymine for my Ruby on Rails development. Not only does it give me autocomplete on my application specific methods, it understands RVM (Ruby Version Manager) and understands where all of the dependencies are locations and has indexed those as well.
I can jump into an ActiveRecord definition as easily as my own methods. And it does this when I simply open the project directory.
Sublime Text 3 and some of the other editors can do the autocomplete/inspect method for full project and dependencies, but not without manual config changes (and some googling).