Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(deps): update dependency @fluencelabs/aqua to v0.15.0 #56

Closed
wants to merge 1 commit into from

Conversation

renovate[bot]
Copy link
Contributor

@renovate renovate bot commented Jan 30, 2023

Mend Renovate

This PR contains the following updates:

Package Change Age Adoption Passing Confidence
@fluencelabs/aqua 0.7.4-322 -> 0.15.0 age adoption passing confidence

Release Notes

fluencelabs/aqua (@​fluencelabs/aqua)

v0.12.1

Bug Fixes

v0.12.0

⚠ BREAKING CHANGES
  • js-client: Move to new js-client interface (#​855)
Features
Bug Fixes

v0.11.11

Features
  • compiler: Structural typing for data and abilities [fixes LNG-215] (#​843) (019611a)
  • parseq implementation (fixes LNG-223) (#​840) (8060695)
Bug Fixes

v0.11.9

Features
  • compiler: Add boolean algebra [fixes LNG-211] (#​814) (a5b6102)
  • compiler: Add equality ops [fixes LNG-217] (#​820) (a5e9354)
  • compiler: Restrict exporting functions that return arrow types or ability types [fixes LNG-209] (#​815) (fabf8d7)
  • wrap aqua api (#​807) (c7fca40)
Bug Fixes
  • compiler: Fix if with brackets parsing (#​812) (4c3c32b)
  • compiler: Fix math ops for u64 [fixes LNG-204] (#​811) (50ba194)
  • compiler: Nested abilities [fixes LNG-214] (#​816) (4e3e70f)
  • compiler: Runtime error on compilation exported functions with top types [fixes LNG-218] (#​822) (ef4b014)

v0.11.8

Features
Bug Fixes

v0.11.7

Compare Source

Bug Fixes
  • compiler: Fix incorrect service method renaming [fixes LNG-199] (#​757) (e22fff7)

v0.11.6

Compare Source

Bug Fixes

v0.11.5

Compare Source

Bug Fixes

v0.11.4

Compare Source

Features
  • tracing: Introduce function calls tracing [fixes LNG-169] (#​732) (e9c0044)
Bug Fixes
  • aqua-api: Compilation to js/ts for file without exports [LNG-196] (#​744) (8c2240d)
  • compiler: Fix closure call compilation [fixes LNG-193] (#​741) (c5534a9)

v0.11.3

Compare Source

Features
Bug Fixes
  • aqua-api: Add default constants to Aqua API [LNG-194] (#​738) (5f5fc49)

v0.11.2

Compare Source

Features
  • aqua-api: return JS and TS sources from API [LNG-164] (#​730) (0b66aa9)
Bug Fixes
  • language-server: Go-to definition for path in use expression [LNG-187] (#​733) (21cb393)

v0.11.1

Compare Source

Features
  • compiler: Structural typing for data and abilities [fixes LNG-215] (#​843) (019611a)
  • parseq implementation (fixes LNG-223) (#​840) (8060695)
Bug Fixes

v0.11.0

Compare Source

⚠ BREAKING CHANGES
  • add name scopes to if/else/try blocks (#​715)
Features

v0.10.6

Compare Source

Bug Fixes

v0.10.5

Compare Source

Features
Bug Fixes

v0.10.4

Compare Source

Features
Bug Fixes

v0.10.3

Compare Source

Bug Fixes

v0.10.2

Compare Source

Features
Bug Fixes

v0.10.1

Compare Source

Bug Fixes

v0.10.0

Compare Source

⚠ BREAKING CHANGES
  • DXJ-283 support new JS client (#​668)
Features

v0.9.5

Compare Source

Bug Fixes

v0.9.4

Compare Source

Bug Fixes
  • Canonicalize variable in object creation or copy if variable is a stream (#​649) (fedd743)
Performance Improvements
  • Unfold variables in parallel where it is possible (fixes LNG-109 ) (#​656) (439f2cd)

v0.9.3

Compare Source

Features
Bug Fixes
  • nil in return [DXJ-226] (#​629) (7ab980a)
  • ci: Set correct aqua version when creating release-please PRs [fixes FLU-215 and FLU-218] #​642 (d7956c1)
  • error-messages: fix incorrect number of arguments message [fixes LNG-108] (#​645) (d0a9db5)

v0.9.2

Bug Fixes

Configuration

📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).

🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.

Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

🔕 Ignore: Close this PR and you won't be reminded about this update again.


  • If you want to rebase/retry this PR, check this box

This PR has been generated by Mend Renovate. View repository job log here.

@renovate renovate bot force-pushed the renovate/fluencelabs-aqua-0.x branch 3 times, most recently from a3d061c to feb16a9 Compare February 9, 2023 17:11
@renovate renovate bot changed the title fix(deps): update dependency @fluencelabs/aqua to v0.7.4-338 fix(deps): update dependency @fluencelabs/aqua to v0.9.4 Feb 9, 2023
@linear
Copy link

linear bot commented Feb 9, 2023

LNG-109 Unfold arguments (call arrow and copy) in parallel where it is possible

LNG-102 Mutate (copy?) objects

depends on LNG-105

FLU-215 Bump aqua versions in package.json

Similar to what was done in FLU-212

FLU-218 fix aqua version in release (now it is 0.9.1-0.9.2)

LNG-108 Invalid error message when calling function with wrong number of args

When calling a function that expects one argument with zero arguments there is an error

Error: Number of arguments for the function is incorrect. Expected: 0. Actual: 1

But it must be

Error: Number of arguments for the function is incorrect. Expected: 1. Actual: 0

@renovate renovate bot force-pushed the renovate/fluencelabs-aqua-0.x branch 2 times, most recently from 7637632 to e9a060c Compare February 27, 2023 18:52
@renovate renovate bot changed the title fix(deps): update dependency @fluencelabs/aqua to v0.9.4 fix(deps): update dependency @fluencelabs/aqua to v0.10.2 Feb 27, 2023
@renovate renovate bot force-pushed the renovate/fluencelabs-aqua-0.x branch from e9a060c to 26ef516 Compare February 28, 2023 20:07
@renovate renovate bot changed the title fix(deps): update dependency @fluencelabs/aqua to v0.10.2 fix(deps): update dependency @fluencelabs/aqua to v0.10.3 Feb 28, 2023
@linear
Copy link

linear bot commented Feb 28, 2023

LNG-119 Functors don't work properly with arrays that is created rigth in Aqua

service OpNum("op"):
  identity(n: u32) -> u32

func getWorkers() -> []u32:
  nums = [1,2,3,4,5]
  results: *u32
  join results[nums.length]
  <- results

@renovate renovate bot force-pushed the renovate/fluencelabs-aqua-0.x branch from 26ef516 to 10057ac Compare April 12, 2023 13:39
@renovate renovate bot force-pushed the renovate/fluencelabs-aqua-0.x branch from 10057ac to 9b54e9d Compare November 15, 2023 14:34
@renovate renovate bot changed the title fix(deps): update dependency @fluencelabs/aqua to v0.10.3 fix(deps): update dependency @fluencelabs/aqua to v0.15.0 Nov 15, 2023
Copy link

linear bot commented Nov 15, 2023

LNG-223 `for .. parsec` instruction for round-based protocols

LNG-208 Restrict using abilities and arrows in arrays, options, structs, etc

  • Forbid exporting functions that accept abilities (exporting functions that return abilities or arrows is already forbidden)
  • Forbid exporting abilities
  • Forbid using non data types in collections

LNG-222 Scope (`new`) generation for streams doesn't work with `try`

try makes compiler skip new for declared stream

func main():
        temp: *i8
        temp <<- 42

produces

(seq
 (call %init_peer_id% ("getDataSrv" "-relay-") [] -relay-)
 (xor
  (new $temp
   (ap 42 $temp)
  )
  (call %init_peer_id% ("errorHandlingSrv" "error") [%last_error% 0])
 )
)

while

func main():
    try:
        temp: *i8
        temp <<- 42

produces

(seq
 (call %init_peer_id% ("getDataSrv" "-relay-") [] -relay-)
 (xor
  (xor
   (ap 42 $temp)
   (null)
  )
  (call %init_peer_id% ("errorHandlingSrv" "error") [%last_error% 0])
 )
)

LNG-215 Add structural subtyping for `data` and `ability`

This should compile:

aqua Main

export main

ability Smaller:
    arrow(x: i8) -> bool

ability Bigger:
    arrow(x: i8) -> bool
    field: string

func useSmaller{Smaller}() -> bool:
    <- Smaller.arrow(42)

data SmallerStruct:
    str: string

data BiggerStruct:
    str: string
    field: i8


func useSmallerStruct(s: SmallerStruct) -> string:
    <- s.str

func main():

    bigger = BiggerStruct(
        str = "bigger",
        field = 42
    )

    useSmallerStruct(bigger)

    closure = (x: i8) -> bool:
        <- x > 0

    bigger = Bigger(
        arrow = closure,
        field = "bigger"
    )

    useSmaller{bigger}()

Now compiler says that Number of fields does not match

LNG-209 Restrict return arrows and abilities from exported functions

LNG-58 Invalid variable name in generated AIR

aqua:

import "fluencelabs/aqua-lib/builtin.aqua"

func test() -> string:
    successful: *bool
    successful <<- true

    status: *string
    waiting = ():
      join successful[0]
      status <<- "ok"

    waiting()
    par status <- Peer.timeout(1000, "timeout")

  <- status!

AIR:

(seq
(seq
 (seq
  (seq
   (call %init_peer_id% ("getDataSrv" "-relay-") [] -relay-)
   (new $status
    (seq
     (new $successful
      (seq
       (ap true $successful)
       (par
        (seq
         (call %init_peer_id% ("op" "noop") [$successful.$.[0]!])
         (ap "ok" $status-0)
        )
        (call %init_peer_id% ("peer" "timeout") [1000 "timeout"] $status)
       )
      )
     )
     (call %init_peer_id% ("op" "identity") [$status.$.[0]!] status-fix)
    )
   )
  )
  (call %init_peer_id% ("--after-callback-srv-service--" "console-log") [status-fix])
 )
 (call %init_peer_id% ("--finisher--" "--finish-execution--") [])
)
(call %init_peer_id% ("callbackSrv" "response") ["ok"])
)

(ap "ok" $status-0) should be (ap "ok" $status)

LNG-204 Fix math for `u64` type

Now it is impossible to use u64 in mathematical operations:

func getU64() -> u64:
    <- 42

func main():
    a <- getU64()
    b <- getU64()
    c = a + b

output:

7     c = a + b
          ^====
          Types mismatch.
          expected:   i64
          given:      u64

LNG-217 Add equality comparison operators

Add binary operators == and != for values of any type (same type)

== and != should have higher precedence than && and ||, but lower precedence than any other oparetor

Inline <left> == <right> to

<left-inline>
<right-inline>
(xor
  (match <left-res> <right-res> (ap true <res>))
  (ap false <res>)
)

(use mismatch for !=)

LNG-57 Allow applying properties on complex expressions

if Op.identity(stream)! == "OK" doesn't parse

Version

0.7.2-303

Code

import "fluencelabs/aqua-lib/builtin.aqua"

func bug():
    stream: *string
    if Op.identity(stream)! == "OK":
        Op.noop()

Error

 % aqua run -i stream_bug.aqua -f 'bug()' --addr krasnodar-01
---- Syntax error: /Users/folex/Development/aqua_scripts/stream_bug.aqua:5:27
5     if Op.identity(stream)! == "OK":
                            ^=========
                            Expected symbol ':'

---- Syntax error: /Users/folex/Development/aqua_scripts/stream_bug.aqua:5:8
5     if Op.identity(stream)! == "OK":
         ^============================
         Expected one of these strings: '<<-'
         OR Expected symbol ':'
         OR Expected symbol '='
         OR Missing braces '()' after the function call (List(Expected symbol '('))
         OR Only results of a function call can be written to a stream

---- Syntax error: /Users/folex/Development/aqua_scripts/stream_bug.aqua:5:5
5     if Op.identity(stream)! == "OK":
      ^===============================
      Expected one of these strings: '<-', 'catch', 'co', 'else', 'for', 'join', 'on', 'otherwise', 'par', 'try'
      OR Expected symbols from 'A' to 'Z'

LNG-220 Nested ability passing compiles with error

aqua Main

export main

ability Simple:
    arrow(x: i8) -> bool

ability Complex:
    simple: Simple

func foo{Complex}() -> bool:
    <- Complex.simple.arrow(42)

func main() -> bool:
    closure = (x: i8) -> bool:
        <- x == 42
    MySimple = Simple(arrow = closure)
    MyComplex = Complex(simple = MySimple)
    <- foo{MyComplex}()

produces error log while compiling

2023.08.11 13:46:58 CallArrowRawInliner.scala [ERROR] Inlining, cannot find arrow Complex.simple.arrow, available:  and vars: PARTICLE_TTL, PARTICLE_TIMESTAMP, nil, INIT_PEER_ID, HOST_PEER_ID, LAST_ERROR

LNG-211 Introduce boolean algebra

Add binary boolean operations ||(or) and &&(and) and unary boolean operation !(not)

Result of ||, && and ! should be of type boolean

Precedence:

  • ! should have highest precedence
  • || and && should have lower precedence than math and comparison operations
  • || should have lower precedence than &&

e.g expression a < 5 || foo() > 10 && !flag should be parsed like (a < 5) || ((foo() > 10) && !flag)

Evaluation of arguments:

  • If left argument of || executes to true, right argument should not be computed
  • If left argument of && executes to false, right argument should not be computed

Implementation:

Translate <left> || <right> to

<left-inline>
(xor
  (match <left-res> true (ap true <res>))
  (seq
    <right-inline>
    (ap <right-res> <res>)
  )
)

Translate && to

<left-inline>
(xor
  (match <left-res> false (ap false <res>))
  (seq
    <right-inline>
    (ap <right-res> <res>)
  )
)

Translate !<expr> to

<expr-inline>
(xor
  (match <expr-res> true (ap false <res>))
  (ap true <res>)
)

LNG-214 Compiler fails on nested ability function call

On such a code snippet:

data Struct:
    int: i8

ability Simple:
    st: Struct
    arrow(x: i8) -> bool

ability Complex:
    simple: Simple
    field: string

func foo{Complex}() -> bool:
    <- Complex.simple.arrow(
        Complex.simple.st.int
    )

func main() -> bool:

    closure = (x: i8) -> bool:
        <- x > 0

    MyComplex = Complex(
        simple = Simple(
            st = Struct(int = 0),
            arrow = closure
        ),
        field = "complex"
    )

    <- foo{MyComplex}()

Compiler errors internally:

ApplyPropertiesRawInliner.scala [ERROR] Inlining, cannot find field Complex.simple in ability var{Complex: scope Complex{field: string, simple: scope Simple{arrow: (x: i8) :: ∅ -> bool :: ∅, st: Struct{int: i8}}}}.. Available: Set(PARTICLE_TTL, PARTICLE_TIMESTAMP, nil, INIT_PEER_ID, HOST_PEER_ID, LAST_ERROR)

LNG-218 Error on top types

Top types throws runtime error

LNG-203 Make `on` propagate error with correct topology

Now on ... via ...is wrapped with xor with call to errorHadlingSrv in its right branch

To propagate error from on body it is needed to insert return to previous topology and fail %last_error% in xor right branch

LNG-125 Replace `Op.noop` with a non-FFI snippet

Currently, topology hops are done using Op.noop function call that exits AquaVM, does nothing, and than returns into AquaVM to figure out what's next.

This could be replaced with smth like:

(new $op
  (new #noop
    (canon peer_id $op #noop)
  )
)

It does the same (moves execution to peer_id, leaves this move in the execution trace), but with no FFI calls, so should be twice as efficient.

LNG-199 Fix incorrect service method renaming

service Op("op"):
 someId(a: string) -> string

func foo(someId: string) -> string:
  <- Op.someId(someId)

Produces incorrect air

(seq
 (seq
  (seq
   (call %init_peer_id% ("getDataSrv" "-relay-") [] -relay-)
   (call %init_peer_id% ("getDataSrv" "someId") [] someId)
  )
  (call %init_peer_id% ("op" "someId-0") [someId] someId-0-0)
 )
 (call %init_peer_id% ("callbackSrv" "response") [someId-0-0])
)

Bug introduced while fixing LNG-92

LNG-149 Fix SO in Topology in some cases

Such aqua script generates SO in Topology module of compiler:

func foo_bar():
   for a <- ["a", "b"]:
     b = a

LNG-92 Passing closures doesn't work (0.7.7-353)

% aqua --version
0.7.7-353
func take_closure(f: string -> bool) -> bool:
  <- f("hello")

func test_pass_closure() -> bool:
  f = (s: string) -> bool:
    <- true

  <- take_closure(f)
% aqua --dry -i closure_race.aqua
2022.10.17 16:14:50:202 main INFO aqua.AquaCli.main:135
    Aqua Compiler 0.7.7-353
2022.10.17 16:14:50 [ERROR] Inlining, cannot find arrow f, available: Srv.list, test, Srv.add_alias, Srv.resolve_alias, Op.string_to_b58, Dist.make_module_config, Kademlia.neighborhood, Dist.add_blueprint, Op.string_from_b58, Script.add_from_vault, Op.identity, Srv.get_interface, Dist.get_module_interface, Script.list, Srv.remove, Sig.sign, Dist.list_blueprints, Op.noop, Debug.stringify, Peer.identify, Sig.verify, Peer.timeout, Peer.connect, Op.array_length, Dist.add_module_from_vault, Script.remove, Peer.get_contact, Dist.make_blueprint, Op.sha256_string, Script.add, Kademlia.merge, Dist.add_module, Srv.create, f-0, Op.bytes_from_b58, Peer.is_connected, Op.array, Sig.get_pub_key, Op.concat_strings, Dist.list_modules, Op.concat, Op.bytes_to_b58, Dist.default_module_config, Peer.timestamp_ms, Peer.timestamp_sec
Source /Users/folex/Development/aqua_scripts/closure_race.aqua: compilation OK

And it generates the following air

; This file is auto-generated. Do not edit manually: changes may be erased.
; Generated by Aqua compiler: https://github.com/fluencelabs/aqua/.
; If you find any bugs, please write an issue on GitHub: https://github.com/fluencelabs/aqua/issues
; Aqua version: 0.7.7-353

(xor
 (seq
  (call %init_peer_id% ("getDataSrv" "-relay-") [] -relay-)
  (xor
   (call %init_peer_id% ("callbackSrv" "response") [f-1])
   (call %init_peer_id% ("errorHandlingSrv" "error") [%last_error% 1])
  )
 )
 (call %init_peer_id% ("errorHandlingSrv" "error") [%last_error% 2])
)

LNG-169 Add logging near all calls for debugging (with flag in compiler)

LNG-193 Assignment does not work with closure return

Next snippet:

func foo(arg: u16) -> u16 -> u16:
  closure = func (x: u16) -> u16:
    <- x + arg
  <- closure

func main() -> u16:
  a = foo(42)
  b = 1 + a(2) + a(3)
  <- b

Makes compiler to write error log

CallArrowRawInliner.scala [ERROR] Inlining, cannot find arrow a, available: foo, closure

but compilation still succeeds with incorrect AIR.

LNG-148 Dev tool for compiler Scala and JS compilation

compile scala remotely

LNG-135 Strict indentation as in Python

Indentation in block must be on one level

func ..
 call1
 call2
 call3

This will throw an error:

func ..
 call1
   call2
 call3

This will throw an error too:

func ..
  call1
    call2
 call3

@renovate renovate bot force-pushed the renovate/fluencelabs-aqua-0.x branch 2 times, most recently from 8fd80cc to 866c453 Compare November 15, 2023 18:01
@renovate renovate bot force-pushed the renovate/fluencelabs-aqua-0.x branch from 866c453 to 5bbc0da Compare December 2, 2023 12:13
@renovate renovate bot force-pushed the renovate/fluencelabs-aqua-0.x branch 4 times, most recently from 0cc20cc to 0cddde2 Compare December 25, 2023 14:53
@renovate renovate bot force-pushed the renovate/fluencelabs-aqua-0.x branch 2 times, most recently from a1ec964 to 418e27c Compare December 25, 2023 16:04
@renovate renovate bot force-pushed the renovate/fluencelabs-aqua-0.x branch 2 times, most recently from fce83ba to 817f152 Compare December 25, 2023 21:26
@renovate renovate bot force-pushed the renovate/fluencelabs-aqua-0.x branch from 817f152 to 4c3ade6 Compare December 25, 2023 21:40
@renovate renovate bot force-pushed the renovate/fluencelabs-aqua-0.x branch 2 times, most recently from 5fdac27 to 9b93990 Compare December 26, 2023 15:34
@renovate renovate bot force-pushed the renovate/fluencelabs-aqua-0.x branch from 9b93990 to 95dd12b Compare December 26, 2023 15:47
@folex folex closed this Dec 27, 2023
@folex folex deleted the renovate/fluencelabs-aqua-0.x branch December 27, 2023 15:07
Copy link
Contributor Author

renovate bot commented Dec 27, 2023

Renovate Ignore Notification

Because you closed this PR without merging, Renovate will ignore this update (0.15.0). You will get a PR once a newer version is released. To ignore this dependency forever, add it to the ignoreDeps array of your Renovate config.

If you accidentally closed this PR, or if you changed your mind: rename this PR to get a fresh replacement PR.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant