Commit Graph

1573 Commits

Author SHA1 Message Date
Remy
bd7e12809e
[LF] fix versioning of value w.r.t. interface (#15370)
CHANGELOG_BEGIN
CHANGELOG_END
2022-10-28 12:31:58 +02:00
Remy
0bba409d0e
[LF] Make ApiCommand.Exercise work directly with type constructor (#15360)
CHANGELOG_BEGIN
CHANGELOG_END
2022-10-26 18:13:38 +00:00
Carl Pulley
c407c4b635
Versioned triggering and correct parsing of TransactionMsg
CHANGELOG_BEGIN
CHANGELOG_END
2022-10-26 15:08:37 +01:00
dylant-da
da8064de64
Add AnyView with HasFromAnyView instances (#15280)
* Implement AnyView as a stable package / primitive

* Point to updated GHC

* Export AnyView datatype, move typeclasses, fix convertPrim

* Adjust AnyView w/ InterfaceTypeRep, implement {to,from}AnyView

* fix lint, satisfy changelog

CHANGELOG_BEGIN
CHANGELOG_END

* fix daml-desugar

* Has{From,To}AnyView instances in daml-docs

* Add DA.Internal.Interface.AnyView to LibraryModules for stdlib

* Fix hash for DA.Internal.Interface.AnyView

* Prefix AnyView with CurrentSdk, add to golden for daml-script test

* Remove HasToAnyView

* Split AnyView into AnyView and AnyView.Types

* fix hash

* Remove unused StandaloneDeriving

* Add HasField instances (requires relevant workers)

* Accept desugaring test changes for removal of HasToAnyView

* Update daml-doc for removal/modification of HasToAnyView/HasFromAnyView

* Update StablePackage hash for DA.Internal.Interface.AnyView.Types
2022-10-25 11:49:32 +00:00
Remy
4fa22e85c1
[Triggers] Version Trigger Daml code (#15298)
We track in `DA.Trigger.Internal` the version of the API between the Daml code and the scala code of the Triggers.

CHANGELOG_BEGIN
CHANGELOG_END
2022-10-21 11:36:59 +02:00
Remy
4318a2341b
[LF] Cleanup StablePackage object (#15250)
CHANGELOG_BEGIN
CHANGELOG_END
2022-10-19 08:06:49 +00:00
Moisés Ackerman
7e6908612b
Fix instance Show Text to produce escaped Text (#15235)
* Fix `instance Show Text` to produce escaped Text (#15177)

This adapts the code used in GHC's 'instance Show Char where { showList }', representing characters as single-character
'Text's using a type synonym. CPP can be used during development to switch to a newtype-based implementation in order
to check type safety.

changelog_begin
- [Daml Standard Library] ``show @Text`` now escapes special characters, producing syntactically correct expressions (#15177)
changelog_end

* Add daml-test-file testing `show @Text`

* Avoid 'explode' in 'showLitChr'

* Cleanup 'showLitChr'

* Update DarReaderTest.scala

* Clean up import of GHC.Base

* Add Note for __DEBUG__SHOW_TEXT_CHR_NEWTYPE macro

* Extract longStringSize from longStringOf in daml-test-file ShowText.daml

* Document differences with GHC implementation

* Remove redundancy between showLitChr and {ascii=>ctrlChrText}

* Add 'exhaustive' test case in daml-test-file ShowText.daml

* Change 'ctrlChrText' default case to throw error
2022-10-17 18:07:56 +02:00
Claudio Bley
e24497635d
Rework evidence security categories (#15226)
* Rework evidence security categories

using the 7 industry standard security testing areas:

* Authentication
* Authorization
* Confidentiality
* Integrity
* Availability
* Non-Repudiation
* Resilience

CHANGELOG_BEGIN
CHANGELOG_END

* Replace category `Input Validation`

* Replace category `Privacy`

* Replace category `Semantics`

* Replace category `Semantics`

* Replace category `Performance`

* Skip categories `NonRepudiation` and `Resilience` for now

There are currently no tests for these categories.

* Regenerate `security-evidence.md`
2022-10-13 09:55:45 +00:00
nickchapman-da
490056ebf9
fix bug in pretty-print for empty kont-stack (#15179)
changelog_begin
changelog_end
2022-10-10 16:35:10 +02:00
nickchapman-da
4d5157b20e
remove dead code (#15181)
changelog_begin
changelog_end
2022-10-06 15:57:27 +00:00
Carl Pulley
6364deb68e
Disable visibility checks for disclosed contracts and disclosed contract keys
* Fixes #14168

CHANGELOG_BEGIN
CHANGELOG_END
2022-09-30 09:38:08 +01:00
Carl Pulley
233bca9d01
Proper error handling on input validation of disclosed contracts
* Fixes #14200

CHANGELOG_BEGIN
CHANGELOG_END
2022-09-29 17:21:02 +01:00
Simon Maxen
817e6aac01
Exclude infrastructure transactions [DPP-1110] (#15121)
* Exclude infrastructure transactions

changelog_begin
changelog_end
2022-09-29 16:22:52 +01:00
dylant-da
485eb2b8dd
Archive choices for interfaces (#15085)
* Point to latest GHC with archive choices on interfaces

* Update Desugared daml for interfaces Archives

* satisfy changelog check

CHANGELOG_BEGIN
CHANGELOG_END

* Update daml-doc test files

* Add relevant identifiers to SignatureReaderSpec for iface Archive choice

* lint

* Point to GHC with generated HasArchive instance

* Add test for archive on interface

* Test that second archive doesn't work

* Update desugar tests

* Point to GHC merge
2022-09-29 10:57:07 +01:00
nickchapman-da
68b323635d
[engine] prefer lastLocation to stackTrace (#15111)
TLDR: Remove broken code which constructs stackTrace().
Happy never to have to read those NOTE(MH) comments in the pushLocation code again!

(1) This code was fundamentally broken for various reasons:
- It doesn't make sense to track location info on the continuation stack. The continuation stack is a record of the evaluation still to come; not a context for the current evaluation.
- Stack traces can't sensibly be provided in a language such as Daml which promises that tail-recursion is evaluated in constant stack-space.
- Attempting to keep location info on the continuation stack does not play well when exceptions are thrown and the stack is unwound.

(2) The stack-trace management code was also very hacky:
- The pushLocation code contained special cases when the continuation stack was headed by a KArg/SToken continuation. This is an internal implementation detail. The KArg doesn't even exist when we stop using the deprecated SEAppGeneral expression constructor.
- The pushLocation code also contained special support for copying stack-traces into SEVal and SDefinition caches, and then later back on to the continuation stack. Yuck!

(3) The stackTrace() code was barely used:
- Some time ago an alternative/simpler location tracking system (lastLocation) was implemented.
- Only ScenarioRunner makes use of the stackTrace()
- Only a single test changes behaviour when we drop use of stackTrace() in favour of getLastLocation
2022-09-28 13:15:08 +01:00
Carl Pulley
935a49d02d
OnLedger immutability
CHANGELOG_BEGIN
CHANGELOG_END
2022-09-27 11:37:29 +01:00
nickchapman-da
e222ee81d6
prefer @deprecated/@warn for SEAppGeneral and SEAppOnlyFunIsAtomic, to renaming functions with _DEPRECATED suffix (#15091) 2022-09-26 18:14:24 +00:00
Remy
1004355fa4
[LF-SPEC] remove files added by mistake after rebase (#15092)
CHANGELOG_BEGIN
CHANGELOG_END
2022-09-26 16:26:02 +00:00
Stephen Compall
dfab8c8b28
rename daml-lf-interface Maven artifact to ...api-type-signature; remove deprecated symbols (#15087)
* remove 2.4.0-deprecated symbols and functions from api-type-signature library

* rename daml-lf-interface maven artifact to daml-lf-api-type-signature

CHANGELOG_BEGIN
- [Daml-LF] Java/Scala applications that directly depend on the (not officially
  supported) ``daml-lf-interface`` library should upgrade to 2.4.0 first, fix
  all deprecations, then upgrade to 2.5.0+ and change their Maven dependencies
  to point to ``daml-lf-api-type-signature`` instead.
CHANGELOG_END
2022-09-26 16:12:20 +00:00
dylant-da
db652ef270
Improve EExpectedViewType (#15048)
* Add dylant-da as a codeowner on compiler-related directories

CHANGELOG_BEGIN
CHANGELOG_END

* SPlit EExpectedViewType into three variants with non-Text bodies

* Duplicate Haskell viewtype typechecking behaviour onto Scala side

* Split TypingSpec tests for different viewtype failures

* lint & changelog

CHANGELOG_BEGIN
CHANGELOG_END

* Fix lint
2022-09-26 14:38:12 +00:00
nickchapman-da
3180094987
[engine] avoid construction of unrestricted speedy expression applications (#15079)
Avoid construction of unrestricted speedy expression applications.SEApp (alias for SEAppGeneral)

- Replace occurrences of SEApp(General) to use SEAppAtomic, with SELet1 as required
- Add new helper SEApp for many cases where arguments are simple values.
- Rename the most general unrestricted constructor as SEAppGeneral_DEPRECATED. The only remaining use is by fromUpdateSExpr and fromScenarioSExpr, due to our unprincipled approach to stack-trace. See TODO in pushLocation. I hope to fix this in a future PR.
- Rename the slightly less unrestricted constructor as SEAppOnlyFunIsAtomic_DEPRECATED. The only call site being in Anf.scala (for the case when ANF is not performed). Maybe one day we can perform ANF in all cases, and hence remove this one remaining usage.
2022-09-26 14:33:51 +01:00
Carl Pulley
7635fbe83c
Test that disclosed contracts respect template/contract preconditions (i.e. ensure clauses)
* Fixes #14227

CHANGELOG_BEGIN
CHANGELOG_END
2022-09-26 08:37:06 +01:00
Remy
6dd9a45e50
[Engine] small cleaning of LookupError (#15060)
* [Engine] small cleaning of LookupError

CHANGELOG_BEGIN
CHANGELOG_END
2022-09-23 13:46:14 +00:00
Remy
56dfeb1e87
[LF] improve AstRewriter (#15073)
CHANGELOG_BEGIN
CHANGELOG_END
2022-09-23 15:13:19 +02:00
Carl Pulley
49f2f7ef20
Bug fix for Classify class - corrects continuation and expression counts
CHANGELOG_BEGIN
CHANGELOG_END
2022-09-23 13:26:11 +01:00
Remy
a1e92e539f
[LF] fix encoder for ELocation (#15070)
* [LF] fix encoder for ELocation

CHANGELOG_BEGIN
CHANGELOG_END
2022-09-23 10:28:21 +00:00
Carl Pulley
3ace00d787
Refactor to ensure Instrumentation and Classify classes are immutable
* Refactor to ensure Instrumentation and Classify classes are immutable

CHANGELOG_BEGIN
CHANGELOG_END
2022-09-22 17:57:16 +01:00
Carl Pulley
aa062cde42
Final step of explicit disclosure cached contract refactor
* Fixes #13897

CHANGELOG_BEGIN
CHANGELOG_END
2022-09-21 18:12:55 +01:00
Remy
3f163e8e2e
[engine] drop deprecated LenientExercise Command (#15059)
CHANGELOG_BEGIN
CHANGELOG_END
2022-09-21 16:48:05 +00:00
nickchapman-da
0ebe770e59
[engine] stack-safe daml-lf archive decoding (#14964)
Transform our code for the protobuf-decoding phase to be stack-safe, by means of a Work trampoline. The code-style rules are:

runWork is never called in a nested context.
We introduce an explicit Work.Delay to break recursion.
Increase the size of the many-fields test from 120 to 160 fields.

(At 164 fields we run into the protobuf limit)

Part of: #13410
2022-09-20 16:51:50 +01:00
Carl Pulley
e134e04913
Part of explicit disclosure cached contract refactor
* Stubbed out `SBUpdateContractCache` builtin and integrated it into Engine and Compiler workflows

CHANGELOG_BEGIN
CHANGELOG_END
2022-09-20 14:55:52 +01:00
Carl Pulley
f9b166ab35
Restrict degree to which Speedy.Machine exposes its mutable state
* Restrict degree to which Speedy.Machine exposes its mutable state

CHANGELOG_BEGIN
CHANGELOG_END
2022-09-20 09:30:03 +01:00
Nicu Reut
03256ddbf5
[lf kv lib] - Clean up transaction traversal [kvl-1566] (#15032)
* [lf kvlib] - Remove scalaz usages from transaction traversal

* Explicitly handle unsupported node types when traversing with witnesses

changelog_begin
changelog_end
2022-09-16 10:36:19 +02:00
Nicu Reut
3f06e322fd
[lf kvlib] - Handle rollback nodes when traversing transaction [KVL-1566] (#15020) (#15028)
We need to extract all the package party mappings found in a transaction, including the nodes that are under a rollback node
Rollback nodes have no informees of their own but we extract the children as expected

changelog_begin
changelog_end
2022-09-15 08:48:14 +00:00
Nicu Reut
21e8ba089e
[daml-lf kvsupport] - Add transaction traversal for package party mappings [KVL-1566] (#14965)
changelog_begin
changelog_end
2022-09-08 11:31:24 +02:00
Carl Pulley
b361d96768
Changes to ensure CompiledPackages contains contract key template lambda definitions
* Compiler changes:
- add in ContractKeyWithMaintainersDefRef
- ensure compileModule compiles contract key lambdas for templates (and so allow contract keys to be extracted from contract instances)

CHANGELOG_BEGIN
CHANGELOG_END
2022-09-06 13:53:34 +01:00
Moisés Ackerman
db4de4e8c5
Engine: Include interface's packageId in usedPackages (#14887)
* Give type signature for runApi

* Add InterfaceRetro.dar in daml-lf/tests

* Add failing test case

* Include interface packageId in usedPackages

changelog_begin
changelog_end
2022-09-02 16:22:33 +00:00
Stephen Compall
2b6289a259
enable interface view tests in api-type-signature (#14877)
CHANGELOG_BEGIN
CHANGELOG_END
2022-08-31 09:23:14 -04:00
dylant-da
804a0b7b9d
Reenable tests from #14773 #14770 / Add new tests for 1.15 (#14836)
* Squashed commit of the following:

commit fd04d54efffdd182b15ed5350ac190fd7e800f2c
Author: Dylan Thinnes <dylan.thinnes@digitalasset.com>
Date:   Mon Aug 29 14:46:19 2022 +0100

    lint

commit 117a3e1253cbede690127b66ee73a7ad7a75fd51
Author: Dylan Thinnes <dylan.thinnes@digitalasset.com>
Date:   Mon Aug 29 13:16:00 2022 +0100

    Temporarily disable isCompleted assertions - they appear to be too eager

commit a17e30b045affad557c1282b9c56229f64ab0d51
Author: Dylan Thinnes <dylan.thinnes@digitalasset.com>
Date:   Mon Aug 29 12:21:40 2022 +0100

    Remove unnecessary NotExtended tests, fix module names, reenable some

commit 075a62e6f263b86a342e887a0015cf0b812ad4e1
Author: Dylan Thinnes <dylan.thinnes@digitalasset.com>
Date:   Mon Aug 29 10:48:24 2022 +0100

    Remove InterfaceConversions - interface exercises are now Interface-only

commit 4b8a7b4a061ea740e5b72c06b99cf6eaced2315d
Author: Dylan Thinnes <dylan.thinnes@digitalasset.com>
Date:   Mon Aug 29 10:39:03 2022 +0100

    Update carbon test names for 1.dev suite test

commit 04e735223cc2c06fa3dd014538edcc5e4d5dd191
Author: Dylan Thinnes <dylan.thinnes@digitalasset.com>
Date:   Mon Aug 29 10:23:45 2022 +0100

    Point to 1.15 for carbon tests

commit 450e49479fc2daed3bc6a08234a95df8fe80382e
Author: Dylan Thinnes <dylan.thinnes@digitalasset.com>
Date:   Mon Aug 29 10:11:23 2022 +0100

    Move InterfaceSubscriptionsIT test to 1.15 folder

commit b1cd99d8074f789927d2e02b46a085fcd7a88319
Merge: 1dfdc2e7c5 f21b165c78
Author: Dylan Thinnes <dylan.thinnes@digitalasset.com>
Date:   Mon Aug 29 09:47:09 2022 +0100

    Merge remote-tracking branch 'origin/main' into dylan-lf-15-reenable-tests

commit 1dfdc2e7c503e9d798b60bc1279633295e50bb0c
Author: Dylan Thinnes <dylan.thinnes@digitalasset.com>
Date:   Thu Aug 25 16:58:37 2022 +0100

    Add NotExtended versions of all tests which use extended interfaces

commit 6398fa96c5c1d14dda1ff724d3d4b5de6301b97b
Author: Dylan Thinnes <dylan.thinnes@digitalasset.com>
Date:   Thu Aug 25 13:01:30 2022 +0100

    Make versions of tests that are NotExtended

commit c2daf05e134ab3d0d27d83a7ef24e07553b15c3e
Author: Dylan Thinnes <dylan.thinnes@digitalasset.com>
Date:   Thu Aug 25 12:20:03 2022 +0100

    Reenable disabled tests from #14770 / #14773

commit f390d37941
Author: Dylan Thinnes <dylan.thinnes@digitalasset.com>
Date:   Thu Aug 25 11:56:52 2022 +0100

    Remove 1.dev-only references from 1.15 protobuf

commit 87d6b540aa
Author: Dylan Thinnes <dylan.thinnes@digitalasset.com>
Date:   Thu Aug 25 11:36:08 2022 +0100

    Temporarily disable failing damlc tests

commit 05ea7bdb75
Author: Dylan Thinnes <dylan.thinnes@digitalasset.com>
Date:   Thu Aug 25 09:49:08 2022 +0100

    Update desugared daml for UExerciseInterface[Guarded] generation

commit 14fdd5f725
Author: Dylan Thinnes <dylan.thinnes@digitalasset.com>
Date:   Thu Aug 25 09:44:59 2022 +0100

    Run damlc interface tests w/o requires when since DAML_INTERFACE

commit d73c86df3f
Merge: 9a83d0776e 00705af419
Author: Dylan Thinnes <dylan.thinnes@digitalasset.com>
Date:   Wed Aug 24 16:35:31 2022 +0100

    Merge remote-tracking branch 'origin/main' into dylan-lf-15-minimal-distinguish-guards

commit 9a83d0776e
Author: Dylan Thinnes <dylan.thinnes@digitalasset.com>
Date:   Wed Aug 24 15:22:59 2022 +0100

    Exclude via $cexerciseGuarded check - ClassOpId approach did not work

commit b635dcd7cb
Author: Dylan Thinnes <dylan.thinnes@digitalasset.com>
Date:   Wed Aug 24 12:59:57 2022 +0100

    Add check for isId to splitDFunId

commit dcfa1e0ebf
Author: Dylan Thinnes <dylan.thinnes@digitalasset.com>
Date:   Wed Aug 24 11:43:19 2022 +0100

    Remove all instances of guarded exercises in versions <= 1.15

commit b0985ccdbd
Author: Dylan Thinnes <dylan.thinnes@digitalasset.com>
Date:   Tue Aug 23 13:10:15 2022 +0100

    Remove guarded exercise when Extended Interfaces are not enabled

commit 125280ca60
Author: Dylan Thinnes <dylan.thinnes@digitalasset.com>
Date:   Mon Aug 22 15:33:55 2022 +0100

    Clarify purpose of `Maybe Expr` type for exercise guard

    Co-Authored-By: Moisés Ackerman <6054733+akrmn@users.noreply.github.com>

commit 50cff3004b
Author: Dylan Thinnes <dylan.thinnes@digitalasset.com>
Date:   Mon Aug 22 15:32:17 2022 +0100

    Remove unnecessary mention of v1_14 from supportedInputVersions

    Co-Authored-By: Moisés Ackerman <6054733+akrmn@users.noreply.github.com>

commit 89744ef341
Author: Dylan Thinnes <dylan.thinnes@digitalasset.com>
Date:   Mon Aug 22 15:31:04 2022 +0100

    Rename interface features

    Co-Authored-By: Moisés Ackerman <6054733+akrmn@users.noreply.github.com>

commit c173799c47
Author: Dylan Thinnes <dylan.thinnes@digitalasset.com>
Date:   Mon Aug 22 15:23:13 2022 +0100

    Attach correct range to guard support error (if any)

    Co-Authored-By: Moisés Ackerman <6054733+akrmn@users.noreply.github.com>

commit c41f8480ed
Author: Dylan Thinnes <dylan.thinnes@digitalasset.com>
Date:   Thu Aug 18 12:57:28 2022 +0100

    Update to new GHC revision, removes pred argument from `exercise`

commit d9dfe87252
Author: Dylan Thinnes <dylan.thinnes@digitalasset.com>
Date:   Tue Aug 16 12:06:04 2022 +0100

    Desugar UExerciseInterface[Guarded] differently, point to updated GHC

commit dd0ac96dcd
Author: Dylan Thinnes <dylan.thinnes@digitalasset.com>
Date:   Tue Aug 16 12:05:53 2022 +0100

    Make exercise guards nullable, ignore Nothing in decode/encode

commit 53e23fac26
Author: Dylan Thinnes <dylan.thinnes@digitalasset.com>
Date:   Tue Aug 23 13:13:09 2022 +0100

    lint

commit abf5267051
Author: Dylan Thinnes <dylan.thinnes@digitalasset.com>
Date:   Tue Aug 23 12:50:04 2022 +0100

    Move InterfaceSubscriptionsIT test back into 1.dev suite

commit c2d1499747
Author: Dylan Thinnes <dylan.thinnes@digitalasset.com>
Date:   Tue Aug 23 12:00:17 2022 +0100

    Use dictionary comprehension to generate ledger/test-common test_names

commit 0d5f167fc6
Merge: 0242452662 ec4c86ac2d
Author: Dylan Thinnes <dylan.thinnes@digitalasset.com>
Date:   Tue Aug 23 10:27:21 2022 +0100

    Merge remote-tracking branch 'origin/main' into dylan-lf-15-minimal

commit 0242452662
Author: Dylan Thinnes <dylan.thinnes@digitalasset.com>
Date:   Tue Aug 23 10:26:29 2022 +0100

    Temporarily disable decode extended interface primitives test

commit b17ca7f03c
Author: Dylan Thinnes <dylan.thinnes@digitalasset.com>
Date:   Mon Aug 22 16:26:10 2022 +0100

    lint

commit ceaca2b0f6
Merge: c11eb08083 95d00c4e8a
Author: Dylan Thinnes <dylan.thinnes@digitalasset.com>
Date:   Mon Aug 22 16:12:43 2022 +0100

    Merge remote-tracking branch 'origin/main' into dylan-lf-15-minimal

commit c11eb08083
Author: Dylan Thinnes <dylan.thinnes@digitalasset.com>
Date:   Mon Aug 22 15:20:50 2022 +0100

    Disable PureConfigReaderWriter tests that assume early-access == stable

commit 03734d2f23
Author: Dylan Thinnes <dylan.thinnes@digitalasset.com>
Date:   Mon Aug 22 14:02:55 2022 +0100

    Also disable conformance-test-tls1.2-or-newer-1.15

commit e683ea3d7c
Author: Dylan Thinnes <dylan.thinnes@digitalasset.com>
Date:   Mon Aug 22 14:00:45 2022 +0100

    Temporarily disable 1.15 conformance tests - handle in another PR

commit 6fb140b0b6
Author: Dylan Thinnes <dylan.thinnes@digitalasset.com>
Date:   Mon Aug 22 13:59:58 2022 +0100

    lint

commit 65531fe577
Author: Dylan Thinnes <dylan.thinnes@digitalasset.com>
Date:   Mon Aug 22 11:00:41 2022 +0100

    Run retroactive implements tests only in extended interfaces

commit edf20bf4a7
Author: Dylan Thinnes <dylan.thinnes@digitalasset.com>
Date:   Fri Aug 19 17:48:39 2022 +0100

    Fix StableVersions back to 1.14, make EarlyAccessVersions 1.15

commit 12818dc58f
Author: Dylan Thinnes <dylan.thinnes@digitalasset.com>
Date:   Thu Aug 18 18:06:36 2022 +0100

    Allow unsafe_from_interface and interface_template_type_rep in 1.15

commit ff7271de1a
Author: Dylan Thinnes <dylan.thinnes@digitalasset.com>
Date:   Fri Aug 19 10:55:40 2022 +0100

    Update tests with extended interface features to only run on 1.dev

commit 9558feaec8
Author: Dylan Thinnes <dylan.thinnes@digitalasset.com>
Date:   Fri Aug 19 16:47:19 2022 +0100

    satisfy changelog check

    CHANGELOG_BEGIN
    CHANGELOG_END

commit 337cc25b7a
Author: Dylan Thinnes <dylan.thinnes@digitalasset.com>
Date:   Wed Aug 17 16:36:45 2022 +0100

    Fix InterfaceNotSupported message to 1.15 or higher

commit 4282ae396b
Author: Dylan Thinnes <dylan.thinnes@digitalasset.com>
Date:   Tue Aug 16 17:41:15 2022 +0100

    Move v1_15 ledger-api-tests into own suite

commit ac3d0a9f25
Author: Dylan Thinnes <dylan.thinnes@digitalasset.com>
Date:   Fri Aug 19 15:18:41 2022 +0100

    Reinclude 1.15 in COMPILER_LF_VERSIONS to build model-tests-1.15

commit 718879020d
Author: Dylan Thinnes <dylan.thinnes@digitalasset.com>
Date:   Fri Aug 19 14:43:35 2022 +0100

    Add 1.15 test suite to testtool

commit a6fd63d3d9
Author: Dylan Thinnes <dylan.thinnes@digitalasset.com>
Date:   Fri Aug 19 14:43:23 2022 +0100

    Add 1.15 as preview version

commit f5c48ddc99
Author: Dylan Thinnes <dylan.thinnes@digitalasset.com>
Date:   Fri Aug 19 14:43:12 2022 +0100

    Make 1.14 default again

commit b9527c1136
Author: Dylan Thinnes <dylan.thinnes@digitalasset.com>
Date:   Wed Aug 17 14:23:16 2022 +0100

    Update Version 1.15 changelog with Call/implements

commit 9cecad5205
Author: Dylan Thinnes <dylan.thinnes@digitalasset.com>
Date:   Wed Aug 17 11:24:49 2022 +0100

    Add Tests file for 1.15 in ledger API testtool

commit cde583d08d
Author: Dylan Thinnes <dylan.thinnes@digitalasset.com>
Date:   Tue Aug 16 16:41:58 2022 +0100

    Remove references to dev from 1.15 protobufs

commit 904da5679b
Author: Dylan Thinnes <dylan.thinnes@digitalasset.com>
Date:   Tue Aug 16 13:04:19 2022 +0100

    Stage 1.15 protobuf

commit 196fa6a3cf
Author: Dylan Thinnes <dylan.thinnes@digitalasset.com>
Date:   Tue Aug 16 11:54:20 2022 +0100

    Update Ast/Version & docs for 1.15, split interface into simple/extended

commit 1c58421f2d
Author: Dylan Thinnes <dylan.thinnes@digitalasset.com>
Date:   Mon Aug 15 13:05:37 2022 +0100

    Add version 1.15 - move interfaces into them

* API-test-tool: add InterfaceSubscriptionsIT to LF 1.15 tests

CHANGELOG_BEGIN
CHANGELOG_END

* fix bug

* Add version 1.15 - move interfaces into them

* Update Ast/Version & docs for 1.15, split interface into simple/extended

* Make 1.14 default again

* Update tests with extended interface features to only run on 1.dev

* Fix StableVersions back to 1.14, make EarlyAccessVersions 1.15

* Run retroactive implements tests only in extended interfaces

* Disable PureConfigReaderWriter tests that assume early-access == stable

* lint

* Move InterfaceSubscriptionsIT test back into 1.dev suite

* lint

* Remove unnecessary mention of v1_14 from supportedInputVersions

Co-Authored-By: Moisés Ackerman <6054733+akrmn@users.noreply.github.com>

* Run damlc interface tests w/o requires when since DAML_INTERFACE

* Temporarily disable failing damlc tests

* Reenable disabled tests from #14770 / #14773

* Move InterfaceSubscriptionsIT test to 1.15 folder

* Remove InterfaceConversions - interface exercises are now Interface-only

* Re-enable assertEquals

* Modify PureConfigReaderWriterSpec to account for stable != early-access

* Disable conformance tests

* Disable on-canton conformance_test instead

* Remove InterfaceTypeRepCheck - all exercises are on interface now

* Fix UpcastDowncast tests

* Fix DowncastUpcast 1.15 test, convert assets to token in Guarded test

* Move typerep/unsafeFromInterface decode tests to basic interfaces

* Fix desugared daml for damlc test changes

* Reintroduce InterfaceConversions - remove impossible exercise

This reverts commit 075a62e6f263b86a342e887a0015cf0b812ad4e1.

* Reintroduce InterfaceTypeRepCheck - fix test to use T2Choice

This reverts commit d8a0a7f299.

* Run InterfaceTypeRepCheck for LF 1.15

Co-authored-by: Remy Haemmerle <Remy.Haemmerle@daml.com>
Co-authored-by: Moisés Ackerman <6054733+akrmn@users.noreply.github.com>
2022-08-30 13:58:31 +00:00
Remy
4622de48bd
API-test-tool: add InterfaceSubscriptionsIT to LF 1.15 tests (#14800)
CHANGELOG_BEGIN
CHANGELOG_END
2022-08-30 09:20:22 +02:00
Stephen Compall
99a48557d3
deprecate interface library names; use new names downstream (#14856)
* new names in daml-script/runner

* new names in json-api

* new names in Scala bindings/codegen

* new names in Java bindings/codegen

* new names in daml-lf interpreter tests

* more new names in daml-script tests

* new names in navigator backend

* deprecate all iface symbols and old method names

CHANGELOG_BEGIN
- [Scala API] ``com.daml.lf.iface`` has been deprecated, as discussed
  further in
  `issue #14783 <https://github.com/digital-asset/daml/pull/14783>`__.
  Use the deprecation warnings as guidance to the new names.
CHANGELOG_END

* prefix cases in OrderingSpec

- suggested by @remyhaemmerle-da; thanks
2022-08-29 20:43:47 +00:00
Remy
45bfb26ade
LF clean up proto snapshot of LF 1.15 (#14799)
CHANGELOG_BEGIN
CHANGELOG_END
2022-08-29 10:40:19 +00:00
Chun Lok Ling
47216d1f1a
Pass retroImplements from Ast.DefInterface to DefInterface (#14843)
* pass retroImplements from Ast.DefInterface to DefInterface and addted test case

CHANGELOG_BEGIN
CHANGELOG_END

* added todo

CHANGELOG_BEGIN
CHANGELOG_END

* fixed findTemplate , added test cases

CHANGELOG_BEGIN
CHANGELOG_END

* add test data

CHANGELOG_BEGIN
CHANGELOG_END

* add copyright

CHANGELOG_BEGIN
CHANGELOG_END
2022-08-25 23:53:01 +01:00
dylant-da
6ece737e46
Desugar guards compatibly with 1.15/1.dev split (#14773)
* Add version 1.15 - move interfaces into them

* Update Ast/Version & docs for 1.15, split interface into simple/extended

* Stage 1.15 protobuf

* Remove references to dev from 1.15 protobufs

* Add Tests file for 1.15 in ledger API testtool

* Update Version 1.15 changelog with Call/implements

* Make 1.14 default again

* Add 1.15 as preview version

* Add 1.15 test suite to testtool

* Reinclude 1.15 in COMPILER_LF_VERSIONS to build model-tests-1.15

* Move v1_15 ledger-api-tests into own suite

* Fix InterfaceNotSupported message to 1.15 or higher

* satisfy changelog check

CHANGELOG_BEGIN
CHANGELOG_END

* Update tests with extended interface features to only run on 1.dev

* Allow unsafe_from_interface and interface_template_type_rep in 1.15

* Fix StableVersions back to 1.14, make EarlyAccessVersions 1.15

* Run retroactive implements tests only in extended interfaces

* lint

* Temporarily disable 1.15 conformance tests - handle in another PR

* Also disable conformance-test-tls1.2-or-newer-1.15

* Disable PureConfigReaderWriter tests that assume early-access == stable

* lint

* Temporarily disable decode extended interface primitives test

* Use dictionary comprehension to generate ledger/test-common test_names

* Move InterfaceSubscriptionsIT test back into 1.dev suite

* lint

* Make exercise guards nullable, ignore Nothing in decode/encode

* Desugar UExerciseInterface[Guarded] differently, point to updated GHC

* Update to new GHC revision, removes pred argument from `exercise`

* Attach correct range to guard support error (if any)

Co-Authored-By: Moisés Ackerman <6054733+akrmn@users.noreply.github.com>

* Rename interface features

Co-Authored-By: Moisés Ackerman <6054733+akrmn@users.noreply.github.com>

* Remove unnecessary mention of v1_14 from supportedInputVersions

Co-Authored-By: Moisés Ackerman <6054733+akrmn@users.noreply.github.com>

* Clarify purpose of `Maybe Expr` type for exercise guard

Co-Authored-By: Moisés Ackerman <6054733+akrmn@users.noreply.github.com>

* Remove guarded exercise when Extended Interfaces are not enabled

* Remove all instances of guarded exercises in versions <= 1.15

* Add check for isId to splitDFunId

* Exclude via $cexerciseGuarded check - ClassOpId approach did not work

* Run damlc interface tests w/o requires when since DAML_INTERFACE

* Update desugared daml for UExerciseInterface[Guarded] generation

* Temporarily disable failing damlc tests

* Remove 1.dev-only references from 1.15 protobuf

Co-authored-by: Moisés Ackerman <6054733+akrmn@users.noreply.github.com>
2022-08-25 14:20:03 +01:00
Remy
0f662a66a9
LF: simplify error about unserializability of view (#14803)
CHANGELOG_BEGIN
CHANGELOG_END
2022-08-25 09:53:03 +00:00
mziolekda
31cc435331
small corrections in the specification of the lf transaction (#14827)
CHANGELOG_BEGIN
CHANGELOG_END
2022-08-25 10:16:41 +02:00
Remy
5a07b6596f
LF: check viewtype is a monomorphic record (#14802)
CHANGELOG_BEGIN
CHANGELOG_END
2022-08-25 10:02:13 +02:00
Stephen Compall
f43bc5c8d1
use new api-type-signature names in some dependents (#14785)
* use new names in json-api

* use new names in java codegen

* use new names in Scala codegen

* use new names in TypedValueGenerators

CHANGELOG_BEGIN
CHANGELOG_END
2022-08-23 17:52:10 +00:00
Stephen Compall
f85f7816c7
rename interface library to api-type-signature; alias symbols (#14783)
* move interface directory to api-type-signature; change bazel target; move scala files

* rename iface package to typesig; rename EnvironmentInterface to EnvironmentSignature

* rename Interface to PackageSignature

* rename fromReaderInterfaces to fromPackageSignatures

* rename InterfaceReader to SignatureReader

* rename InterfaceReader to SignatureReader in deprecation note

* rename readInterface to readPackageSignature

* rename InterfaceReaderError to Error

* rename InterfaceReaderMain to SignatureReaderMain

* rename InterfaceType to PackageSignature.TypeDecl

* rename astInterfaces to interfaces

* rename astInterfaces to interfaces in PackageSignature

* rename findAstInterface to findInterface

* rename a couple arguments

CHANGELOG_BEGIN
- [Scala API] The "quasi-public" API in ``com.daml.lf.iface`` has moved
  to the new ``com.daml.lf.typesig`` package, with many accompanying
  name changes as documented in `issue #13669
  <https://github.com/digital-asset/daml/issues/13669>`__.

  Daml 2.5.0 or later will remove the old names, and also rename the
  Maven artifact from ``daml-lf-interface`` to
  ``daml-lf-api-type-signature``.  We recommend that users of this API
  use the deprecation guidance in 2.4.0 to port their applications
  before this happens.
CHANGELOG_END
2022-08-23 15:21:45 +00:00
dylant-da
a74c020ddd
Add version 1.15 - move interfaces into them (#14770)
* Add version 1.15 - move interfaces into them

* Update Ast/Version & docs for 1.15, split interface into simple/extended

* Stage 1.15 protobuf

* Remove references to dev from 1.15 protobufs

* Add Tests file for 1.15 in ledger API testtool

* Update Version 1.15 changelog with Call/implements

* Make 1.14 default again

* Add 1.15 as preview version

* Add 1.15 test suite to testtool

* Reinclude 1.15 in COMPILER_LF_VERSIONS to build model-tests-1.15

* Move v1_15 ledger-api-tests into own suite

* Fix InterfaceNotSupported message to 1.15 or higher

* satisfy changelog check

CHANGELOG_BEGIN
CHANGELOG_END

* Update tests with extended interface features to only run on 1.dev

* Allow unsafe_from_interface and interface_template_type_rep in 1.15

* Fix StableVersions back to 1.14, make EarlyAccessVersions 1.15

* Run retroactive implements tests only in extended interfaces

* lint

* Temporarily disable 1.15 conformance tests - handle in another PR

* Also disable conformance-test-tls1.2-or-newer-1.15

* Disable PureConfigReaderWriter tests that assume early-access == stable

* lint
2022-08-23 13:39:16 +00:00