Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
  • Dec 01 00:36
    scala-center-steward[bot] opened #678
  • Dec 01 00:36

    scala-center-steward[bot] on munit-cats-effect-3-1.0.7

    Update munit-cats-effect-3 to 1… (compare)

  • Dec 01 00:36
    scala-center-steward[bot] opened #677
  • Dec 01 00:36

    scala-center-steward[bot] on scalatest-3.2.14

    Update scalatest to 3.2.14 (compare)

  • Dec 01 00:36
    scala-center-steward[bot] opened #676
  • Dec 01 00:36

    scala-center-steward[bot] on scalafmt-core-3.5.9

    Update scalafmt-core to 3.5.9 Reformat with scalafmt 3.5.9 E… Add 'Reformat with scalafmt 3.5… (compare)

  • Dec 01 00:35
    scala-center-steward[bot] opened #675
  • Dec 01 00:35

    scala-center-steward[bot] on sbt-converter-1.0.0-beta40

    Update sbt-converter to 1.0.0-b… (compare)

  • Dec 01 00:35
    scala-center-steward[bot] opened #674
  • Dec 01 00:35

    scala-center-steward[bot] on sbt-1.8.0

    Update sbt to 1.8.0 (compare)

  • Dec 01 00:35
    scala-center-steward[bot] opened #673
  • Dec 01 00:35

    scala-center-steward[bot] on scala3-library-3.2.1

    Update scala3-library to 3.2.1 (compare)

  • Dec 01 00:35
    scala-center-steward[bot] opened #672
  • Dec 01 00:35

    scala-center-steward[bot] on scalajs-dom-2.3.0

    Update scalajs-dom to 2.3.0 (compare)

  • Dec 01 00:35
    scala-center-steward[bot] opened #671
  • Dec 01 00:35

    scala-center-steward[bot] on mongo-scala-driver-4.7.2

    Update mongo-scala-driver to 4.… (compare)

  • Dec 01 00:35
    scala-center-steward[bot] opened #670
  • Dec 01 00:34

    scala-center-steward[bot] on org.eclipse.lsp4j-0.19.0

    Update org.eclipse.lsp4j to 0.1… (compare)

  • Dec 01 00:34
    scala-center-steward[bot] opened #669
  • Dec 01 00:34

    scala-center-steward[bot] on commons-text-1.10.0

    Update commons-text to 1.10.0 (compare)

