!EHpcRyNJdgGtwsEwtl:matrix.org

Scala CLI

415 Members
Scala CLI is a command-line tool to interact with the Scala language. It lets you compile, run, test, and package your Scala code (and more!) scala-cli.virtuslab.org4 Servers

Load older messages


SenderMessageTime
29 Dec 2023
@_discord_537054256151265281:t2bot.ioearldouglas Thanks for the help, all! 18:05:14
@_discord_537054256151265281:t2bot.ioearldouglas https://github.com/VirtusLab/scala-cli/issues/2653 18:16:35
3 Jan 2024
@_discord_154558903290560512:t2bot.iojd557 I think the standard way is to just put all the directives in a project.scala 20:10:32
@_discord_154558903290560512:t2bot.iojd557 Yeah, not really 🫤 20:12:42
@_discord_154558903290560512:t2bot.iojd557 I guess you could use the using-directives lib to parse it 20:13:04
@_discord_154558903290560512:t2bot.iojd557 Or export the build 20:13:38
@_discord_154558903290560512:t2bot.iojd557 (give me a minute, let me just order dinner) 20:13:53
@_discord_154558903290560512:t2bot.iojd557 I meant this https://github.com/VirtusLab/using_directives 20:18:58
@_discord_154558903290560512:t2bot.iojd557 I only see the export option, but maybe it's not that hard to convert from JSON to using directives? 20:28:51
4 Jan 2024
@_discord_594749312123142149:t2bot.ioquafadas I'm using scala cli to run a gist, which ends like this.

Caused by: doobie.munit.analysisspec$Checker$ErrorItems
    at doobie.munit.analysisspec$Checker$ErrorItems$.apply(analysisspec.scala:61)
    at doobie.munit.analysisspec$Checker.checkImpl(analysisspec.scala:54)
    ... 4 more

I reaaaaallly wan tto see those "4 more". Can I tell scala-cli not to truncate them somehow? I tried -v -v -v but to no avail.
08:12:47
@_discord_845013677816021083:t2bot.ioarmanbilge I'm not sure but it's possible the ... 4 more is the JVM truncating, not a scala-cli thing 14:26:34
@_discord_845013677816021083:t2bot.ioarmanbilge might be -XX:MaxJavaStackTraceDepth 14:27:37
@_discord_594749312123142149:t2bot.ioquafadas Well, I tried the stack trace flag, but didnt change anything get it to work. I'll pause this for now. 20:23:57
@_discord_594749312123142149:t2bot.ioquafadas * Well, I tried the stack trace flag, but didnt change anything. I'll pause this for now. 20:24:07
6 Jan 2024
@_discord_583167330566275072:t2bot.iosethtisue I replied with a doc link 15:52:03
@_discord_154558903290560512:t2bot.iojd557 It might be worth to link that question in https://github.com/VirtusLab/scala-cli/discussions/1794 15:52:58
@_discord_154558903290560512:t2bot.iojd557 Even with the docs, I think that the package defaults can be a bit confusing 15:53:36
7 Jan 2024
@_discord_583167330566275072:t2bot.iosethtisue it's a reasonable feature request, but it's not straightforward to implement since scala-cli is basically just a launcher. by default it launches the stock REPL and the stock REPL does not have this feature

you can launch the Ammonite REPL instead with scala-cli --power repl --amm — Ammonite has this feature, but the syntax is different, some import $ivy... thing
18:31:53
@_discord_583167330566275072:t2bot.iosethtisue would be a good Google Summer of Code project this year, maybe. though if someone wants to tackle it sooner than that, please do 🙂 18:33:40
9 Jan 2024
@_discord_448877036098813952:t2bot.ioLorenzo Gabriele (lolgab) The whole point behind build tools like scala-cli and bleep is the fact that the build is data (directives or yaml) and not scala code. If you need to run some scala code to manipulate the build programmatically, isn't it better to just use a build tool with the build as code, like sbt or mill? 10:45:26
@_discord_594749312123142149:t2bot.ioquafadas I've been struggling with scaladoc, and tracked it back to, what I believe to be a rather odd looking bug.

I have this code, in a file called ext.scala

package vecxt

export Retentions.*

object Retentions:
    opaque type Retention = Double
    extension (x: Retention)
        inline def retention: Double = x
end Retentions

This command, works.
scala-cli doc ext.scala -o scaladoc -f
and produces, as advertised, a website with documentation, for this glorious functionality.

Now, if I rename the file, to be this,
ext.retention.scala

Then scaladoc falls over...

simon@Simons-Mac-mini scaladoc % scala-cli doc ext.retention.scala -o scaladoc -f
Compiling project (Scala 3.3.1, JVM (21))
Compiled project (Scala 3.3.1, JVM (21))
class vecxt.ext.retention$package cannot be unpickled because no class file was found for denot: val <none>
1 error found
[error]  Scaladoc generation failed (exit code: 1)

My claim, is that the file rename, is tripping up scaladoc? Could this be the case?
16:08:51
@_discord_594749312123142149:t2bot.ioquafadas * I've been struggling with scaladoc, and tracked it back to, what I believe to be a rather odd looking bug.

I have this code, in a file called ext.scala

package vecxt

export Retentions.*

object Retentions:
    opaque type Retention = Double
    extension (x: Retention)
        inline def retention: Double = x
end Retentions

This command, works.
scala-cli doc ext.scala -o scaladoc -f
and produces, as advertised, a website with documentation, for this glorious functionality.

Now, if I rename the file, to be this,
ext.retention.scala

Then scaladoc falls over...

simon@Simons-Mac-mini scaladoc % scala-cli doc ext.retention.scala -o scaladoc -f
Compiling project (Scala 3.3.1, JVM (21))
Compiled project (Scala 3.3.1, JVM (21))
class vecxt.ext.retention$package cannot be unpickled because no class file was found for denot: val <none>
1 error found
[error]  Scaladoc generation failed (exit code: 1)

My claim, is that the file rename, is tripping up scaladoc? Ohh. I tyhink i tried it in mill and got the same... so I'm thinking this is not a scala-cli thing, and i'm posting in the wrong channel... hmm... would this be a scala compiler thing?
16:10:32
10 Jan 2024
@_discord_510415959480336393:t2bot.iopotatoef changed their profile picture.11:33:01
12 Jan 2024
@_discord_945331330294624276:t2bot.iozhao_nan changed their display name from Zhao Nan to zhao_nan.17:01:58
@_discord_231350810565410817:t2bot.ioragnar changed their display name from ragnar#4252 to ragnar.21:32:24
13 Jan 2024
@_discord_967195426275065976:t2bot.ioose_369 changed their display name from OSE to ose_369.00:42:10
14 Feb 2024
@nrktkt:matrix.orgnrktkt!discord bridge 632150470000902164 90115302163808266017:28:44
@_discord_bot:t2bot.ioDiscord BridgeI'm asking permission from the guild administrators to make this bridge.17:31:34
@nrktkt:matrix.orgnrktktchanged room power levels.17:32:28
@_discord_bot:t2bot.ioDiscord Bridge

Timed out waiting for a response from the Discord owners.

17:36:35

There are no newer messages yet.


Back to Room ListRoom Version: 9