Changelog
All notable changes to this project will be documented in this file.
The format is based on Keep a Changelog and this project adheres to Semantic Versioning.
5.0.0 - 2025-03-07
Changed
Upgraded serialization library to 9.0.0.
Upgrade Kotlin to 2.1.
Minimum supported JDK is now 21.
4.1.0 - 2024-09-03
Changed
Upgraded serialization library to 7.0.0.
4.0.0 - 2024-08-07
Added
Support for observations in contracts has been added.
Support for observations in CSL scenario tests has been added.
Changed
Improved abstract expression analysises of less-than expressions.
Improved abstract expression analysises of application-expressions, which makes the analysis faster.
CSL Scenario-test now makes use of the
NormalContractrepresentation which implements deferred matching.Updated
com.deondigital:serializationto version 5.0.0.
Fixed
Fixed an issue that could lead to an infinite loop in contract analysis for very specific cases.
Fixed an issue where the unification done during expression analysis would fail to find a substitution.
Removed
Opaqueness control and tracking in expression evaluator has been removed.
Functionality to simplify an
Expvalue via “normalisation by evaluation” has been removed.Removed the webapp and API that supported the Vitznauerstock demonstration application.
Removed the
sic-rest-operationsand moved relevant wrapper classes tosic-preamble-core.Removed the possibility of generating TypeScript classes from CSL with
sic.
3.0.0 - 2023-12-07
Added
sicfor Kotlin includes an instance of acom.deondigital.serializationJson codec on the companion object for classes generated from CSL types.Static unfolding of
NormalContractvia a functionunfoldinto a tree-structure where prefix-predicates have been analyzed.
Changed
sicfor kotlin now adds a companion field onContractInstancewith the entrypoint of the contract.Minimum supported JDK is now 17. Was 1.8 previously.
Removed
Support for the Corda 4.x ledger backend has been removed.
2.0.0 - 2023-03-09
Added
CSL Language: Added an optional “prefix guard” to contract prefixes, which defines patterns that must match in addition to the predicate given by there
where-clause.The
sicGradle plugin now works with version 1.7.x of the Kotlin Gradle plugin.sicgenerates KotlincomponentX()methods on classes from record types that can be used in destructuring expressions.Added support for Corda 4.10.
Changed
Added support for trailing commas in CSL.
The
upgrade-from-0-82-0-to-0-83-0package has been renamed toupgrade-csl-corda-statesto reflect its more generic nature.Artifact repository changed from
https://repository.deon.digital/artifactory/releasestohttps://dl.cloudsmith.io/basic/deondigital/releases/maven/.
Fixed
Fixed a bug where the typechecker would crash if type variables were present in record field definitions.
Fixed a bug in generation of arbitrary dates, which prevented properties on
Datetype to be exercised correctly.
Removed
Removed the dependency on
com.github.kittinunf.fuel.
1.0.0 - 2022-09-05
No changes between 0.84.0 and 1.0.0.
0.84.0 - 2022-08-31
Added
Added a new target to
siccalledCompile. This target compiles the input CSL to a “CSL package”.Added documentation on application development explaining CSL integration.
Added new next-events analysis based on symbolic evaluation of expressions.
Changed
Some classes and top-level functions were moved to different packages to avoid package name clashes across jars. See the migration guide for details.
The
gradle-sic-pluginnow usessic compileto compile the CSL declaration. The name of the resulting artefact is now<sicNamespace>.declaration.cslpkginstead of<sicNamespace>.definitions.zip.The package
com.deondigital.core.logginghas been moved to a separate project. See the migration guide for details.siccan now only receive one command-line input at a time.siccan now be pointed to a folder with adeon-projector directly to thedeon-projectfile, instead of relying on globbing.sicnow has two sub-commands:generateandcompile.generatecan targetKotlinorTypescript.compileoutputs to stdout or acslpkgfile given with--output.generatecan take a new option--cslpkgpointing to a cslpkg file. If this option is given, theContractDetailsclass also contains a static val pointing to the cslpkg file.
The utility library for specifying benchmark workloads has been moved to a separate project. See the migration guide for details.
The package
com.deondigital.pretty-printhas been moved to a separate project. See the migration guide for details.The library for (de)serialization JSON and MsgPack has been moved to a separate project. See the migration guide for details.
Agent anonymization behaviour on Corda has changed:
All participants are always anonymized.
All agent values pointing to anonymized participants are always deanonymized when fetching events, calling reports and fetching instantiation parameters.
com.deondigital.cordapp.services.SetParticipantsAnswer.AuthorizeEnterContractis now an object instead of a data class.com.deondigital.cordapp.services.InstantiateContractAnswer.Authorizeis now an object instead of a data class.com.deondigital.cordapp.services.NovateContractAnswer.AuthorizeEnterNovationis now an object instead of a data class.The public documentation has been re-organized under topics for readability.
The vitznauerstock demo webapp no longer attempts to normalize where-clauses for residual contracts.
Fixed
Fixed a bug in
TypedJsonSum.restrictwhere an incorrect tag-value would be used. It caused.restrictto not work onapi.Value.Fixed a bug in mutually recursive contract bindings in
letblocks.
Removed
Removed the
CoreAST,Signature,OntologyandMetaDatatargets forsic. These are replaced by thecompilesub-command.Removed
JSONoutput support fromsic.Removed
com.deondigital.api.ExternalObject.CordaAgent.isConfidential.Removed
com.deondigital.sic.CordaAgent.isConfidential.Removed
com.deondigital.cordapp.client.CordaAgent.isConfidential.Removed
anonymize: Booleanparameter fromcom.deondigital.cordapp.services.SetParticipantsAnswer.AuthorizeEnterContract.Removed
anonymize: Booleanparameter fromcom.deondigital.cordapp.services.InstantiateContractAnswer.Authorize.Removed
anonymize: Booleanparameter fromcom.deondigital.cordapp.services.NovateContractAnswer.AuthorizeEnterNovation.Removed
compareAgentsByWellknownIdentitiesparameter fromContractHandler.report.Removed
agentToWellKnownparameter fromCordaEntityModule. Agents are now always compared by their well-known identities when possible.Removed
addReverseAgentMappingfromReportingManager.Removed
reverseAgentMappingfromcom.deondigital.corda.common.CordaEntity.toExternalObject.Removed
agentMappingsfromCachedTransactionChanges,TransactionChangesInLedger,CachedCSLContractState,InternalCachedCSLContractState, andVersionProvenance.Removed
reverseAgentMappingfromCachedCSLContractStateandInternalCachedCSLContractState.
0.83.0 - 2022-06-01
Added
Added a new Datalog engine, resulting in dramatically faster querying of relations.
Serialization: Added a helper function for restricting typed OpenAPI sum codecs to a single tag.
Serialization: Added functionality for versioning serialization MessagePack codecs.
Added an upgrade script to migrate Corda CSL contracts that were compiled with
sic0.82.*.CSL unit tests now support scenarios, which allow a contract to be tested against a series of events and assertions that it should support.
Add a
cslNameproperty to all record classes generated bysic. This property gives the CSL name of the record’s type.
Changed
The internal representation of environments has been split into global and local environments, making it no longer necessary to minimize closures when constructing function values. The evaluator APIs have been simplified as a result.
Fixed
Before,
CordaLedger.getAllContractIds()would return an immutable view on a mutable set. This meant that concurrent threads could mutate this seemingly immutable set. This method now returns a copy of the set instead.
0.82.1 - 2022-05-09
Fixed
Fixed a bug where a type error in the scrutinee of a
matchexpression would crashdeon-checkand the LSP server.Fixed a bug where
CachedCSLContractState.versionedEventswould show the empty sequence of events for any version after the version in which the total of applied events exceeded 2.Fixed a bug in clojure testing setup, where failing tests would not render correctly.
0.82.0 - 2022-04-05
Added
Support for a separate shared events cache in
CordaLedgerthat can be bounded in size in addition to the contract cache.Added an upgrade script to migrate Corda CSL contracts that were compiled with
sic0.81.0.CSL value definitions can be marked as properties, which enables them to be used for testing.
Added support for CSL unit tests, including the use of external test oracles such as Excel models.
sicnow also produces ameta-datafile containing the ABI version of its outputs.CSL stdlib: Added function
Map::isEmptyfor testing whether a map is empty.CSL stdlib: Added function
compfor composing two unary functions.CSL stdlib: Added function
viafor transforming inputs to a binary function before applying it.CSL stdlib: Added functions
compareDateandcompareTimefor comparing date and time, respectively.CSL stdlib: Added function
Maybe::map2for lifting a binary function to one inMaybe.CSL stdlib: Added function
Map::lookupOrDefaultfor a lookup in a map with a default value in case of failure.CSL stdlib: Added function
Map::toListfor turning a map into a list of (key, value) tuples.CSL stdlib: Added function
List::takeWhilefor taking a prefix of a list as long as a given predicate remains true.CSL stdlib: Added function
List::isSortedfor testing whether a list is sorted according to a given comparison function.CSL stdlib: Added functions
Ordering::twoStepandOrdering::lexicographicfor combining comparison function for more complex data types.CSL stdlib: Added functions
min,max,List::minimumandList::maximumfor finding maximum and minimum of two arguments or a list of arguments.CSL stdlib: Added function
List::containsfor checking whether a list contains a given element.CSL stdlib: Added function
equalfor checking whether two elements are equalCSL stdlib: Added a new built-in
NonEmptyListdata type with accompanying standard library functions.Added the
setParticipantsmethod toContractHandler.Added an RX
ObservablepropertyQueryMonitor.onUnanswerableRequestthat can be used to react to query monitor requests that are not answerable automatically with the givenRespondPolicy.Added configuration argument to
Queries.pastEventsto customize the order of the sequence of events.Added support for scoping
CordaLedgerto all CSL attachments that are compatible with a given main attachment.Added MessagePack serialization helper function
isoMsgPackCodec.Added a
matchexpression for direct pattern matching on expressions.Added a simple coarse-grained cache for CSL report results.
Fixed
Fixed a bug where the deferred matching engine would create very large runtime representations of some contracts and would crash for contracts with unbounded loops.
Fixed a bug where
addEventswould throwCordaRuntimeExceptioninstead ofRuntimeExceptionin certain cases of failed event application.Fixed a bug where a migration would cause reports with
compareAgentsByWellKnownIdentities=trueto change behaviour.Fixed a bug where a migration from and to the same declaration would cause the events before the migration to be listed in
pastEventsand therefore also in reports.Fixed a bug where methods to novate, terminate, authorize migration, migrate, and change contract participants finished before updating the cache.
Serialized timezones in the form of offsets are now supported. Previously, only named zones such as “Europe/Copenhagen” were supported.
Changed
CachedCSLContractStateno longer stores pre-materialized events.ContractHandlernow exposesCachedCSLContractStateHandlefrom its member functions instead ofCachedCSLContractStatewhich consists of pre-materializedCachedCSLContractStateobject in propertydataand functions to access required events for the contract.Queries.pastEvents()exposes aSequenceof past events that can be consumed lazily instead of a pre-materialized list.ContractHandlernow requires aCacheConfigurationobject to configure the contract and event cache when it is instantiated instead of a size object.Renamed
com.deondigital.cordapp.client.AttachmenttoClasspathCslCordaAttachment.gradle-sic-pluginno longer implicitly adds Deon dependencies.Renamed constructor argument
attachmentInfoincom.deondigital.cordapp.client.{CordaLedger, GenericContractHandler}toattachmentId.Moved
reportandnextEventsfromContractHandlertoCordaLedger. The methods still exist onContractHandlerbut simply delegate toCordaLedger.Moved the open method
cslCordappConfigfromContractHandlertoCordaLedger.QueryMonitor,UserAuthorizationOperations, andRespondPolicyhave been moved fromsic-preamble-coretocsl-cordapp-client.CordaLedgernow implementsUserAuthorizationOperations.ContractHandlerandCordaContractOperationsnow implementAutoClosable.All flows that modify the ledger contents return
LedgerUpdateFlowResultwith the original result accessible in the propertyvalue.ContractOperationSequenceResulthas a new propertyattachmentIdto signify the attachment the contract belongs to.Changed the syntax for polymorphic external declarations to be consistent with type variable binders in value definitions.
The serialization helper function
newTypeJsonCodecis now calledisoJsonCodec.Upgraded to Corda 4.9.
Removed
It is no longer possible to define recursive datatypes in CSL.
Removed the
targetandcslVersionconfiguration option fromgradle-sic-plugin.Removed the methods
setParticipants,migrateContract,authorizeMigration,terminateContractfromCordaLedger. Call the corresponding methods onContractHandlerinstead.Removed the method
CordaLedger.subscribeToUserQueryFeedin favour ofCordaLedger.trackUserQueries.Removed
CSLRequestandCSLAnswerfrom the packagecom.deondigital.sic. Use the corresponding classes fromcom.deondigital.cordapp.serviceswhich are almost identical.Removed the
attachmentIdparameter fromExecuteOperationsFlow,SetParticipantsFlowandTerminateContractFlow.
0.81.0 - 2021-11-09
Added
com.deondigital.sic.DbLedgerContractOperationsbackend for thesicContractOperationswrapper which connects directly to aDbLedger.Added the library
com.deondigital:mass-migrationwhich can be used to build interactive mass migration scripts of Corda CSL contracts.Extended the
contract-migrationexample with usage of the mass migration library.Added a new Corda flow
FetchCSLAttachmentswhich will list all CSL attachments on the Corda ledger along with some metadata.The
ContractHandlercan now migrate a contract to an attachment ID other than its own, by explicitly supplying the attachment ID whenmigrateContractis invoked.The package
com.deondigital.debugprovides graphical inspectors for values and environments, which can make it easier to understand running CSL code.The
VersionProvenancetype has been extended with 3 new constructors,MigrationAuthorized, Migrated, ParticipantsChangedto make it easier for consumers to determine the provenance of a contract version.Added more context to the error message provided when an event was rejected because the agent did not match.
The package
com.deondigital.pretty, in thepretty-printmodule, contains a Kotlin pretty-printing library.The module
deon-prettycontains pretty printers for some datatypes.
Fixed
Fixed a bug where identifiers that were only used mutually recursively by a
withbound expression were marked as unused.Fixed a bug where a
setParticipantscall would fail after a novation or batch operation.Fixed a bug where custom CSL Cordapp configurations would be ignored during contract migration.
Changed
Added a standalone flow to authorize contracts for migration.
Removed the use of contract termination as the first step of contract migration.
Renamed
com.deondigital.benchmarkpackage that exposes benchmarking utility classes tocom.deondigital.benchmarkingutils.Changed the methods of
CSLFLowsto returnFlowDispatchinstead of invoking flows directly. This allows callers to themselves determine how call the flows (e.g. tracked or untracked).Improved the error message when there are multiple or zero parties matching an identity in
ContractHandler.getParty.Changed the signature of
CSLCordappConfigure.createContractStateto receive an instance ofDefaultCSLContractStatein order to facility newtype style wrapping instead of reimplementing all fields ofDefaultCSLContractState.
0.80.0 - 2021-09-14
Added
CSL source code must always be written in the UTF-8 encoding (this formalises the existing state CSL practice).
All released JARs now contain the name and version of the package in the
META-INF/MANIFEST.MFfile.
Fixed
Fixed a bug in conversion of api.ListValue to clojure list. The conversion would result in a
LazySeqand not a properIPersistentListvalue.Fixed a bug where exceptions thrown whilst responding to a contract update would be swallowed. Note that to respond properly to exceptions in this case, you should provide a second argument to
Observable.subscribe.Fixed a bug on Corda where a failed event application would indefinitely hospitalize the responder flow.
The standard library is now embedded in CSL-related executables rather than being found in a separate file, making it even less likely that
--csl-std-libis necessary.
Changed
The classes in the namespace
com.deondigital.cordapp.clienthave been moved into their own Gradle artifact and therefore also out of the CSL workflows cordapp.All definitions from the
clojure-apilibrary have been moved into a newclj-apisubpackage.
Removed
Removed the type parameter from
ResponsePolicy.Always.Removed the
cproperty fromcom.deondigital.sic.CordaAgent.Removed the
CordaLedger.getInitialStatesmethod.
0.79.0 - 2021-08-10
Added
Added support for migrating running contracts to new declarations on Corda.
Added an example Cordapp project to demonstrate the usage of migration support.
Command-line CSL tooling can now automatically locate the standard library in more situations, making it less often necessary to pass the
--csl-std-liboption.
Fixed
Fixed a bug resulting in an exception when getting contract details after changing the contract participants.
Fixed a bug that caused the typechecker to crash if it encountered a non-wellformed type composed of types defined in different files.
Fixed a bug where you could not use the unqualified name of a recursive contract within its definition.
Changed
Changed the behaviour of the
SetParticipantsflow to reuse the existing anonymous identity for current participants of the contract that are also in the new set of participants.
Removed
Removed the helper CLI tool
attachment-uploaderfor uploading attachments to Corda nodes.
0.78.0 - 2021-07-28
Added
Add alternative runtime for CSL contracts implementing the “deferred matching semantics”. Under this semantics, events are applied at all enabled prefixes in the contract, as opposed to the state tree runtime which prematerely “cuts off” alternative branches as soon as a prefix matching the incoming event is found. The new API is available under the
com.deondigital.runtime.deferrednamespace.
Fixed
Fixed a bug where the Corda CSL cache would ignore all remaining output states from a vault update when an output state was encountered with a different attachment id.
Fixed a bug where
CordaLedgercould see and interact with contracts that were not instantiated with its associated declaration.Fixed a bug where the version number of a contract was incremented twice when terminated.
Changed
CordaLedgerandContractHandlernow exposes a singleObservableyou can subscribe to for all contract updates. The old subscription mechanism still exists but is deprecated.
0.77.0 - 2021-06-18
Added
CSL now emits a warning when a pattern is unreachable due to earlier patterns having exhausted the space of possible values.
The next-events analysis now allows some names to be declared “opaque”. Opaque names are only unfolded when said unfolding leads to a non-function value.
Changed
The
deon-language-runtimeproject now properly declares the dependency oncom.github.andrewoma.dexxasapi, so consumers no longer have to add this group asimplementationdependencies in Gradle.The LSP server binary for CSL has been renamed from
language-servertocsl-lsp-serverto avoid confusion.
Fixed
Fixed a bug where the Corda
GenericContractHandlerwould assume only one legal-identity for all nodes and crash in case there were multiple.Fixed a subtle variable scoping bug in the contract guardedness checker
Fixed a rare bug in
ResourceIndexedReadWriteLockManagerdue to memory visibility issues on lock cleanup.
0.76.0 - 2021-05-28
Added
DbLedger now has support for concurrent reads and writes to separate contracts.
Added auto-completion support for local definitions and qualified names relative to the module scope in LSP server.
CSL now requires that all pattern matches cover all possible cases
Added syntax for explicitly binding type variables in definitions.
Added support for referring to bound type variables in type annotations.
Changed
Upgraded Corda from version 4.5 to 4.8.
Fixed
Fixed a bug in the guard checker which incorrectly rejected contracts that made advanced use of templates.
Fixed a bug where top-level value declarations could shadow generated equality functions.
Fixed a bug in the Gradle
sicplugin that made it hide resource files inmain/resourcesfrom the JAR artifact.Fixed a bug where type constraints were not propagated under type constructors.
Fixed a bug where equality was allowed on polymorphic tuples.
Fixed a bug where equality tests on a type
Awould crash in standalone reports if no values of that type were equated in the declaration.Fixed a bug where relations could be redeclared.
0.75.0 - 2021-04-09
Added
Added support for module-relative references to CSL.
Added auto-completion support for top level and modules’ definitions in LSP server.
Added contract novation to DbLedger and Corda.
Added support for checkpointing of contract state tree to DbLedger.
Added
eventNamefield to theEventPredicateAPI object from/next-events.Added
clojure-apifor using CSL from Clojure. Includes conversions back and forth from Clojure values tocom.deondigital.syntaxandcom.deondigital.apivalues. Also a runtime library for instantiating contracts and evaluating expressions is included.Added support in CSL for adding custom built-ins via external declarations.
Added auto-completion support for record construction and projection in LSP server.
Fixed
Contract instantiations on DbLedger must have at least one participant.
Notifications to callbacks and replication requests in DbLedger are only sent if the changes to the underlying ledger are successful.
TypeScript code generated by
sicnow has type mappings for Corda contract IDs.OpenAPI supports authorization with a peer identity, allowing calls that require an agent identity argument.
Fixed bug in
sicthat stopped the code generation if the input CSL source contained a record or union type with a nested function type.Fixed a bug in the type checker that made it accept usage of derived equalities on types for which an equality function could not be derived due to nested function types or type variables.
Added missing classes to the serialization whitelist for the Corda runtime.
Corrected a bug in the initialization of the DbLedger connection to PostgreSQL.
Fixed a bug that would crash the demo webapp when using a contract id as an instantiation argument.
Fixed a bug in the webapp that would reset the list of entrypoints when a contract was instantiated.
Fixed a bug in the type checker that made it accept functions as map keys or set values, which would lead to runtime errors.
Fixed a bug in evaluation of certain builtins and “open values”.
Changed
Changed the caching of relevant data in DbLedger to be constrained based on cache size.
Kotlin-code generated by
sicnow depends on packagescom.deondigital:sic-rest-operationsand/orcom.deondigital:sic-corda-operationsto supply theContractOperationsand related types, instead of generating bespoke versions of them at each run.The next-events analysis now performs reduction on the returned where-clauses using a “normalization by evaluation” algorithm.
The
DeonWebservicenow takes the concrete agent identifiers as config parameters instead of auto-generating fresh ones.Cosmetic improvements to the demonstration webapp.
Sic now appends “Module” to the subtypes of
ContractModulethat it generates.The sic gradle plugin now checks the generated jar for Corda compatibility, if the target is Corda.
Contract lookup in
ContractOperationsreturnsnullinstead ofContractInstanceNotFoundwhen no contract with that ID exists. The exception type has been removed.Parser now also accepts empty fields in projection.
0.74.0 - 2021-02-18
Added
New types for working with calendars and time:
Period,Year,Month,YearMonth,Date,Time,DateTime,ZonedDateTimeandZoneOffset.Added support for terminating contracts on Corda.
Added support for the 1/1 day count convention.
Fixed
New implementation of the Actual/Actual ICMA day count convention
Fixed bug in
ExecuteOperationsFlowin Corda that allowed event applications on behalf of an agent who is not the proposer of the transaction when combined with contract instantiations.Fixed bug in
RestContractOperations.executewhere exceptions were not serialized correctly.Type checking in atomic operations.
Changed
The
DateTimetype has been renamed toInstant. There is still aDateTimetype, but it is different from the old one.Simplified core representation of template definitions.
Make use of explicit functions to construct a runtime representation from an entrypoint and a list of values instead of relying on building up a contract AST.
Don’t store contract AST in DbLedger in the
Contractstable.Made sidebar in the demo webapp scroll independently of the CSL editor.
Changed instantiation arguments to be a single value instead of list
EntryPoint,instantationArgumentandinstantationTimehave been moved toinstantationDetailsin theContractobject ofDeonAPI.
0.73.1 - 2021-02-15
Fixed
Fixed a bug that prevented applications to upload attachments to Corda nodes twice.
Made the artifact produced by the Gradle
sicplugin byte-for-byte reproducible.
Changed
Use compiled declarations for named reports instead of recompiling.
0.73.0 - 2021-01-20
Added
A CorDapp example showing integration between a CSL contract and the Corda Token SDK.
Added support for terminating contracts on DBLedger, which disallows applying further events on the contract.
Entrypoints must no longer be specified as a template. The form
contract entrypoint main = ...is now accepted.
Fixed
Type checking of contract instantiations has been fixed on Corda. Templates with missing
entrypointwere previously accepted but are now rejected. Entrypoints using the new contract lambdas for taking instantiation parameters were previously rejected, but are now accepted.
Changed
The Gradle
sicplugin now has the plugin idcom.deondigital.gradle-sic-plugin. This is the name that should be used in anapply plugin:section in a Gradle build script.The Gradle
sicplugin no longer builds a fat jar that includescsl-cordappandcsl-contracts-states. Instead, only the generated code and AST are included in the built jar.The demo webapp now has a drop-down with all entrypoints in a CSL declaration. Each entrypoint has a set of input forms derived from its parameter types for setting instantiation arguments.
All internal serialization has been changed from JSON to the binary MessagePack format. This improves serialization and deserialization of contract state by an order of magnitude.
QueryMonitor now responds to contract authorization requests from the query service (e.g., instantiation) in a non-blocking fashion and using its own threadpool to prevent concurrency issues.
0.72.0 - 2020-11-24
Added
Added the functions
Math::ceiling,Math::floor, andMath::roundto the standard library.Added support for atomic execution to DbLedger.
Added the conversion
Float::toIntto the standard library.Templates can now specify contract parameters that are contract functions.
Changed
Guarded recursive contract definitions are now allowed.
Template application now requires the contract-parameter list to be given. Previously, given
template T x = ...you could applyTwithT 42, omitting the empty list of contract arguments. Now, you have to writeT[] 42.Integers are now 64 bits, extending their range to the interval [-9223372036854775808, 9223372036854775807].
Subdivided the com.deondigital.cordapp package namespace into states, flows, services, resources, client subpackages.
Optimized execution of Corda flow (
ExecuteOperationsFlow) to minimize overhead of copying ledger state and parsing non-essential declarations.
0.71.0 - 2020-11-05
Added
Added a QueryMonitor class for handling contract instantiation requests in sic-generated Corda applications.
The
deon-projectfile format now allows single-line comments starting with#.You can now write contract-lambdas with pattern matching.
Fixed
Fixed a bug in the
gradle-sic-pluginwhich made it impossible to fetch dependencies that it injected into projects.
Changed
Template expression parameter syntax changed from
(a, b, c)toa b c. The current syntax is still valid but denotes a tuple parameter instead.
0.70.0 - 2020-10-16
Added
CordaLedger now supports specification of groups of operations (contract instantiations and event applications) atomically iff the operations span the same participants and notary.
CordaLedger now supports both anonymous and non-anonymous participants in contracts.
All contract instantiations in CordaLedger now require authorization by the client and are not automatically accepted as before.
The
sicgradle plugin now tracks changes to CSL files.siccan now open the “file”-which causes it to read from stdin.Added support for instantiating
SumandRecordtypes to the webapp.Added support for empty tuples.
Added the Unit type as an alias to the empty tuple.
The DbLedger can now distribute events and contracts to other read-only “subscriber instances” of DbLedger.
Added a new Maven package
com.deondigital.sicwhich wraps the sic binary for easier use in JVM based projects.
Fixed
Improved performance of the internal cache representation of events in DbLedger.
Corrected an issue with CSL project files not having trailing whitespace.
Fixed a bug in
sic/Kotlin that made it impossible to instantiate entrypoints inside amodule.Fixed a bug in the automatically generated equality functions for types involving a
typealiasparameter.Fixed a bug in
sic/Kotlin that caused the generated code to crash the Kotlin compiler when a sufficiently long CSL source text was embedded.
Changed
Renamed the built-in type
ContracttoContractInstance.Going forward, .jar artifacts are no longer published with a prefixed
vor-SNAPSHOTmodifier.Published .jar artifacts have been moved from nexus.deondigital.com to the Gitlab package registry. This requires an update to all build credentials.
0.69.0 - 2020-09-18
Added
The DbLedger now maintains a hash-chain on all events it stores to make it less easy to tamper with the underlying database.
Fixed
Fixed a bug that caused the DbLedger to not persist participant IDs correctly.
0.68.0 - 2020-09-10
Added
The standard library now has
String::isEmptyfunction.Built-in
Setdata type with accompanying standard library functions.A new API end point
/contracts/{id}/residualhas been added which can be used to examine the current state of a contract.EventPredicatenow contain aresidualContractand corresponding environment, describing the state of the contract after the event is applied.The Corda contract manager now supports changing the set of participants in a running contract. A flow for this purpose can be instantiated from the API.
The type checker will now emit warnings on unused local
val,contract, andtemplatedefinitions.
Fixed
Fixed a bug where
CordaLedger.contractIdwas not initialized with contracts that had one or more events applied.Fixed a bug in the runtime value type checker that made it not check
Mapvalues.Removed the
tagOrNulloverride in thejsonCodecforContractUpdateas it was dead code, after an update to thewebappwhich fixed an issue with needing a refresh after instantiating a contract.
0.67.0 - 2020-08-10
Added
Added methods for subscribing to contracts and events added on Corda.
Changed
Corda flows to collect signatures and generate new identities have been optimized to improve performance of contract instantiation and event application.
ContractOperations.getInstance now returns
nullwhen no instance is found instead of throwingContractInstanceNotFoundand throwsContractInstanceWrongTypewhen trying to get contract as typeAwhen the instance is actually of some other typeB.
0.66.0 - 2020-06-26
Added
sic-generated Kotlin classes for CSL datatypes now contain customtoString()methods.
Changed
DbLedger now supplies the triggering event in the
contractUpdatedcallback.CordaLedgernow caches contract ids so it will not fetch all initial states on each report.Corda contract manager: Corda was upgraded from 4.4 to 4.5.
Fixed
Fixed a bug where pagination errors appeared during contract event application when the number of contract instances in the ledger exceeded the default page size (200).
0.65.0 - 2020-06-19
Fixed
Fixed bug where the exception
CannotApplyEventonly contained the messagenullinstead of the list of errors. This makes log messages more useful.
Changed
Corda contract manager: Agents returned from reports are now identified by their well-known keys instead of their confidential (randomized, pseudonoymous) keys.
Corda contract manager: Applications can now run reports in a mode where agents are compared by their well-known identities instead of their confidential keys.
0.64.0 - 2020-05-28
Fixed
Fixed bug where
sicgenerated TypeScript would generate differentCordaAgenttype than used inapi-client.
Changed
DBLedger no longer checks for visibility/existence of contract-id values in inputs to reports. This is consistent with the behaviour on Corda.
The demo webapp now has UI components for creating CSL
Maps. The UI components for CSLListandBoolhave been improved.
0.63.0 - 2020-05-20
Changed
Contracts and events on the DBLedger are now only visible to peers that are participants of the contract.
The REST API has been split up into an anonymous API with endpoints that do not need the identity of the caller, and an identified API that does need it.
Fixed
Fixed a bug where
sicgenerated TypeScript would crash at runtime due to circular imports.Fixed a bug where
SecureHashinCordaEntitywas not serialized correctly. This broke contract validation for contracts containing contract ids.
0.62.0 - 2020-05-07
Added
sicgenerated TypeScript now includes aCordaAgentvariant ofAgent.
Removed
The “AST view” in the demonstration webapp has been removed.
The
/contracts/{id}/treeAPI endpoint has been removed.
Changed
sicnow generates a structuredAgentobject for TypeScript instead of astringfor CSLAgent.
Fixed
Fixed a bug related to Kryo serialization where a Corda node would crash while suspending a flow trying to persist the stack frame.
0.61.0 - 2020-04-29
Added
Support for fully validating contract manager on Corda that keeps the full contract state on the ledger and checks for event validity on every event application.
Support for batched application of CSL commands (instantiation and event application). Currently only batched event application are exposed by flows.
Support for versioning, indexing and querying on contract state fields.
Internal integration tests in
cordappsthat test contract verification, flows, vault storage and querying.It is now possible to publish generated CorDapps locally to make the development process simpler.
Removed
Unused resources model.
Changed
cordapp-examplesdo not use relocation any more.Simplified the implementation of the caches, flows, vault storage and retrieval functionality.
Fixed
Corrected a bug in the
gradle-sic-pluginthat caused it to fail when project files lacked a trailing newline.Corrected a bug in the
gradle-sic-pluginthat caused it to deadlock sometimes on MacOS.
0.60.0 - 2020-04-15
Changed
Upgraded Corda target platform from 4.0 to 4.4.
TypeScript code generated by
sicno longer addsequals/hashCodemethods onObject.prototype.Significant performance improvements to the evaluator and contract executor. Tail-recursive contracts no longer get slower over time.
Fixed
Fixed a bug related to Kryo deserialization where a Corda node would crash if resuming a flow from a persisted snapshot.
Fixed a bug in the derivation of derived equality functions that caused runtime exceptions when one derived an equality function for a constructor with fixed type parameters.
0.59.0 - 2020-03-27
Changed
The TypeScript code generated by
sicnow has better support for theimmutable-jsdata structures, in particular theimmutable.Mapthat CSL maps are represented as.sicgenerated contract operations for DbLedger now returns tags when applying events.Event agents are now validated against contract participants on DbLedger.
Fixed
The automatically generated equality functions do not depend on the standard library anymore.
0.58.0 - 2020-03-09
Added
sicnow generates TypeScript classes for template entrypoints, including a staticinstantiatemethod.
Changed
CSL reports that are called externally (with, e.g.,
sic) must be marked with the newreportkeyword.Contract templates that are used as entrypoints (from, e.g.,
sic) must be marked with the newentrypointkeyword.Event application on the DbLedger through the API now always return a tag. Previously it was only when a tag was included in the input.
Fixed
Corrected a substitution bug the in report query language that caused wrong results whenever a variable unified with a term which itself contained variables.
Corrected an issue in DbLedger that caused wrong external symbols to be used in event application.
0.57.0 - 2020-02-21
Added
The
deondigital/vitznauerstockDocker image now includes drivers for PostgreSQL.sicnow exposes a fieldinstantiationTimeonContractInstanceobjects.The TypeScript code generated by
sicnow contains copy methods with named parameters for classes which represent CSL records.Built-in
Mapdata type with accompanying standard library functions.sicnow generates Kotlin classes for template entrypoints, including a staticinstantiatemethod.
Changed
The performance and disk usage of the DbLedger backend has been improved.
0.56.0 - 2020-02-10
Added
The Deon webservice now has the endpoint
/declaration/{id}/namedReportfor invoking a report in a declaration by its qualified name and a list of value arguments.
Changed
sicnow reports aContractInstanceNotFoundinstead of a general exception if a non-existing contract id is used ingetContractInstance.the
sictypeContractInstancenow includes a function for retrievingnextEventsfor a contract.nextEventsnow include the event predicate and agent as anExptype.
Fixed
Corrected a bug in the type checker that caused it to fail to reject
=on records that contained fields for which we cannot use=.Corrected a bug that caused lists that are returned from queries to be wrongly encoded, thereby causing runtime errors.
0.55.0 - 2020-01-28
Added
Signature backend to
sicthat emits as JSON the types of all top-level declarations.
Changed
The API endpoints for running reports have been moved from
/contracts/{id}/report(/contracts/report) to/declarations/{id}/report(/declarations/report), reflecting the fact that running a report requires just the declaration, not an instantiated contract.The object that represents an instantiated contract now includes the peers that were specified on instantiation.
Fixed
Fixed a bug that caused the surface-to-core translation to crash if one used
=on a type alias for a built-in type.
0.54.0 - 2020-01-15
Added
sicand thegradle-sic-pluginnow supportdeon-projectfor Corda and Kotlin.
Changed
The equality operator
=now works on any closed type that does not contain function orSignedtypes.
Removed
The standard library functions
Int::equals,Float::equals,String::equals, andDateTime::equalshave all been removed.
0.53.0 - 2020-01-09
Added
New asynchronous API client.
Changed
Update the
RESTContractOperationsgenerated bysicto use the asynchronous API client.Reports and contract entrypoints that can be called from the outside must have monomorphic types.
Fixed
It is now possible to pass record values that are subtypes of the expected argument value to reports and template instantiations.
0.52.0 - 2019-12-03
Added
CSL now supports type annotations on top-level
valdeclarations:val x : Int = 42.
Changed
The
sicemitters for Kotlin and Corda now generate wrapper classes for the ledger-specific representations ofAgentandContractIdto make it possible to use the same code on top of both DBLedger and Corda.The API type
Contractnow contains the fieldsentryPointandinstantiationArguments.The
sicemitters for Kotlin and Corda generate theContractOperationsinterface andRESTContractOperations/CordaContractOperationsimplementations which can be used to interact with thesic-generated contract API in a ledger-agnostic way.
0.51.0 - 2019-11-22
Added
The TypeScript code generated by
sicnow contain factory methods for creating objects with named parameters.The Kotlin code generated by
sicnow contains copy methods with named parameters for classes which represent CSL records.CSL now supports type aliases:
typealias MyType a = Tuple a Int.
Changed
Ontology backend to
sicwas changed to output only type definitions instead of the internal contract descriptors ofsic.Code generated by
sicnow inspects API values for their actual types when deserializing, instead of statically deserializing values to their indicated type. This means that a recordMyEventcan be correctly deserialized from a value that is statically typed asEventbut dynamically tagged asMyEvent.The
gradle-sic-pluginhas been updated to better handle multiproject builds.
0.50.0 - 2019-11-08
Changed
The
csl-pluginhas been removed. It is superseded by the new gradle plugingradle-sic-plugin.sicoutput is now available when using--infowith the gradle plugin.
Fixed
sicno longer generates optional parameters for the TypeScript target which caused problems when mixing optional and required parameters.
0.49.0 - 2019-10-29
Added
New record extension syntax for carrying over some of the fields of an existing record into a new one:
R { use x with a = 1, b = 2 }.
Fixed
Corrected a bug that prevented instantiation of contracts with
sicgenerated code on Corda nodes.
0.48.0 - 2019-10-24
Added
DateTime::dayCountFractioncan now handle theAct/Act ICMAconvention.
Fixed
Corrected a bug in
toContractASTthat caused a crash when working with nullableorbranches.
Changed
The concept of “pseudo value” has been removed in favor of “external objects”. Bound names are no longer to be specified for agents, contracts, etc. represented as CSL values.
The
DateTime::dayCountFractionfunction now only takes one parameter. The usualfromandtoparameters should now be applied to the convention constructor. I.e.DateTime::dayCountFraction (DateTime::ActActISDA #2007-12-28# #2008-12-28#).
0.47.0 - 2019-10-10
Fixed
Corrected a bug in
DayCountFractioncalculations that occurred when start and end dates are in the same year.Fixed a bug in
sicthat caused it to not generate code for reports and entry points that use one of the built-in types as input or output types:Ordering,DateTime::DayOfWeek,DateTime::Components,DateTime::DayCountFraction,Event,Duration::Components,RuntimeError.
0.46.0 - 2019-09-27
Removed
The
sic-maven-pluginhas been removed. It is superseded by the gradle plugincsl-plugin.The standard library function
getEventshas been removed.
0.45.0 - 2019-09-03
Fixed
Corrected a bug in
DateTime::dayCountFraction.
Changed
Renamed
DateTime::dayCountFractionconventionThirty360ISMAtoThirty360ICMA.
Added
A list of past events was added to the contract view in the webapp.
0.44.0 - 2019-09-03
Added
Added the standard library function
DateTime::dayCountFractionthat calculates Day Count Fraction for a number of conventions.
Changed
The
sic“JSON” emitter has been renamed to “CoreAST”.
Fixed
Corrected a bug in the publication settings for one of the JAR dependencies which caused the generated CorDapps to break.
0.43.0 - 2019-08-19
Added
Ontology backend to
sicthat emits as JSON the intermediate contract descriptor used by thesicemitters.
Changed
The
sic-generated Kotlin code does not generate aninterfacewith*Implclass implementations, but just the class implementations directly without the*Implsuffix.The structure in multi-file
deon-projects is now more closely reflected insic-generated TypeScript/Kotlin code.Both the TypeScript and Kotlin code generated by
sicintroduces anaddDeclarationfunction for putting a CSL declaration on the ledger. The instantiation classes now require a declaration id in their constructors.When
sicoutputs the JSON-representation of an AST to standard out it does not include the separator strings that are invalid JSON.
Fixed
Corrected a bug in the build setup that rendered the Maven-published JAR of
deon-api-clientunusable.
0.42.0 - 2019-08-05
Added
The LSP server now supports go to definition.
Added an endpoint
contracts/<contractID>/eventsto get the event that have been applied to a contract.
Changed
sicnow writes multiple files instead of merging everything into one file. Dependencies onsicgenerated files will have to be updated accordingly: For TypeScript, the files are renamed; and for Kotlin projects, the generated namespace has changed.The helper functions for serialisation/deserialisation generated by TypeScript backend in
sichave been refactored, sosicusers will need to make a few changes to their TypeScript code. Instead ofmkXValueandgetXthere are now methodsX.toValueandX.fromValue. AlsogetAgenthas been replaced byAgent.fromValue.
Fixed
Corrected the code that converts
StateTreebased residual contracts to their abstract syntax form.
0.41.0 - 2019-07-10
Added
The Visual Studio Code plugin now shows type information on mouse hover.
Fixed
Made sure the Gradle plugin for generating CorDapps includes everything needed to generate them correctly.
Fixed a bug in the TypeScript emitter of
sicwhere records using TypeScript keywords as field names would not function properly.
0.40.0 - 2019-06-28
Added
Initial version of the new Datalog-inspired query language.
Gradle plugin to generate self-contained CorDapps directly from CSL code.
A new backend to
sicthat emits parsed and compiled CSL syntax as a JSON-file.
Changed
Upgraded Corda to 4.0.
Upgraded Kotlin runtime to 1.2.
Removed
The generic Corda ledger backend has been removed.
The Hyperledger Fabric ledger backend has been removed.
The special treatment of
Evidencerecords has been removed from the Corda backend.The example oracle implementations have been deleted.
The
InMemorybackend has been removed. It’s superseded by theDbLedgerbackend.
Fixed
Fixed an issue where the service would fail in an unexpected way when fed with certain invalid
DateTimes.Fixed an issue where in some cases the type checker would not report error messages in expressions involving records.
0.39.0 - 2019-04-26
Changed
Added support for simple simplifications of contracts. The simplifications are used for the contracts presented in the webapp in the “Actions” and “Viewer” tab.
Fixed
Fixed an issue where lists in events (records) constructed from the webapp would not be handled correctly.
Fixed an issue where the type checker would allow complex patterns at top-level. This is no longer allowed as it was in the old type checker.
0.38.0 - 2019-04-11
Fixed
Fixed an issue with floating point equality where numbers were not normalized.
Functions can now be serialized which makes it possible to call templates with functions as arguments.
Changed
Contracts are now represented more efficiently on the ledger.
The evaluator uses a new approach with a global environment instead of closures.
0.37.0 - 2019-04-10
Fixed
Fixed an issue with floating point arithmetic operations where they would not use decimal128 rounding.
0.36.0 - 2019-04-09
Fixed
Fixed an issue where the type checker would crash instead of reporting an error when a constructor pattern missed an argument.
Fixed an issue where the language server would report errors in the wrong file.
Changed
The underlying representation of floating point numbers was changed to decimal128 from binary64, allowing more exact financial calculations.
0.35.0 - 2019-04-05
Fixed
Fixed an issue where a unary minus was not pretty printed correctly.
Fixed an issue with applying events to contracts with inner lets
Changed
sicfor TypeScript now generates classes instead of type aliases for records.
Removed
Removed the
corda-lightledger backend. It was not being used and was obstructing further developments and randomly failing CI.
0.34.0 - 2019-03-21
Fixed
Fixed an issue in the new type checker where record projection, upcast and type case did not work as expected in certain cases.
0.33.0 - 2019-03-21
Changed
The type checker was replaced. It reports multiple error messages and returns an AST annotated with types.
0.32.0 - 2019-03-15
Changed
The
sictool now shows warnings on the console when it cannot generate entrypoints.We now disallow shadowing of names in CSL. Shadowing is only disallowed within each name kind. That means value expression names cannot shadow other value expression names but contracts and values can still use the same name.
0.31.0 - 2019-03-12
Fixed
Fixed a bug that caused a significant slowdown when evaluating some reports.
Changed
Record types in
sic-generated code implements the subtyping hierarchy of the CSL source with native target language constructs.
0.30.0 - 2019-03-07
Fixed
Fixed an issue that caused the project structure of
deon-projectfiles to not be respected in some scenarios.Fixed a bug in the webapp where it would crash when adding a boolean argument to a report.
Fixed an issue in the webapp where the wrong declarations were used for instantiating contracts in certain cases.
Changed
The contract composer in the webapp has a new layout.
0.29.0 - 2019-02-26
Added
Added
sic-support fordeon-projectfiles.
Fixed
Fixed a bug that caused type errors in
sic-generated TypeScript code with tuples.Fixed a bug that caused
/simplifyto crash on certain combinations of contract-parameters and pseudo-syntactic values.Fixed a bug in the agent matching algorithm that made it problematic to have agents with numbers in their name, such as
agent1andagent2.Fixed a bug in the webapp that prevented instantiation of contracts with multiple contract ID parameters.
Fixed a bug in the webapp that made it crash when attempting to provide a
DateTimeargument to a report.Fixed a bug in the webapp where the contents of AST nodes could overflow if it was too large - now the full content will only be visible when the mouse is hovering over the node.
Changed
Declarations are identified by content hashes (SHA-256) instead of UUIDs.
Upgraded Fabric to version 1.4.
The data model for check errors (type errors, parse errors, etc.) has changed. See OpenAPI specification for the new model.
0.28.0 - 2019-01-15
Added
Add support for heterogeneous tuple values in CSL.
Added support for event tags in
sic. Kotlinsicusers will need small adjustments to their code.
Fixed
Fixed an issue with serialization of websocket values.
Fixed a performance issue in the
/contractsendpoint that caused it to compute a lot of unnecessary data.
Changed
Updated the cache policy for static resources such as documentation and examples to prevent browsers from showing outdated versions.
Updated webapp to react 16.7.0
Changed default database backend from H2 to SQLite for the DBLedger.
0.27.0 - 2018-12-13
Fixed
Fixed duplications of agents on agent list on Fabric.
Fixed too liberal type checking of signed data.
Changed
Upgraded Corda to version 3.3.
Removed dependency on Jackson and improved performance of JSON serialization.
0.26.0 - 2018-12-03
Added
Added support for signing of structured data.
Fixed
Fixed an issue with instantiation with pseudo-syntactic values in records or lists.
Changed
Updated API specification to OpenAPI 3 format. The specification endpoint is changed from
/v2/api-docsto/openapi.json.
0.25.1 - 2018-11-23
Fixed
Fixed a rendering issue with contract ids in the instantiation UI.
0.25.0 - 2018-11-22
Added
Added the power and square root functions;
Math::powandMath::sqrtto the standard library.
Fixed
sic: Fixed a bug in the conversion of values in the TypeScript backend.Fixed broken link to PDF language guide in the HTML language guide.
Corrected an error in the UI Actions tab.
0.24.0 - 2018-11-19
Changed
sic: It is no longer necessary to wrap contract ids in the Kotlin interface for reports and event application.Changed layout of instantiation screen to handle templates with many arguments in the UI.
Fixed
Fixed a bug that caused the Kotlin API client to break when it was initialized with a request timeout.
Fixed a bug when serializing durations with jackson.
0.23.0 - 2018-11-07
Changed
sic: Event application functions in Kotlin and TypeScript are no longer lower-cased but follow the capitalization of their CSL types.
Fixed
Fixed a bug in the TypeScript backend to
sicthat caused reports that returnPairorMaybevalues to fail at runtime.Fixed a bug with event application that would sometimes cause a “variable not found in environment” error.
Fixed a bug in the Kotlin backend to
sicwhere the result would not compile when agents were compared.
Removed
The “Apply Event as Text” button has been removed from the webapp because it is no longer possible to construct an event value within the syntax of the language.
0.22.0 - 2018-10-10
Added
A new instantiation argument which resolves to the id of the instantiated contract has been added.
The Visual Studio Code extension now supports projects spanning multiple CSL files (see the plugin’s README for more information).
Tutorial section about the tool
sicto the language guide.
Fixed
Fixed a bug that caused Corda nodes to fail when using lists in events.
Changed
Agents in contracts are no longer strings, but are abstract values issued by the ledger. Use the new
/agentsAPI to retrieve the available agent values.It is no longer possible to use the special variable
eventsto refer to the events of the contract instance; usegetEventsinstead.Contracts::getEventshas been renamed togetEvents.It is no longer possible to redeclare top-level value bindings.
Contract ids are no longer strings but instead abstract values of the type
ContractIdthat cannot be constructed in syntax.
0.21.0 - 2018-09-21
Added
Web UI: Contract ID selector in “Reports” tab.
It is now possible to specify a separate
peerslist for each contract instantiation in the code generated bysic.
Fixed
Fixed a bug where the webapp could not apply events containing data with qualified sum types.
Fixed a bug in
sicthat caused empty CSL records to be handled wrong.
0.20.0 - 2018-09-14
Added
Lightweight implementation of Corda adapter where the notary is only used to ensure consensus on the ordering of events for contracts and not validity of the sequence of events.
Added ISO 8601 compliant syntax for duration literals.
Added built-ins and standard library functions for working with durations.
Fixed
Cucumber: ContractIDs are replaced in the expected results of Report tests.
Fixed a bug in the scoping of event bindings in prefix expressions.
0.19.0 - 2018-08-31
Added
TypeScript backend to
sic.Upgraded Corda to version 3.2.
Upgraded Fabric to version 1.2.
Added support for Fabric in deployment-tool.
Support for batching in Kotlin-client.
Changed
It is now only possible to query
Contracts::getEventson contracts that are instantiated from the same declaration ID as the caller.Updated the formatting and structure of the CSL language guide and reference.
Fixed
Fixed a bug where agents represented by variables could be shadowed by bound event names.
Fixed a bug in the serialization of contracts.
Fixed a bug in
sicthat caused Kotlin code generated from CSL that usedFloats to break.Fixed a bug in
sicthat caused it to generate invalid code due to keyword name clashes.Fixed a bug in the corda-adapter that could break the client-to-node communication under high load
0.18.0 - 2018-08-13
Added
Deployment tool.
The code generation tool
sicfor automatically generating a Kotlin interface for a CSL contract.
Changed
Upgraded Corda to version 3.1.
Fixed
Fixed a bug that crashed the UI if the residual contract could not be computed.
Fixed a bug where lists of events could not be converted from the internal to the external representation in some cases (like
List::append events events).Fixed a bug in the web UI where events could not be applied as raw text.
0.17.0 - 2018-06-25
Added
The API methods
/contractsand/contracts/{id}now return the instantiation time of the contract.The standard library now has a
Maybe::bindfunction. See the documentation for details.A built-in function
error : RuntimeError -> ahas been added.
Changed
The API methods
/contracts/reportand/contracts/{id}/reportnow accept an optional list ofValues that can be used as arguments for reports that take parameters.
Removed
The REST API clients have been moved to GitHub.
Fixed
A bug which caused the type checker to refuse references to previously declared templates from locally defined templates has been fixed.
A bug where the simplifier would cause run-time errors to disappear has been fixed.
Corrected a bug where server side errors could break the UI.
0.16.0 - 2018-06-05
Changed
The syntax for declaring contracts, templates and values has been changed. Recursive contract templates now have to be explicitly marked as so, and mutually recursive templates must be declared together. See the language guide for more information.
The
Add eventbutton has been removed from theViewermenu as it duplicates the functionality onActions. Events can be added as raw text fromActionsnow.Removed the API method
/parse-valuethat was equivalent to/reportin taking an expression as string and returning aValue.Renamed the
/contract/{id}/simplifiedendpoint to/contract/{id}/srcendpoint and added an optional parametersimplifiedsuch that/contract/{id}/src?simplified=truereturns the simplified residual contract and/contract/{id}/srcreturns the non-simplified residual contract.
Fixed
Fixed an issue in the (Kotlin) implementation of
applythat could result in a crash from a stack overflow.
0.15.0 - 2018-05-28
Added
The UI now displays the current version number.
Changed
Performance of the CSL parser has been improved.
Performance of report and expression evaluation has been improved.
The endpoints
/check,/check-expression, and/parse-valuewill now run type check on successfully parsed declaration parts even if there is a parse error later.
Fixed
Fixed a bug where the Visual Studio Code plugin was not in contact with the parser and type checker.
0.14.0 - 2018-05-17
Added
The standard library now has
List::isEmptyfunction.
Fixed
The in-memory ledger and database-backed ledger backend now correctly handle tagged event application.
Changed
The Node.JS and web REST clients now support optional tags for
applyEvent.Performance of the
/checkEventendpoint has been improved.
0.13.0 - 2018-05-14
Added
Events are now type checked before being applied to contracts.
The web editor now supports comment toggling with
Cmd-/orCtrl-/.Standard library function
DateTime::dayOfWeekthat gives the day of week (DateTime::DayOfWeek) for aDateTime.
0.12.0 - 2018-05-07
Added
The ontology for a CSL program now includes sum types in addition to record types.
New event input form in “Actions” tab.
New database-backed ledger backend with support for H2 and SQLite.
Node.js REST client.
Added new endpoints to submit contracts and events in batches for faster execution
Convenience function to JavaScript SDK for handling
Valueobjects as JSON data.
Fixed
Fixed a bug where applying many events to a contract could cause an exception.
Fixed some bugs where a couple of endpoints in the API client NPM package did not work.
Fixed bug where contract instantiation would result in an illegal contract due to a bug in the implementation of scoping.
Changed
Moved endpoint to simulate events, and added the possibility to simulate events across multiple contracts.
When running reports, the optional parameter for declaration id is now an optional path parameter. The client SDK has been updated to reflect this.
0.11.0 - 2018-04-24
Added
Shorthand syntax for
DateTimeliterals in CSL. The following all denote the same point in time:#2018#,#2018-01#,#2018-01-01#,#2018-01-01T00#,#2018-01-01T00:00#,#2018-01-01T00:00:00#, and#2018-01-01T00:00:00Z#.Added “guardedness check” to ensure that contracts do not contain infinite recursion.
Support for unary minus.
Fixed
Fixed a bug where the UI’s pretty printing of
DateTimevalues were not syntactically valid.Fixed bug where contract instances in the web app AST view were not simplified.
Fixed bug where the order of arguments to constructors were reversed when converting from value to expression.
0.10.0 - 2018-04-18
Added
Contract abbreviations can now be defined in
letblocks and top-level definitions.Contract templates with no contract parameters can now also be defined using the
templatekeyword.CSL extension to Visual Studio Code.
Node.js package with an API client.
Contract examples are now available in the UI.
Report examples in the language guide.
Added type checking to contract instantiation, preventing you from passing illegal arguments to contracts.
Added the possibility to run a simulation of event application without modifying a contract on the ledger.
Fixed
Fixed an issue where contract names and module names could be in conflict, thus causing bugs when applying events to those contracts.
Changed the parser such that ranges of tokens don’t include trailing whitespace.
Changed
It is no longer possible to do comparison of strings like
"a" > "b".Locations in error messages have been improved to be more specific.
0.9.0 - 2018-03-21
Added
Standard library extended with
Int::toStringfunction.
Changed
The
/contracts/{id}/next-eventsand/contracts/{id}/treeendpoints will no longer surround agent matcher with<and>.
Fixed
Fixed an issue where result values from report evaluation were not rendered correctly.
Fixed an issue where cross origin resource sharing (CORS) headers were not included in the webservice HTTP responses.
Local contract and template declarations would not overwrite global ones in the type checker.
0.8.0 - 2018-03-13
Added
The UI now has a link to the OpenAPI (Swagger) documentation for the webservice API.
Added GET
/declarations/{id}endpoint to the webservice API.Reports and values are now type checked.
Evaluation of reports independently of specific contract instances:
Added POST
/contracts/reportendpoint to the webservice API for evaluating reports.“Reports” tab in UI has been updated with option to evaluate reports independently.
The standard library now has
String::appendfunction.
Changed
The webservice API has been refactored and documented:
Input/output models have new names, e.g.
DeclarationandContractinstead ofNamedCSLandNamedContract.Contracts can only be instantiated with a declaration ID - not with a CSL string.
Contract AST are now retrieved through
/contracts/{id}/tree.Next events for contracts are now retrieved through
/contracts/{id}/next-events.Endpoints now return HTTP codes 4XX when the input is invalid, e.g., 404 for invalid ID’s, 400 for failed type checking, etc.
Input bodies are always objects with named fields.
/templatesendpoints are now/declarationsendpoints./peersand/ledgerInfohave been merged to/node-info./cslis now/csl/check./parseReportis now/csl/check-expression./valueis now/csl/parse-value./{id}/ontologyis now/declarations/{id}/ontology./contract/{id}/reportis now/contracts/{id}/report.OpenAPI (Swagger) documentation has been updated with examples and data models.
Qualified named for
Records,Lists,typesare now sent as structured objects instead of strings, e.g.A::ais now{qualifier: ["A"], name: "a"}.
The UI now refers to “declarations” instead of “templates”.
Removed
The DELETE endpoints
/contracts/{id}and/templates/{id}have been removed from the webservice API.
Fixed
Fixed an issue where a contract could not be instantiated if a type with the same name is present.
Fixed an encoding issue where some characters could not be used in CSL.
Fixed a bug in the type checker where sum type constructors inside modules where globally scoped.
0.7.1 - 2018-03-12
Fixed
Fixed concurrency issue in InMemory-ledger.
0.7.0 - 2018-03-06
Added
Structural equality relations for lists of base types added to standard library.
List shorthand:
[1,2,3]is shorthand forCons 1 (Cons 2 (Cons 3 Nil)).Upcast annotation (
:>) for records, telling the type checker to consider a record expression as a super record, e.g.DeliveryEvent {...} :> Event.
Fixed
Fixed issues in relation to expansion of templates.
template[c] Foo() = (<*> E then success) then cwould not work as expected.Fixed issue where
((<*> E then success) or success) then Cwould acceptCand become((<*> E then success) or success) then successbut it should have become simplysuccess.
0.6.0 - 2018-02-23
Added
The UI now has a link to the language guide.
The UI now has a link to the change log (this document).
The language guide now contains a grammar for CSL.
Changed
Upgraded Corda to v2.0.0.
Changed keyword
failtofailurefor consistency withsuccess. Bothsuccessandfailureare nouns.Prefix contracts do not include the
thenkeyword. Therefore, the following two are now equivalent<*> Eand<*> E then success.
Fixed
Fix a serialization issue between
FabricLedgerServiceandchaincode.Removed argument field names at instantiation.
0.5.0 - 2018-02-13
Added
Support for the submission of event subtypes from the web UI if the contract’s ontology specifies them.
Added new ledger service
FabricLedgerServicethat supports CSL runtime on Hyperledger Fabric.Serve language-guide with webservice (http://webservice:8080/docs/guide.html).
Parse and type errors are now highlighted in the web UI.
Changed
The
Ordertype in the standard library has been renamed toOrdering.
Fixed
Significantly improve the speed with which contract source code is printed (roughly ~100x). This should improve the performance of cucumber tests.
Fix a bug that made it impossible to instantiate contracts with
DateTimeparameters in the web UI.
0.4.0 - 2018-02-06
Changed
Updated the CSL standard library to version 0.2, with the following changes:
Renamed module
TimetoDateTime, andTime::TimeComponentstoDateTime::Components.Added
DateTime::addDays.Added general combinators:
id,const,flip.Added
Pair, and projection functionsfst,snd.Added
Maybewith functionsmaybe,fromMaybe,Maybe::map,Maybe::isDefined,Maybe::any,Maybe::all.Added
compareInt,compareFloat, andcompareDateTime.Added the following functions to
Listmodule:head,headOrDefault,tail,length,map,mapMaybe,filter,zipWith,any,all,first,last,append,concat,reverse,take,drop.Added documentation.
Indentation and formatting.
The value parser now uses CSL2 syntax. This means events should be entered in CSL2 syntax with uppercase constructors e.g.
TrueFalseNilandCons.
Removed
The CSL1 language level.
Fixed
Fix a bug that caused the ontology viewer to not be shown when a record type explicitly specified
Recordas its parent.
0.3.0 - 2018-02-05
Added
In
com.deondigital.apiaConstructorValueis now available to create and read CSL-constructors applied to argument values.Record subtyping, so that a record subtype can match the type pattern of its supertype, and an event subtype can be applied to a contract accepting its supertype.
Fixed
The reports tab would report an error when the result of a report contained any constructor which was not
True,False,NilorCons.