Enable the language extension FlexibleContexts by default.
BREAKING CHANGE Enable the language extension MonoLocalBinds by default. let and where bindings introducing polymorphic functions that are used at different types now need an explicit type annotation. Without the type annotation the type of the first use site will be inferred and use sites at different types will fail with a type mismatch error.
Java Codegen
Fix bug that caused the generation of duplicate methods that affected sources with data constructors with type parameters that are either non-unique or not presented in the same order as in the corresponding data type declaration. See #2367.
Ledger
H2 Database support in the Ledger API Server.
Sandbox
The sandbox now properly sets the connection pool properties minimumIdle, maximumPoolSize, and connectionTimeout.
https://daml.com/wp-content/uploads/2021/01/DAML_Logo_Blue.svg00Nemanja Memarovichttps://daml.com/wp-content/uploads/2021/01/DAML_Logo_Blue.svgNemanja Memarovic2019-08-29 10:15:002021-01-25 16:42:42Release of DAML SDK v0.13.21
This is a brief survey of possibilities when pattern matching records in DAML.
This will help those looking to learn about features enabling succinct expressions involving records as arguments.
We start with the following data declaration to give us something to work with.
Suppose we want to write a function that calculates the number of items on a stack.
Consider the “canonical” way of writing this function where we attempt to be as explicit as possible.
[Note : Rule of thumb for formatting “with” blocks – Always indent under the ‘with’ and always drop back when the block is finished.]
DAML allows us to inline the function’s type signature like this.
“Record field punning” (meaning, when the name of the variable coincides with the name of the field, you can omit it) is supported so we can remove the bindings of variable names and work directly with the field labels.
The field top is unused so we can elide matching on it.We can rewrite the above as a multi-equation equivalent (and we’ll drop the explicit type annotation for brevity).
We can get the second equation down to a “one-liner” by switching to “record brace” syntax.
Lastly, we can employ “record wild cards” in the second equation to bring the field labels of the argument into the scope of the right hand side so that we can write simply this.
DAML provides flexibility for expressing patterns over records allowing the modeler to find their own “right” balance between readability and conciseness!
Some issues that caused damlc test to crash on shutdown have been fixed.
The DAML compiler was accidentally compiled without optimizations on Windows. This has been fixed which should improve the performance of damlc and daml studio on Windows.
damlc build should no longer leak file handles so ulimit workarounds should no longer be necessary.
Allow more contexts in generic templates. Specifically, template constraints can have arguments besides type variables, if the FlexibleContexts extension is enabled.
DAML-LF
Breaking Rename NUMERIC back to DECIMAL in Protobuf definition.
DAML Studio
damlc ide now also accepts --ghc-option arguments like damlc build so damlc ide --ghc-option -W launches the IDE with more warnings.
The VSCode extension now has a configuration field for passing extra arguments to damlc ide.
DAML Integration Kit
Participant State API and kvutils was extended with support for changing the ledger configuration. See changelog in respective package.scala files.
Sandbox
Fixed a bug that caused the reset service to hang for 10 seconds. See issue #2549.
Java Bindings
The Java Codegen now supports parametrized ContractIds. See #2258.
Fixed a bug that prevented the ledger from loading transactions with empty workflow ids.
Fixed internal shutdown order to avoid dead letter warnings when stopping Sandbox/Ledger API Server. See issue #1886.
DAML Studio
Added a new command for visualizing a project in the IDE.
Print stack trace when a scenario fails.
Various memory leaks have been fixed so long-running sessions should no longer show a significant increase in memory usage.
DAML Compiler
The --project-root option now works properly with relative paths in daml build.
Support generic template declarations and instances. Documentation for generic templates is still being worked on.
The --dump-pom flag from damlc package has been removed as packaging has not relied on POM files for a while.
Navigator
{"None": {}} and {"Some": value}, where previously accepted, are no longer supported or used for DAML Optional values. Instead, for simple cases, use the plain value for Some, and null for None. See issue #2361 for other cases.
HTTP JSON API
A new, more intuitive JSON format for DAML values is supported. See issue #2361.
For damlc docs, the --template argument now takes the path to a Mustache template when generating Markdown, Rst, and HTML output. The template can use title and body variables to control the appearance of the docs.
DAML Assistant
Spaces in user names or other parts of file names should now be handled correctly.
The daml deploy and daml ledger experimental commands were added. Use daml deploy --help and daml ledger --help to find out more about them.
Fix a bug where daml studio did not launch VSCode on Windows.
BREAKING CHANGE Handwritten instances of Template and Choice typeclasses are no longer supported. All template constructs must be defined using declarations inside template syntax.
DAML Docs
The damlc docs command now produces docs to a folder by default. Use the new --combine flag to output a single file instead.
The damlc docs flag --prefix has been replaced with a --template flag which allows for a more flexible template.
The damlc docs flag --json has been dropped in favor of --format=json.
Extractor
BREAKING CHANGE Changed schema to accomodate removed field ExercisedEvent#contract_creating_event_id. Existing database schemas are not compatible anymore with the newer version. The extractor needs to be run on an empty schema from Ledger Begin.
Java Bindings
Add all packages of java bindings to the javadocs. See #2280.
BREAKING CHANGE Removed field ExercisedEvent#contract_creating_event_id. See #2068.
Ledger API
BREAKING CHANGE Removed field ExercisedEvent#contract_creating_event_id. See #2068.
Sandbox
The active contract service correctly serves stakeholders. See #2070.
Added the --maxInboundMessageSize CLI parameter to set the maximux size of messages received through the Ledger API. If the value is not set the current default is preserved (4 MB).
Makes package uploads idempotent and tolerate partial duplicates. See #2130.
This website stores cookies on your computer. These cookies are used to collect information about how you interact with our website and allow us to remember you. We use this information in order to improve and customize your browsing experience and for analytics and metrics about our visitors both on this website and other media. To find out more about the cookies we use, see our Privacy Policy OK
Privacy & Cookies Policy
Privacy Overview
This website uses cookies to improve your experience while you navigate through the website. Out of these cookies, the cookies that are categorized as necessary are stored on your browser as they are essential for the working of basic functionalities of the website. We also use third-party cookies that help us analyze and understand how you use this website. These cookies will be stored in your browser only with your consent. You also have the option to opt-out of these cookies. But opting out of some of these cookies may have an effect on your browsing experience.
Necessary cookies are absolutely essential for the website to function properly. This category only includes cookies that ensures basic functionalities and security features of the website. These cookies do not store any personal information.
Any cookies that may not be particularly necessary for the website to function and is used specifically to collect user personal data via analytics, ads, other embedded contents are termed as non-necessary cookies. It is mandatory to procure user consent prior to running these cookies on your website.