github wavesplatform/Waves v0.17.0
Version 0.17.0 (Testnet)

latest releases: v1.5.8, v1.5.7, v1.5.6...
pre-release5 years ago

In This Release

RIDE 4 DApps

In this release, we introduce RIDE4DApps: the RIDE language and blockchain update. This grants a way to assign programmable functions to an account, which operate state and tokens atomically. To initiate the call, use the new InvokeScriptTransaction. More on that in the documentation.

RIDE Language Update

  1. Defining custom functions:

func max(a: Int, b: Int) = if (a > b) then a else b

  1. @Callable(inv) and @Verifier(tx) annotations:
@Callable(i)
func record(x: Int) = {
    WriteSet([DataEntry(toBase58String(i.caller.bytes), x])
}

@Verifier(tx)
func verify() = {
    false
}
  1. Postfix notation for function calls:
    extract(i.payment) can be rewritten as i.payment.extract()
    getInteger(account, key) can be simplified to account.getInteger(key)

  2. Compiler now supports directives. These are recommended to be specified at the beginning of DAPP code:

{-# STDLIB_VERSION 3 #-}
{-# CONTENT_TYPE DAPP #-}
{-# SCRIPT_TYPE ACCOUNT #-}

# definitions, callable and verifier functions go here

Default values are:

{-# STDLIB_VERSION 2 #-}
{-# CONTENT_TYPE EXPRESSION #-}
{-# SCRIPT_TYPE ACCOUNT #-}

For Asset script, use

{-# CONTENT_TYPE EXPRESSION #-}
{-# SCRIPT_TYPE ASSET #-}

Standard library version 3 and content-type DAPP will be available after successful RIDE4DAPPS feature activation.

  1. {-# STDLIB_VERSION 3 #-} includes:
  • this, returning address of the account, granting
getInteger(this, key)
  • value() function, which is the same as extract
  • let x = [a,b,c] List constructor
  • New types: WriteSet,TransferSet,ScriptResult and other types necessary for script invocation
  • getInteger(...) family of functions and addressFromString now have companions of type getIntegerValue(..) and addressFromStringValue(..) which throw unrecoverable exception is the value is not present

Other changes

  • Default directory now follows os-specific guidelines:
    OSX: $HOME/Library/Application Support/waves
    Linux: $XDG_DATA_HOME/waves or $HOME/.local/share/waves
    Windows: %APPDATA%/local/waves (edited)

RIDE 4 DAPPS is implemented as Feature 11. Please vote!

Update Notes

No need to rebuild the node storage when updating from version 0.16.2

SHA256 Checksums

d53d59cb92b0e3d8fbeaba481e778cd254919284f5c5d80ee2133868c3fdefbd  waves-all-0.17.0.jar
a8d205f6018a32eca91998b44b542013ef7e22a4919ffb489ae9eb48d9226a0d  waves-testnet_0.17.0_all.deb

Don't miss a new Waves release

NewReleases is sending notifications on new releases.