From 0f9c40e9d16578f9293dbde26116b38168502938 Mon Sep 17 00:00:00 2001 From: Anatolios Laskaris Date: Fri, 14 Jul 2023 10:09:03 +0300 Subject: [PATCH 1/2] chore: Fix release (#795) Fix? --- .github/workflows/publish.yml | 15 --------------- 1 file changed, 15 deletions(-) diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index 908a2e285..55665b80a 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -43,21 +43,6 @@ jobs: - name: scala-js build run: sbt ";cliJS/fullLinkJS;language-server-apiJS/fullLinkJS;aqua-apiJS/fullLinkJS" - - aqua-cli: - name: "Publish aqua-cli" - runs-on: ubuntu-latest - timeout-minutes: 60 - - needs: - - compile - - steps: - - name: Checkout repository - uses: actions/checkout@v3 - with: - ref: ${{ inputs.tag }} - - name: Import secrets uses: hashicorp/vault-action@v2.7.0 with: From 33ab33d4c8f34743202e5acbfb2e976ab3070299 Mon Sep 17 00:00:00 2001 From: InversionSpaces Date: Fri, 14 Jul 2023 14:06:21 +0200 Subject: [PATCH 2/2] fix(compiler): Fix search for one element cycles (#797) --- linker/src/main/scala/aqua/linker/Linker.scala | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/linker/src/main/scala/aqua/linker/Linker.scala b/linker/src/main/scala/aqua/linker/Linker.scala index 5afdbd256..6d71b6ea9 100644 --- a/linker/src/main/scala/aqua/linker/Linker.scala +++ b/linker/src/main/scala/aqua/linker/Linker.scala @@ -40,12 +40,10 @@ object Linker extends Logging { case path :: otherPaths => val pathDeps = deps.get(path.last).toList.flatten val cycles = pathDeps.flatMap(dep => - NonEmptyChain - .fromChain( - // This is slow - path.toChain.dropWhile(_ != dep) - ) - .toList + NonEmptyChain.fromChain( + // This is slow + path.toChain.dropWhile(_ != dep) + ) ) val newPaths = pathDeps .filterNot(visited.contains) @@ -62,7 +60,7 @@ object Linker extends Logging { .flatMap(m => findCycles( paths = NonEmptyChain.one(m.id) :: Nil, - visited = Set.empty, + visited = Set(m.id), result = List.empty ) )