* TransactionNodesStatistics.stats now returns case class of same name
changelog_begin
changelog_end
* Rename TransactionNodesStats to Detail and make inner class
* Rename TransactionNodesStatistics.stats to apply
* Rename TransactionNodesStatistics to TransactionNodeStatistics
* Reformat
* Remove rollback from statistic action count
* Update with review comments
* Update with review comments
* Remove Extractor
Extractor is being removed after a long time being in Labs status.
This should improve the flakiness on CI.
🔥
changelog_begin
Extractor has been removed from the SDK
changelog_end
* Remove Extractor documentation
* Remove Extractor from CODEOWNERS
* Remove Extractor references in Daml-LF build files
* Remove Extractor references in the Daml SDK assistant
* Remove Extractor from the SDK
* Remove Extractor reference from CONTRIBUTING.md
The method is not correctly implement, as it should slice the
underlying array before returning it. Since it is not possible to
implement it in constant time, we simply drop it, in favor in other
conversion.
CHANGELOG_BEGIN
CHANGELOG_END
* Escape daml-lf tracelog messages
Currently veracode complains because this allows for clrf
injection (injecting newlines to make user input look like separate
log statements).
With this change
```
debug "abc"
debug "eaiu\neaiu"
debug "def"
debugRaw "abc
```
is logged as
```
[DA.Internal.Prelude:555]: \"abc\"
[DA.Internal.Prelude:555]: \"eaiu\neaiu\"
[DA.Internal.Prelude:555]: \"def\"
[DA.Internal.Prelude:555]: abc
```
You can debate whether we should escape the quotes are necessary but
90% of the reason why people add them is because they call `debug` on
strings when they should be using `debugRaw` so this seems fine to me.
changelog_begin
changelog_end
* fix tests
changelog_begin
changelog_end
as it is normally caught in the interpreter loop. In particular the
caller of the engine should not have to catch such an error.
CHANGELOG_BEGIN
CHANGELOG_END
* Update TODOs to outdated issues.
In particular update a lot of defunct interface TODOs to the LF 1.15
issue (or add the LF 1.15 issue if it's also relevant).
changelog_begin
changelog_end
* typo
* remove numeric/bignumeric todo
* scalafmt!!
* drop choice observer TODO
changelog_begin
changelog_end
add runtime check in freeVars: determination that a variable is-free using levels instead of indexes
remove DB-indexes and runtime check; simplify freeVars computation in closure-conversion
Part of #11978. Adds typechecking for this field on the interface side,
and enforces that any template that implements A must implement B if A requires B.
CHANGELOG_BEGIN
CHANGELOG_END
As mentioned in the comment, I view these tests as a way to guard us
against bricking ledgers on upgrades so they somewhat deliberately
ignore ordering of non-cachable errors relative to each other since
those only change error messages.
changelog_begin
changelog_end
* Remove the use of nesting with `size` and `resize` approach as suggested by scalacheck.
CHANGELOG_BEGIN
CHANGELOG_END
* Biased to shorter names generator for Name
After staring at a type mismatch between `Nested` and `Nested` this
seemed like a sensible change. We could also include the package
ids. I don’t have strong feelings about this but this seems like a
clear uncontroversial improvement.
changelog_begin
changelog_end
This is part of #11691
This PR allows to limits:
- the number of signatories,
- the number of observers,
- the number of controllers,
- the number of inputContracts,
CHANGELOG_BEGIN
CHANGELOG_END
* Add skeleton for trace-based LF evaluation tests
The recent issues around wrong ordering of contract id typechecks got
me thinking about this again so I wanted to hack up a PR of how we can
test evaluation order sensibly directly at the LF level.
This is only testing a single create but I first wanted to see if we
agree that this is a sensible approach using a simple example.
If we agree that this is a sensible approach, I’d suggest to extend
those tests later in separate PRs to make them exhaustive.
changelog_begin
changelog_end
* cleanup
changelog_begin
changelog_end
* Adding missing stack-safety testcase for SEScopeExcerise.
changelog_begin
changelog_end
* run all testcases at depth of 10,000. This is plenty deep enough to ensure stack-safety
* recode free-vars computation to be stack-safe. and test
* Drop support for Daml-LF party literals from the Scala side
This PR enforces that forbidPartyLiterals is always `true` and drops
the corresponding literals from the AST. Haskell side is in #11930fixes#11581
changelog_begin
changelog_end
* Update daml-lf/interpreter/src/test/scala/com/digitalasset/daml/lf/speedy/ComparisonSBuiltinTest.scala
Co-authored-by: Remy <remy.haemmerle@daml.com>
* Revert "Update daml-lf/interpreter/src/test/scala/com/digitalasset/daml/lf/speedy/ComparisonSBuiltinTest.scala"
This reverts commit 55e542ce4e3a7fd15544ee703de3277ffc309b17.
Co-authored-by: Remy <remy.haemmerle@daml.com>
* Use Absolute-indexes as keys for the Env-mapping during closure-conversion.
Do runtime check to confirm behaviour matches the existing Relative-indexes.
changelog_begin
changelog_end
* remove quadratic shift!
remove (dev)pretty-print code
remove relative-index keys from Env-mapping
remove runtime *diff* check
increase depth for stack-safety tests
* improve/simplify indexing calculation for Env-keys
* Add type rep argument for interface exercises.
(Still WIP.)
Part of #11703. Fixes the order in which errors are raised ("wrong type"
takes priority over "does not implement interface"). This PR also simplifies
ExerciseInterface by making the guard mandatory, otherwise there's too
many variations. We can revisit that later if we want.
changelog_begin
changelog_end
* haskell side
* dont throw exception in checkTemplateId
* scalafmt
* evidence security
* fix TypingSpec test
* SExpr1.SELocS - carry relBad/absGood - abs unused so far
* compute/pass SELocS.abs in ClosureConversion, and check in Anf that it matches the reconstructed value
CHANGELOG_BEGIN
CHANGELOG_END
* Remove relative stack locations. Rename as SELocAbsoluteS. Simplify Anf. Remove shiftLoc in ClosureConversion.
* Prevent wrongly typed fetch by interface.
When doing a "fetch by interface" command with a known template id,
error out with a WronglyTypedContract if the fetched contract has
a different template id. This doesn't affect daml, only affects
replays, so it's rather minor. I also enabled the engine test that
caught this.
Part of #11703, follow up to #11836.
changelog_begin
changelog_end
* strengthen test output checks
* Drop DA.Next.Set and DA.Next.Map
Fixes#11527. Also removed a bunch of unnecessary CPP, though there's
still a lot more CPP to remove.
changelog_begin
- [Daml Standard Library] DA.Next.Map and DA.Next.Set have been removed
after being deprecated since Daml-LF 1.11
changelog_end
* Drop a deriving MapKey
* update unstable-types test
* Add a guard when exercising by interface.
This fixes part of #11703, when exercising an inherited choice by
interface and you know the template id, via the command preprocessor.
It does this by inserting a "guard" in between the interface fetch and
the exercise body. The guard is a function Interface -> Bool, which
is general enough to check the template id, without complicating too
much in speedy. And can be generalized in the future to check more,
like signatories, etc.
I added the guard as an optional argument to UExerciseByInterface.
This isn't hooked up to the protobuf AST yet (or Haskell side for
that matter) -- but I'll do it in the next PR! For now you can invoke
the guarded exercise via the command preprocessor, so I can enable the
approprate engine tests. (There's still some failing fetch tests left,
but I decided to leave this for later. Fetch can be a lot simpler than
guarded choices, since you always add a fetch node. No need for fancy
continuations.)
changelog_begin
changelog_end
* scalafmt
* Feedback and fix matches
* Update comments, we are always going to abort the transaction
* Raise WronglyTypedContract in SBGuardTemplateId.
* rebase and fix parser
* restore ANF
* scalafmt
ClosureConversion -> Suffix with "Old"
CHANGELOG_BEGIN
CHANGELOG_END
ClosureConversion old-vs-new diff check
ClosureConversionNew, first cut. All tests in SBuiltinTest work.
In addition we change some Array --> List in SExpr1 (for human pp).
And we throw away ClosureConversionDup.
adapt AnfTest from Array to List change for SExpr1
all tests pass in daml-lf/interpreter
remove SExpr0.SELet1General
reorder things
testing for stack-safety of closure conversion
file/class renames
improve naming
pass cont as sep arg to commit (move out of Up/Down)
comment stack-safe closure conversion
fix bug: failed to use env1
fix 2x unmoored doc comment
comment stack safety testing
Remove old closure-conversion code & diff-check between old/new.
loose StackSafe suffix on ClosureConversion class/file
rename StackSafetyTest.scala to ClosureConversionTest.scala
prefer "sealed abstract class" to "sealed trait"
fvs.zipWithIndex --> fvs.view.zipWithIndex
(SExpr1) SEAppGeneral -> SEApp; prefer List to Array in SEApp/SECase
prefer xs.toArray to Array(xs: _*)
access SExpr0 via "source."
two more .view
improve comment and fix typo
link to Issue
switch to a continuation stack; avoids nesting in the Cont type
* Drop LF < 1.14 from supported damlc output versions
fixes#11319
We keep test coverage by depending on the most recent snapshot which
still has 1.14 support.
changelog_begin
- [Daml Compiler] Damlc can only produce Daml-LF 1.14 or
newer. Passing aynthing older to `--target` is an error. If you
need to produce older versions, use an older SDK.
changelog_end
* Switch around legacy_compiler_lf_versions
changelog_begin
changelog_end
* drop since-lf
changelog_begin
changelog_end