Geoffrey Challen
@gchallen
scastie seems extremely similar, so I'm curious if it's something that I could integrate into our existing backend? I'd like to continue to use our existing sandbox if possible, since it's fast and pretty well tested at this point. As described, I need a way to compile Scala code to bytecode, probably to a Java classloader. I also make take a look at scalac to see if I can reverse engineer things that way, which is what we did for Kotlin. Any suggestions would be appreciated! I'm also just starting to grok my first bits of Scala as I work on this, which is of course both fun and complicates things somewhat :-).
Vinz
@vincenzobaz
Welcome @gchallen ! Your playgrounds seem very cool, a nice UI and good performances as well! I agree that the project is similar to Scastie with a few differences, and please correct me if I make any mistake about Playgrounds. The biggest divergence appears to be that Scastie allows users to customize their build, both by modifying compiler flags and adding dependencies, thus users can have a very unique experience. This also impacts the performances as we need to rely on sbt (a build tool) to process snippets.
Another useful feature, that you might now from the Kotlin ecosystem, is the possibility to use Worksheet mode to evaluate interactively expressions of snippets. That is possible thanks to the mdoc project https://scalameta.org/mdoc/
OlegYch
@OlegYch
@gchallen this sounds more like https://github.com/scalafiddle
though it currently offline (moving to new servers)
you can embed both scalafiddle and scastie in your website
scalafiddle is faster because it doesn't touch file system and easier to secure because it executes the code (compiled to js) in browser
ollijh
@liff:matrix.org
[m]
any chance of scastie getting its jvm upgraded from 8 to 11 or 17?
OlegYch
@OlegYch
@liff:matrix.org shouldn't be a problem
pr is welcome
ollijh
@liff:matrix.org
[m]
where is the version defined?
guessing it isn’t just a single place considering there’s all of docker, nix and nvm used in run instructions :)
OlegYch
@OlegYch
this stuff is not on ci though so be careful
ollijh
@liff:matrix.org
[m]
so the public thingy at https://scastie.scala-lang.org/ runs on Docker?
OlegYch
@OlegYch
the server runs on ubuntu, and the snippets build and run in docker
ollijh
@liff:matrix.org
[m]
ah i see
ollijh
@liff:matrix.org
[m]
@OlegYch: PR is away, thanks for the support
OlegYch
@OlegYch
awesome
Jim Newton
@jimka2001
Is this gitter active4?
Screenshot 2022-01-23 at 00.32.52.png
it is linked from the scastie tool.
OlegYch
@OlegYch
@jimka2001 yep
patientplatypus6
@patientplatypus6
how is this supposed to run? there's a save button, but no run button?
OlegYch
@OlegYch
@patientplatypus6 the button both saves and runs
Naftoli Gugenheim
@nafg
It should have a run icon
OlegYch
@OlegYch
it does
Naftoli Gugenheim
@nafg
I meant it should have a run button
A save button with a run icon is confusing
It should just say run
I don't think "now I want to save this for later, how do I do that." I think "now I want to run this, how do I do that"
Saving is nice because
(a) I want to press refresh and not lose it
(b) I want to be able to open it elsewhere (or allow someone else to) by copy-pasting a URL
Both of those are things that I expect to happen automatically, not because I explicitly request to. I shouldn't have to
The thing I want to have an explicit button for is "Run," not "Save"
Similarly there should not be a New button, and it most certainly shouldn't pop up a modal confirmation box
There should be a Clear button. And pressing Back should take me to the old code so I don't need to sign a document confirming I accept the risks so to speak
OlegYch
@OlegYch
@nafg can you explain a bit about 'back', i'm not sure what you mean
Naftoli Gugenheim
@nafg
@OlegYch clearing should generate a new URL, and the code before should be saved under its URL, so the browser back button would take me to the code before I cleared it. So you could "undo" erasing it. Therefore no need to show a modal
Relatedly, if I just go to scastie without specific code link, I don't want to see my old code whatever it was doing. I want a blank editor
It's very annoying that if I'm like "I want to try something in scastie" I have 3 steps, navigate to scastie, press New, and confirm Yes
OlegYch
@OlegYch
well if you accidentally close scastie you don't want code to be gone either
@nafg can you open an issue for that please
Naftoli Gugenheim
@nafg
@OlegYch true but I don't see how that's relevant, unless the New confirm is really the onunload confirm, which I can't imagine
Jack Koenig
@jackkoenig

I'm having issues trying to download and run an executable in a Scastie (in this case, using coursier executable as an example): https://scastie.scala-lang.org/binAsaE5RViUFuK8JxdtZA

The same code works locally so I'm just wondering if I'm missing something.

OlegYch
@OlegYch
@jackkoenig could be docker sandbox preventing that?
Jack Koenig
@jackkoenig
@OlegYch that would probably do it, I'm guessing it's strictly forbidden to run any new binaries (other than the compiled Scala of course) for security reasons?
OlegYch
@OlegYch
@jackkoenig i'm not sure (not an expert on docker), but it seems like it
Jack Koenig
@jackkoenig
Does anyone have automation to generate Scasties? My use case is that I have Scastie templates that I have to manually edit every time I do a release of the project I maintain. It'd be nice if I could script this such that I update some data file and then generate new Scastie links and embed them (in a README for example). I know there's a JavaScript API for generating Scasties used by mdoc, it's not exactly what I want but I did discuss this a little bit in the mdoc repo: https://gitter.im/scalameta/mdoc?at=620abd1fe4c979478d79d514
I could go the pure JavaScript embedded route, but it feels wasteful that every time my webpage is opened, a new Scastie is generated. I'd rather generate it once and just embed a link
OlegYch
@OlegYch
@jackkoenig you could pass your library config via query params eg https://scastie.scala-lang.org/try?g=com.typesafe.play&a=play&v=2.8.12&t=JVM&sv=2.13&o=playframework&r=playframework
will this work for you?