* 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
* added graphql resolve field
CHANGELOG_BEGIN
CHANGELOG_END
* render interface prefix; add interface in the route path; added graphql resolve field
* pass in interface id if the choice exercised via interface
* render interface choice in popup when click wrench icon
* Added internal interface case class
CHANGELOG_BEGIN
CHANGELOG_END
* resolveRetroImplements WIP
* remove not used def
* added astInterfaces in PackageRegistry
* provide implementedInterfaces set
* Use def from interface library to resolve choice interface and retroactive implements
* use resolvedChoices instead of directChoices to get resolved choices from template.
* renming AstInterface -> Interface
* Address Stephen's comment
* format
* 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
* introduce TemplateChoices to mediate template choice resolution
* if any resolutions fail in EnvironmentInterface, discard the template's resolution
* if any resolutions fail in Interface, discard the remaining unresolved
CHANGELOG_BEGIN
CHANGELOG_END
* WIP
* First working version of java codegen daml interface support
* Update language-support/java/codegen/BUILD.bazel
Co-authored-by: Remy <remy.haemmerle@daml.com>
* Fix compile errors
* Simplify code massivly, enjoy less duplication
changelog_begin
- The Java codegen now has basic support for daml interface definitions. Converting a contract id of a template implementing an interface to a contract id of the interface is possible and both executing interface choices is possible on the contract id of the interface and implementing template.
changelog_end
* Rename the test file to reflect it is a test file & enhance the inner test name & extend it further
* Fix test
* Refactor parts of TemplateClass.scala into multiple files
* Format that files!
* Minimize duplication further
* Remove unused comment
* Simplify code
Co-authored-by: Stephen Compall <stephen.compall@daml.com>
* Update language-support/java/codegen/src/main/scala/com/digitalasset/daml/lf/codegen/CodeGenRunner.scala
Co-authored-by: Stephen Compall <stephen.compall@daml.com>
* Further refactoring and renaming of the TemplateClassSpec to ContractIdClassBuilderSpec
* Fix formatting
* Add interface docs
* Remove unnecessary code generation of the Contract class for interface types
* Use less bool flags and more good function names :)
* Fix build
Co-authored-by: Remy <remy.haemmerle@daml.com>
Co-authored-by: Stephen Compall <stephen.compall@daml.com>
This adds the presence of interface names, as well as lists of choices
and their argument/return types for each interface.
It also changes the semantics of DefTemplate and EnvironmentInterface:
each may contain "unresolved choices", which are the choices inherited
from interfaces for each implementing template;
EnvironmentInterface#resolveChoices will copy the full type information
as a concrete choice for each implementing template, which should be
much simpler for codegen and json-api.
A type generator should take account of the astInterfaces as well as
typeDecls in EnvironmentInterface; interfaces aren't included in
typeDecls because where I is an interface only ContractId I is
serializable.
* Ast.DataInterface is empty, just use the interfaces map directly
* port json-api for interface API changes; does not solve #12689
* port Scala codegen for interface API changes; does not add support
* port Java codegen for interface API changes; does not solve #11350
CHANGELOG_BEGIN
CHANGELOG_END
Process:
- `git ls-files -z | xargs -0 -n 100 sed -i --follow-symlinks 's/DAML/Daml/g'`
- `git add -p`
- `git restore -p`
- Check there is no unstaged change left.
To review:
- Check for false positives by carefully reviewing the diff in this PR.
- Check for false negatives with `git grep DAML`.
- Quicker check for fals positives:
```
git grep DAML | grep -v migration | grep -v DAML_
```
Fixes#13190
Note: This is the "second half" of #13191, which failed to cover all the
remaining DAMLs because of:
```
$ git ls-files | grep "'"
compiler/damlc/tests/daml-test-files/MangledScenario'.daml
```
CHANGELOG_BEGIN
CHANGELOG_END
Fixes#12789
Adds a new query endpoint to Navigator's GraphQL backend that
lists all the parties registered by Navigator. The parties are
filtered on the server based on a query from the frontend and
served back. The frontend uses this to provide suggestion and
autocompletion features whenever a party identifier input is
required.
changelog_begin
[Navigator] Whenever you have to input a party identifier you
are now offered suggestions and the possibility to
autocomplete. See #12789.
changelog_end
Navigator already had the possibility of autocompleting contract
identifiers, the only thing missing was to wire it in in full. This is
done mostly to inform how to address the more involved #12789.
changelog_begin
[Navigator] All input fields where a contract identifier can be passed
now provide the possibility of auto-completing based on the contracts
existing on the ledger.
changelog_end
As we transition to Canton, we use a new format of contract and party
identifiers that can break the UI of Navigator here and there. In
order to prevent this, we use the same rules as Canton does to shorten
identifiers (basically, elide any hash longer than 12 characters).
Full identifiers are still shown as part of the tooltip.
Furthermore, a tooltip suggests that clicking on the shortened
identifier copies it in full length on the clipboard (which is indeed
what happens). There are a couple of possible improvements to this
interaction, which cannot be handled as part of this PR due to time
constraint:
- the visual cue suggesting that the identifier can be copied can be
improved by adding a clipboard icon besides the label
- there is no visual feedback from copying the identifier, ideally the
user should somehow see that the copying took place (e.g. by turning the
clipboard icon suggested in the point above into a checkmark for a
couple of seconds)
changelog_begin
[Navigator] Contract and party identifiers are shortened on the UI
but can be copied in full by clicking on their label.
changelog_end
Undoing an unnecessary refactoring from #12187
stefanobaghino-da confirmed this fixes the memory leak he observed
in "long" running navigator sessions.
CHANGELOG_BEGIN
CHANGELOG_END
Add basic support for user management to navigator:
log in as a user, act/read as its primary party.
When user management is supported & enabled, you can
only log in as a user (and that user must have a
primary party, which is what you'll actually be
acting/reading as).
The above is the default behavior. It can be disabled
using a feature flag (`--feature-user-management`),
and you can also still specify parties explicitly
in the config file.
CHANGELOG_BEGIN
Navigator supports user management by default. To disable,
use `--feature-user-management false` or specify parties
explicitly in `daml.yaml`.
CHANGELOG_END
Co-authored-by: Robert Autenrieth <31539813+rautenrieth-da@users.noreply.github.com>
Co-authored-by: Stefano Baghino <43749967+stefanobaghino-da@users.noreply.github.com>
Co-authored-by: Victor Peter Rouven Müller <mueller.vpr@gmail.com>
* Upgrade to Scala 2.13.8
changelog_begin
changelog_end
* Update hash for scala in nixpkgs
* update more hashes for scala upgrade
* Fix most warnings etc.
* Fix remaining errors etc.
* Fix formatting
* Resolve last errors hopefully
* Fix ledger api common build file
* Combine imports & revert accidental change that broke the CI run
* Rename exporting vals to scriptExport & minimize diff
* Remove more wrong changes
* moved warning around
Continues the work started in https://github.com/digital-asset/daml/pull/12543
These libraries were only needed to transition from Scala 2.12 to 2.13
and are no longer useful as all the necessary items are now available
in Scala 2.13.
changelog_begin
changelog_end
changelog_begin
changelog_end
Fixes the transitive vulnerable dependency on `nanoid`.
Verified via `yarn audit`. Ran a quick manual test to check that
this did not break `navigator`.
* Split channel configuration from LedgerClientConfiguration
Fixes#12391
The channel configuration now has to be provided separately from the
configuration specific to the ledger client. In this way we avoid
situations where the builder is provided with some configuration
that gets overridden.
changelog_begin
[Scala bindings] The channel configuration has been split from the
LedgerClientConfiguration class. Provide the gRPC channel specific
configuration separately or use a builder. The channel configuration
no longer overrides the builder.
changelog_end
* Fix compilation issues in //ledger-service/...
changelog_begin
changelog_end
Bump resolved markdown-it version to 12.3.2 for modernizr
Bump webpack-dev-server to 4.3.7 to fix transitive issue reported on selfsigned 1.x
Bump marked to 4.0.10 to address reported vulnerability
Somewhat error-prone, so please review carefully.
Reasons we need this:
- Some file types are not properly handled by the script.
- The only exclusion mechanism we currently have (`NO_AUTO_COPYRIGHT`)
is overly coarse.
CHANGELOG_BEGIN
CHANGELOG_END
New year, new copyright, new expected unknown issues with various files
that won't be covered by the script and/or will be but shouldn't change.
I'll do the details on Jan 1, but would appreciate this being
preapproved so I can actually get it merged by then.
CHANGELOG_BEGIN
CHANGELOG_END
Closes#11317
* Add warning for uses of 'controller ... can' syntax
* Remove uses of 'controller ... can' syntax
* Add test cases for -W{,no-}controller-can
* Update docs to reflect 'controller ... can' syntax deprecation
changelog_begin
* Deprecate 'controller ... can' syntax.
* It will be removed in a future version of Daml.
* Instead, use 'choice ... with ... controller' syntax. Note that this does not implictly add the controller as an observer, so it must be added explictly as one (or as a signatory).
changelog_end
I’ve kept the infrastructure for versioned_scala_deps around because
I’m optimistic and hope that eventually we’ll do another Scala upgrade.
changelog_begin
changelog_end
* Moved ErrorCodesVersionSwitcher to //ledger/error
CHANGELOG_BEGIN
CHANGELOG_END
* Rename ErrorCodeLoggingContext to ContextualizedErrorLogger
* Refactored ErrorFactories
* All error factories use ContextualizedErrorLogger for being able to dispatch self-service error codes.
* The ContextualizedErrorLogger is passed down from the dispatching Ledger API services.
* ErrorFactoriesSpec asserts both legacy (V1) and self-service error codes (V2).
* Adapted ApiSubmissionService
* Addressed Marcin's review comments
I used a selective override for strip-ansi because html-webpack-plugin
cannot handle 7.0.0 and I don’t want to downgrade it in other places
where we are already using 7.0.0.
changelog_begin
changelog_end