This is necessary to at least attempt an upgrade to 2.13 and
generally, I want to keep our rulesets up2date. rules-scala forces the
version of scalatest so we have to bump that at the same time.
This requires changes to basically all Scala test suites since the
import structure has changed and a bunch of things (primarily
scalacheck support) got split out.
Apologies for the giant PR, I don’t see a way to keep it smaller.
changelog_begin
changelog_end
We have a builtin SBConsMany use to concatenate a list with a prefix
of variable size. Its appear that most of the concatenation happens
with only one element. For this reason we add a new builtin to handle
the most efficiently possible the case with 1 element.
CHANGELOG_BEGIN
CHANGELOG_END
CHANGELOG_BEGIN
- [DAML-LF] Some types that were deprecated in DAML 1.4 have been
removed. Please fix any deprecation warnings by using the new types
before upgrading.
CHANGELOG_END
* Bazel: Reduce the visibility of some Protobuf targets.
* Bazel: Make Protobuf JAR visibility parameterizable.
Default to private, and explicitly make it public where it's needed.
CHANGELOG_BEGIN
CHANGELOG_END
* Tail-recursive function definitions execute with bounded environment and continuation stacks.
changelog_begin
changelog_end
* be more precise about the throw exception; use thrownBy
* add test for the KFoldr1Map/Reduce case
* Multiple submitters field for Command
* Multiple submitters field for Engine API
* Tests for multi-party submissions in Engine
* Make use of multi-party Engine capabilities in the engine benchmark
* Enable multi-party submission in Engine's API
CHANGELOG_BEGIN
CHANGELOG_END
* Separate unit tests for multi-party engine
* Unit tests for multi-party submission transaction replay
* ledger-api: Use `proto_jars`.
CHANGELOG_BEGIN
- [Ledger API] The Scala JARs containing the gRPC definitions no longer
contain the *.proto files used to generate the ScalaPB-based classes.
CHANGELOG_END
* Create a source JAR for *.proto files in `proto_jars`.
* ledger-api: Publish the protobuf sources as "ledger-api-proto".
CHANGELOG_BEGIN
- [Ledger API] The *.proto files containing the gRPC definitions are now
provided by a new Maven Central artifact, with the group "com.daml"
and the artifact name "ledger-api-proto".
CHANGELOG_END
* release: We don't need the "main-jar" option.
* Bazel: Proto JARs will always have a Maven artifact suffix.
* Bazel: Simplify Protobuf source file TAR and JAR targets.
* Bazel: Extract out Protobuf functions.
String validators from com.daml.lf.data.IdString are use extensively.
This PR optimize the implementation of some of those.
CHANGELOG_BEGIN
CHANGELOG_END
* WIP Draft of formal exception semantics
CHANGELOG_BEGIN
CHANGELOG_END
* Make throw take an AnyException
* Don't allow templates as exceptions
* Make throw a builtin
* Pass the textual error message to to_any_exception
* Rename builtin exceptions to errors
* Rename to_any_exception in make_any_exception
* Fix typing rules for make/from_any_exception
* Add availability notes
* Fix typo
* simplify interface to construct speedy continuations
move code from caller to definition
* relocate comment to the relocated code it refers to!
changelog_begin
changelog_end
* rename var: m -> machine
* relocate instrumentation print() from where KFinished is thrown, to where it is handled in run()
* revert KFinished back to an object (instead of a class taking machne); and revert back to use initialKontStack()
Turns out the `package_dir` is not what we're looking for. Omitting it
fixes the path.
_Before:_
```
1766 2010-01-01 00:00 protos-0.0.0/com/digitalasset/daml_lf_1_8/com/digitalasset/daml_lf_1_8/daml_lf.proto
```
_After:_
```
1766 2010-01-01 00:00 protos-0.0.0/com/digitalasset/daml_lf_1_8/daml_lf.proto
```
CHANGELOG_BEGIN
CHANGELOG_END
* kvutils: Use ScalaPB to generate a Scala JAR for daml_kvutils.proto.
* Bazel: Delete the unused `da_java_binary` rule, and inline `_wrap_rule`.
* Bazel: Factor out Java/Scala protobuf class generation into a helper.
CHANGELOG_BEGIN
CHANGELOG_END
* daml-lf/archive: Use `proto_jars`.
* Bazel: Remove the visibility modifier from `proto_jars`.
It's too confusing. Just make everything public.
* daml-lf/archive: Push protobuf source tarballs into `proto_jars`.
* Bazel: Add comments to the various parts of `proto_jars`.
* daml-assistant: Do unpleasant things with `location` in Bazel.
As requested by Martin in #8069, we extract most of the changes from
DecodeV1Spec in a separate PR.
This advances the state of #7155
CHANGELOG_BEGIN
CHANGELOG_END
CHANGELOG_BEGIN
kvutils reports LookupByKey node mismatches during validation as Inconsistent
instead of Disputed if they can be due to contention on the contract key
CHANGELOG_END
* Refactor indexing to minimize transaction traversals
changelog_begin
[Integration Kit] Bugfix: daml.index.db.store_transaction metrics were keeping track of empty insertions, skewing down the numbers
[Integration Kit] Performance: minimizing the number of traversals of a transaction to index it, more efficient indexing
changelog_end
* Add empty stakeholders for non-consuming exercises
* Fix test to check usage of pre-computed blinding info
* Remove unnecessary string interpolators
* Shorten creation of net visibility
* Delete obsolete comment
* Add visibility of divulged contracts
* Address review https://github.com/digital-asset/daml/pull/8019#discussion_r527666572
* Address review https://github.com/digital-asset/daml/pull/8019#pullrequestreview-535399441
* Address review https://github.com/digital-asset/daml/pull/8019#discussion_r527681774
* Fix ordering of batches, use explicitly named types to avoid confusion
* Default to an empty set if a divulged contract is not visible in the current transaction
* Shorten references to store transaction metrics when writing
* Address review https://github.com/digital-asset/daml/pull/8019#discussion_r527745640
* Add divulgences from past transactions
* More fine-grained types and signatures
Add a description of how to enable LaTeX input mode when editing the
DAML-LF spec in VS Code. Also add some additional symbols.
CHANGELOG_BEGIN
CHANGELOG_END
* Adapt to new desugaring for choice observers.
update hash of ghc patch.
changelog_begin
changelog_end
update ghc patch to final version
update stack-snapshot hashes for ghc-lib(-parser)
update stackage_snapshot.json, following `bazel run @stackage-unpinned//:pin`
expose Optional constructors for desugared code to use
adapt LFConversion to expect a 4-tuple for a desugared choice def/sig
update LFConversion for choice-observers
first example using new choice observer syntax.
fix scala type checker to have correct scoping rules for choice-observers
remove comment from example which says it is broken
improve variable names
improve tests for choice-observer clause
only test choice-observers SINCE 1.dev
add jq queries for choice observeres
make positive statement in jq test which checks choice obserers are present
test behaviour of choice observers
squash me
typo
* test more choice-observer divulgence
* Update documention for choice observers.
changelog_begin
Support choice observers in 1.dev
changelog_end
* fix docs build
* fix daml docs choice-observers example
* address comments: rewording text
* annotate choices observers as early-access in documention
* split out documentation code-snippets which require --target=1.dev
* final tweaks to documentation text
* DAML-LF: Add interning for type to DAML-LF 1.dev
We add two new features to DAML-LF 1.dev:
* a per package list (or table) of `Type` messages, and
* a new case in the `Type` message which is an index into this table.
In combination, these two features can be used to allow DAML-LF
encoders to perform hash-consing of `Type` messages. We also change the
Haskell implementation of our DAML-LF encoder to do exactly that when
targetting DAML-LF 1.dev.
Doing this has a few benefits:
1. The DALFs produced by `damlc` get smaller: I've seen a case where
the size dropped from 69MB to 45MB.
2. DAML-LF decoders need to decode less data.
3. Decoded packages use less memory because identical structures are
now shared. This is particularly helpful in situations where we need
to keep the interface (or signature) of a package in memory for a
long time.
This PR mostly takes care of the Haskell implementation. However, we
need to make the Scala implementation of the decoder aware of the new
features as well since we have tests that load DAML-LF 1.dev into the
engine. A decoder and _targeted_ tests on the Scala side will follow
in a separate PR.
CHANGELOG_BEGIN
CHANGELOG_END
* Make jq tests aware of type interning
CHANGELOG_BEGIN
CHANGELOG_END
* Improve jq test
CHANGELOG_BEGIN
CHANGELOG_END
* Apply Remy's suggestions
Co-authored-by: Remy <remy.haemmerle@daml.com>
* Improve the imperative bits
CHANGELOG_BEGIN
CHANGELOG_END
Co-authored-by: Remy <remy.haemmerle@daml.com>
We introduce in #7835 VersionedNode which associate to each node a
version. In this PR, we update Transaction validation to take into
account this version when comparing nodes.
This advances the state of #7788
CHANGELOG_BEGIN
CHANGELOG_END
Following what have been done in #7944, we add a check in the Scala
version of the LF type checker that rejects invalid kinds (i.e. kinds
of the form k -> Nat).
This PR does the "Scala side" of #7917.
CHANGELOG_BEGIN
CHANGELOG_END
* Require pattern match exhaustiveness in spec.
Changes the rules for case expressions to require exhaustiveness.
This involves moving out the "well-formed case alternative" rules
to a separate judgement, and introducing a "pattern match
exhaustiveness" judgement.
The symbol ⊲ used for pattern match exhaustiveness comes from
sheaf theory and formal topology, where "A ⊲ B₁, …, Bₙ" means
"A is covered by { B₁, …, Bₙ }", indicating an exhaustive
coverage of A by possibly overlapping conditions B₁, …, Bₙ.
For example, see [this nlab page](https://ncatlab.org/nlab/show/posite).
It seemed appropriate.
changelog_begin
changelog_end
* rst syntax
* fix ExhaustVariant and some weird other syntax
* review comments
Remove file describing how contract key will be implement. The file
is not usefull as contract key have been fully implemented. Futhermore
the file contains plenty of out of date information.
CHANGELOG_BEGIN
CHANGELOG_END
This PR prepares the change of inference algorithm described #7788
where each node is version independently. This PR associates to each
node of `VersionedTransaction` a version. In the current state, all
nodes are associated to the version of the transaction itself. The
inference algorithm (that will make those versions potentially
distinct) will be implemented in an upcoming PR.
CHANGELOG_BEGIN
CHANGELOG_END
This PR fixes two bugs in the type checker:
- Fetch are now rejected if the type constructor does not match a
template
- to_any, from_any, and type_rep are now rejected if the type
parameter contains synonyms.
Additionally, this PR adds the type of the validation error that each
test case should throw in the test that ill formed expression are
properly rejected. In the way we fix some wrong test cases.
CHANGELOG_BEGIN
CHANGELOG_END
- Exercises' results are checked after the children have been checked.
- output the mismatching nodes in case of comparison failure.
CHANGELOG_BEGIN
CHANGELOG_END
* DALF Reader: Refactor decoder environment
Currently, the module to be decoded is part of the decoder environment.
This turned out to be unpleasant during my attempts to implement
interning for types since decoding the type interning table does not
happen in the context of a module.
This PR moves the module out of the decoder environment and passes it
to the decoder function for modules directly. Unfornatunately, we still
need to keep the module name in the environment since that is used as a
default when decoding location information. We solve this problem by
making the module name in the environment optional and always filling
it in when decoding in actual module.
CHANGELOG_BEGIN
CHANGELOG_END
* Adapt tests
CHANGELOG_BEGIN
CHANGELOG_END
* Follow Remy's suggestion
CHANGELOG_BEGIN
CHANGELOG_END
This PR drops support for Transaction version 1 to 9. This is a
breaking change that may affect only ledger created with a pre SDK
1.0.0. No Sandbox-based ledger is affected by this change.
This advances the state of #7788
This breaking change was approved by the architecture committed.
CHANGELOG_BEGIN
CHANGELOG_END