* Add reference docs for exceptions
Not that these are reference-style docs so they are deliberately brief
and don’t focus on usecases. I’ll add a section to the Daml intro for
that in a separate PR.
changelog_begin
changelog_end
* Apply suggestions from code review
Co-authored-by: Sofia Faro <sofia.faro@digitalasset.com>
* review comments
changelog_begin
changelog_end
Co-authored-by: Sofia Faro <sofia.faro@digitalasset.com>
* Pretty print daml.yaml in Daml ledger export
changelog_begin
changelog_end
* Use dynamic port in example-export generation
* Add daml.yaml to Daml ledger export golden test
* Sort data-dependencies for reproducibility
* Replace hashes in data-dependencies with a placeholder
To avoid test failure when any of these change.
* normalize data-dependencies path in scala client
So that the bazel build action is more reproducible itself.
* Fix Scala 2.12 build
* Factor out deleteRecursively
changelog_begin
changelog_end
* Generate ledger export in temp-dir
Build actions are not sandboxed in Windows. The ledger export will also
created a directory `deps` to store all the DALFs in. On Windows this
directory may persist across Bazel builds and may cause errors due to
attempts to overwrite an existing directory.
To avoid these issues the ledger export is generated into a temporary
directory and only the wanted files are moved to the expected output
locations in the bazel execroot afterwards.
* Close source
* Use replace instead of replaceFirst
The latter matches regex pattern instead of just substring matching
which fails with Windows paths due to `\` being interpreted as an escape
character.
* Normalize Windows \ to Unix /
Co-authored-by: Andreas Herrmann <andreas.herrmann@tweag.io>
* client_server_build - user defined outputs
Let the user define a list of output files on client_server_build.
changelog_begin
changelog_end
* daml-script runner expose main(config)
changelog_begin
changelog_end
* Add an example Daml ledger export to the docs
* Build Daml ledger export
changelog_begin
changelog_end
* sh_inline_test
Support toolchain arguments to sh_inline_test. Usefuly for make variable
expansion, e.g. for the POSIX toolchain.
* Add a golden test for Daml ledger export
* Test args files as well
* Use sed from POSIX toolchain
* Add normalization comment to top-level comment
* Ignore trailing CR on Windows
The JSON formatting of the args file uses Windows line endings on
Windows. Therefore, the args.json output technically differs from the
expected output. We're happy to ignore the difference in CRLF here.
Co-authored-by: Andreas Herrmann <andreas.herrmann@tweag.io>
* Add a ledger model page for exceptions.
This page describes the changes to the ledger model as part of the exceptions feature. The changes should be kept separate for now, but once exceptions are stable and out for a while, they should probably be incorporated into the rest of the daml ledger model.
Part of #8020. **This PR is to be merged only when we start releasing exceptions.**
changelog_begin
- [docs] The Daml ledger model has been updated to describe the changes introduced by the new exceptions feature. See here: https://docs.daml.com/concepts/ledger-model/ledger-exceptions.html
changelog_end
* Apply suggestions from code review
Co-authored-by: Ognjen Maric <ognjen.maric@digitalasset.com>
* Round 2
* Fix and simplify "after" relation!
* Easy fixes
* Diagrams for structure and integrity sections.
* Add missing diagrams :)
* clarify consistency section
* Authorization.
* Editing.
* fix label reference
Co-authored-by: Ognjen Maric <ognjen.maric@digitalasset.com>
* Factor out all encoding components
* Provide TextMap party mapping instead of record
This allows users to customize the mapping from old party names to new
party names.
* Emit bindings for parties at beginning of export
For better readability, to avoid `getParty "Alice" parties` all over the
place.
* getParty --> lookupParty to avoid conflict with Prelude
* Use DA.Traversable.mapA over TextMap
* Update integration test
* Update args.json
* Update the daml export docs
changelog_begin
* [Daml export] Users can now define a mapping from parties in the
original ledger state to parties to be used when recontructing the
ledger state. The ``parties`` component of the argument to the
generated export script now takes a mapping from old party name to new
party name.
changelog_end
* getContract --> lookupContract for consistency with lookupParty
Co-authored-by: Andreas Herrmann <andreas.herrmann@tweag.io>
* Take user defined mappings for unknown contracts
* Remove unused `allocateParties` helper
These are now provided in `args.json`.
* No longer fail on missing contract ids
* Generate a default args.json
* Configure daml start to run the export
Configures init-script and script-options such that `daml start` will
execute the export script with the default `args.json` input.
Configures navigator to display the default parties.
* Update daml export integration test
Input format has changed.
* Update documentation for daml ledger export
changelog_begin
* [Daml export] Daml ledger export now handles references to missing
contracts. The generated export script takes a mapping from unknown
contract ids to replacement contract ids as a parameter. Users can
prepopulate the ledger with replacements of missing contracts and
configure the export script to reference these replacements.
The generated export script no longer exposes ``testExport`` as an
entry point, instead Daml export generates a default input file
``args.json`` that can be used to execute the ``export`` function from
``daml script`` or ``daml start``.
changelog_end
* Reinstante testExport & allocateParties
Convenient for testing in Daml IDE or on ledgers that don't have
automatic party allocation.
* Add docstrings to the generated Daml export script
Co-authored-by: Andreas Herrmann <andreas.herrmann@tweag.io>
The existing public key is set to expire in May, so we've changed it.
Note: this _should_ require no other change as the private key is
unchanged (i.e. the new public key can be used to verify old
signatures), but my understanding of GPG is somewhat limited so 🤷.
CHANGELOG_BEGIN
CHANGELOG_END
* Add setTime flag
changelog_begin
* [Daml export] Enable the ``--set-time`` flag on
``daml ledger export script`` to replicate transaction time stamps.
This only works on ledgers operating in static time mode.
changelog_end
* Dump.scala --> Export.scala
So that the file name and class name match.
This was forgotten in 5e652bb2f8.
* Implement optional setTime actions
* Define Action type encompassing SetTime and Submit
Factor out construction of submit actions interleaved with setTime
actions.
This makes it easier to test the corresponding functionality in
isolation.
* EncodeSetTimeSpec
* ActionsFromTreesSpec
* update docs on daml ledger export
* Enable --set-time in integration test
To ensure that the generated code actually compiles
* Fix date/time encoding
Requires additional imports for DA.Time and DA.Date.
Requires qualified references to DA.Time.time, DA.Date.date, and
DA.Date.MONTH.
* Fix Scala 2.13
* Move setTime parameter to Action.fromTrees
* Move export transaction time docs out of caveats
Co-authored-by: Andreas Herrmann <andreas.herrmann@tweag.io>
* Document daml ledger export script
changelog_begin
* [Daml export] Refer to the "Ledger Export" chapter under the "Early
Access Features" for a description of the new Daml ledger export
command. This is an early access feature.
changelog_end
* Fix reference formatting
* Update docs/source/tools/export.rst
Co-authored-by: Moritz Kiefer <moritz.kiefer@purelyfunctional.org>
* Mark as alpha
* Clarify issue around archived contracts
Co-authored-by: Andreas Herrmann <andreas.herrmann@tweag.io>
Co-authored-by: Moritz Kiefer <moritz.kiefer@purelyfunctional.org>
* daml build: add a --access-token-file for remote dependencies
This adds a `ledger.access-token-file` field in the `daml.yaml` project
file and a `--access-token-file` flag to `daml build` to authorize
querying/fetching of remote dependencies.
CHANGELOG_BEGIN
[daml build] A new flag `--access-token-file` is added for the `daml
build` command. It allows the specify the path to an access token to
authenticate against the ledger API. This is needed if the project
depends on a remote Daml package hosted on such a ledger. Alternatively,
the path to the token can also be specified in the `daml.yaml` project
file under the `ledger.access-token-file` field.
CHANGELOG_END
* Expose rounding modes as constructors.
This PR exposes the rounding modes as constructors for RoundingMode. Pattern matching for RoundingMode is not implemented and not critical (will open a separate issue).
This PR also adds documentation for BigNumeric.
changelog_begin
changelog_end
* Fix rounding mode literals
* Update data-types.rst
* expose constructors
* expose constructors (part 2)
* Update compiler/damlc/daml-prim-src/GHC/Types.daml
Co-authored-by: Moritz Kiefer <moritz.kiefer@purelyfunctional.org>
* Try to improve `Numeric n` description.
* Add message for RoundingMode match and a test.
* Restrict RoundingMode test to 1.dev
* Update version numbers to 1.13
Co-authored-by: Moritz Kiefer <moritz.kiefer@purelyfunctional.org>
* remote pkgs: resolve package names in data dependencies via ledger
This implements part 3) of #8976.
This adds the ability to specify package names/versions in daml.yaml in
the data-dependencies stanza. They are being resolved via the project
ledger and a daml.lock lock file.
CHANGELOG_BEGIN
[remote dependencies] Package names and versions, as well as package
ID's are allowed in the `data-dependencies` list of `daml.yaml`. These
packages are fetched from the project ledger. The auto-generated
`daml.lock` file keeps track of the package name/version to package
ID's resolution and should be checked in to version control of the
project.
CHANGELOG_END
* added docs
* Update compiler/damlc/lib/DA/Cli/Damlc/DependencyDb.hs
Co-authored-by: Moritz Kiefer <moritz.kiefer@purelyfunctional.org>
* Update docs/source/daml/reference/packages.rst
Co-authored-by: Moritz Kiefer <moritz.kiefer@purelyfunctional.org>
* suggestions
Co-authored-by: Moritz Kiefer <moritz.kiefer@purelyfunctional.org>
* Add documentation for the Daml Profiler
changelog_begin
- [Daml Profiler] Daml Connect EE now includes a profiler which can be
used to profile Daml execution time.
changelog_end
* Update docs/source/tools/profiler.rst
Co-authored-by: Bernhard Elsner <40762178+bame-da@users.noreply.github.com>
* Make sphinx happy
changelog_begin
changelog_end
Co-authored-by: Bernhard Elsner <40762178+bame-da@users.noreply.github.com>
* Support fetching SDK EE tarball in the assistant
This PR adds an `artifactory-api-key` field to `daml-config.yaml`. If
this is set, we will download the SDK EE tarball if it exists, falling
back to GH releases on 404s (for old releases).
changelog_begin
- [Daml Assistant] The assistant now supports an `artifactory-api-key`
field in `daml-config.yaml`. If you have a license for Daml Connect
EE you can specify this and the assistant will automatically fetch
the EE edition which provides additional functionality.
changelog_end
* Hardcode first EE snapshot
changelog_begin
changelog_end
* Add pruning stabilization to ledger API changelog
changelog_begin
changelog_end
* also can’t type outside of backport
changelog_begin
changelog_end
* I give up
changelog_begin
changelog_end
We used to do this for some packages but it broke cpp. I don’t
actually know why it doesn’t do that anymore but I’ll gladly accept
that fact and turn it on everywhere.
changelog_begin
changelog_end
* Use DA.Map in triggers if available
Replaces DA.Next.Map by DA.Map in the trigger library if the DAML-LF
version supports it, i.e. above 1.11.
Selects on `DAML_GENMAP` and `DAML_GENERIC_COMPARISON` using `CPP`.
changelog_begin
- [Triggers] The trigger library now uses `DA.Map` instead of the
deprecated `DA.Next.Map` if the targeted Daml-LF version supports it.
This is a breaking change: Code that interfaced with the triggers
library using `DA.Next.Map`, e.g. with
`Daml.Trigger.getCommandsInFlight` or `Daml.Trigger.Assert.testRule`,
will need to be changed to use `DA.Map` instead.
changelog_end
* Deduplicate GMap imports in triggers
* DA.Next.Map --> DA.Map in carbon-upgrade-trigger
Co-authored-by: Andreas Herrmann <andreas.herrmann@tweag.io>
* Add a Ledger API changelog
changelog_begin
changelog_end
* Update docs/source/support/compatibility.rst
Co-authored-by: Bernhard Elsner <40762178+bame-da@users.noreply.github.com>
Co-authored-by: Bernhard Elsner <40762178+bame-da@users.noreply.github.com>
Also adds a comment to make sure we don’t forget it in the
future. Note for reviewers: Our code already only looks at the first
line, so the comment in the second line does not break anything.
changelog_begin
changelog_end
* Use cliopts.Http for OAuth 2.0 middleware
changelog_begin
- [OAuth 2.0 Middleware] You can now configure the address that the
middleware listens to using the ``--address`` flag.
The port that the middleware listens to is now configured using the
``--http-port`` flag, use 0 to dynamically choose a free port.
You can now configure a port file where the chosen port will be
written to using the ``--port-file`` flag.
changelog_end
* Add test-case for OAuth 2.0 middleware port file
* Don't forget to close source
* Fix integration test
* Update triggers/service/auth/src/main/scala/com/daml/auth/middleware/oauth2/Config.scala
Co-authored-by: Moritz Kiefer <moritz.kiefer@purelyfunctional.org>
Co-authored-by: Andreas Herrmann <andreas.herrmann@tweag.io>
Co-authored-by: Moritz Kiefer <moritz.kiefer@purelyfunctional.org>
* add livez endpoint to auth middleware
* Add OAuth 2.0 middleware to Daml SDK
* unhide trigger service auth flags
changelog_begin
- [Triggers] The trigger service now supports authorization through an
auth middleware. The feature is enabled using the `--auth` and
`--auth-callback` command-line flags. Please refer to the
Authorization chapter of the trigger service documentation for further
instructions.
- [OAuth 2.0 middleware] Daml Connect now includes an implementation of
the auth middleware API that supports OAuth 2.0 Authorization Code
Grant. Please refer to the Auth Middleware and OAuth 2.0 Auth
Middleware chapters of the documentation.
changelog_end
* drop early access flag on triggers
Daml triggers, the trigger service, and the auth middleware are no
longer marked as early access features.
changelog_begin
- [Triggers] Daml Triggers and the Trigger Service are no longer in
early access status.
changelog_end
Co-authored-by: Andreas Herrmann <andreas.herrmann@tweag.io>
* Add choice observers in the ledger model.
To keep the distinction between "observer" and "choice observer"
clear I'm trying to always refer to the former as "contract observer".
The section on divulgence should probably be reworked to favor choice
observers at some point, but I'm not sure how to do that.
changelog_begin
changelog_end
* s/observer/contract observer
* Separate out the choice observer case of informees
* apply suggestion from @oggy-
* specifying choice observers in DAML contract model
* Add table correlating Connect and Ledger API version
CHANGELOG_BEGIN
CHANGELOG_END
* Use a legal character for header underlining
* Flip columns
* Remove empty line
* Replace many occurrences of DAML with Daml
* Update docs logo
* A few more CLI occurrences
CHANGELOG_BEGIN
- Change DAML capitalization and docs logo
CHANGELOG_END
* Fix some over-eager replacements
* A few mor occurrences in md files
* Address comments in *.proto files
* Change case in comments and strings in .ts files
* Revert changes to frozen proto files
* Also revert LF 1.11
* Update get-daml.sh
* Update windows installer
* Include .py files
* Include comments in .daml files
* More instances in the assistant CLI
* some more help texts
This commit fixes a few copyright headers that have been missed in the
automatic update on Jan 1, as well as the generation code in the compat
workspace so it generates the right headers.
CHANGELOG_BEGIN
CHANGELOG_END
* Remove Navigator console
This was a labs feature so we can remove it without a deprecation
cycle. It doesn’t have any known users and is almost completely
superseded by DAML REPL.
@bame-da agreed to the removal.
This also has the nice side effect of eliminating 1 of our 2
dependencies that were not Scala 2.13 compatible.
changelog_begin
- [Navigator Console] The labs feature Navigator Console has been
removed. Users are encouraged to use DAML REPL instead.
changelog_end
* Kill Navigator database docs completely
changelog_begin
changelog_end
As we strive for more inclusiveness, we are becoming less comfortable
with historically-charged terms being used in our everyday work.
This is targeted for merge on Dec 26, _after_ the necessary
corresponding changes at both the GitHub and Azure Pipelines levels.
CHANGELOG_BEGIN
- DAML Connect development is now conducted from the `main` branch,
rather than the `master` one. If you had any dependency on the
digital-asset/daml repository, you will need to update this parameter.
CHANGELOG_END
* Support multi-party submissions in DAML Script over JSON API
changelog_begin
- [DAML Script] Multi-party submissions are now also supported over
the JSON API.
changelog_end
* Fix outdated comment
changelog_begin
changelog_end
* Support multi-party submissions in the JSON API
changelog_begin
- [JSON API] Add support for multi-party submissions by allowing for
multiple actAs parties in the token and passing on readAs to the
ledger.
changelog_end
* Update ledger-service/http-json/src/main/scala/com/digitalasset/http/EndpointsCompanion.scala
Co-authored-by: Stephen Compall <stephen.compall@daml.com>
Co-authored-by: Stephen Compall <stephen.compall@daml.com>
* Deprecate Sandbox persistence
changelog_begin
changelog_end
* Update docs/source/tools/sandbox.rst
Co-authored-by: Bernhard Elsner <40762178+bame-da@users.noreply.github.com>
* Include in component statuses
changelog_begin
changelog_end
* Fix daml on sql Name param
changelog_begin
changelog_end
* make it compile
changelog_begin
changelog_end
Co-authored-by: Bernhard Elsner <40762178+bame-da@users.noreply.github.com>
* Document participant pruning for operators
CHANGELOG_BEGIN
CHANGELOG_END
* Add references
* Add references and authorization info
* Address review comments
* Keep paragraphs on the same line
* Fix link to Pruning Service
* Add services section for Pruning Service
* Add Pruning Service to service diagrams
* Fix leftover
* How to determine a suitable pruning offset
* Expand determining a suitable offset
* Expand API impacts
* Expand limitations
* Address review comments
* Address review comments
* Flashier top-level menu
* Flashy buttons
CHANGELOG_BEGIN
CHANGELOG_END
* Increase top-level nav font-size
* Make the entire landing page box clickable
* Fix code block alignment and copy button with line numbers
* Fix code blocks with line numbers on mobile
* Reengineer code blocks properly
* More fixes to code-blocks
* Add a vertical line after line numbers
* fix minor typos
CHANGELOG_BEGIN
CHANGELOG_END
* Remove notes and comments on pragma
* minor fix: remove "again" again
* fix various typos
* remove unexplained "bank" references
* replace LET with LT
* fix typo
* remove "again"
* fix grammar
Co-authored-by: Bernhard Elsner <40762178+bame-da@users.noreply.github.com>
* adjust line numbers to include
Co-authored-by: Bernhard Elsner <40762178+bame-da@users.noreply.github.com>
Noticed this while using it to test Navigator changes. Not sure for
how long this has been outdated but definitely for quite a while.
changelog_begin
changelog_end
* Docs restyle WIP
* Minor color changes
* Adjust fonts and shadows
* Remove redundant local contents
* Further fixes to "In this Section"
* Restyle previous and next buttons
* Make visited link color blue
* Top-level nav
* Change how anchors are underlined
* Fix header spacing
* Improve tables
* Improve search results
* Improve copy button
Match sphinx versions between dev-env and bazel
* Copy button and code block fixes
* Fix copy button z-index
* Making things reactive
* Make the title spacing work on mobile & tablet
* Pixel adjustment for S3 hosting
* Spacing and font-size fixes
* Fix content menu for tablet
* Tidy up menu indentation
* Reorder Mobile Menu
* Move unified nav up
CHANGELOG_BEGIN
[Docs] New styling
CHANGELOG_END
* Remove non-free fonts
* Fix button padding
* Fix spacing above first h2
* Fix pixel adjustment of h1 line
* Fix menu click effects and antialiasing
* Pixel adjust h1 line once more
* Remove the examples page from the docs in favour of one on daml.com
CHANGELOG_BEGIN
CHANGELOG_END
* Fix link from /samples to /examples
* Fix link in daml intro
* Fix link, second try
* 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.
* Add party management service to the services page, targeting #8027.
CHANGELOG_BEGIN
CHANGELOG_END
* rephrase to make it more compact
Co-authored-by: Bernhard Elsner <40762178+bame-da@users.noreply.github.com>
* remove unnecessary note
Co-authored-by: Bernhard Elsner <40762178+bame-da@users.noreply.github.com>
* remove unnecessary note
Co-authored-by: Bernhard Elsner <40762178+bame-da@users.noreply.github.com>
* remove blank line
Co-authored-by: Bernhard Elsner <40762178+bame-da@users.noreply.github.com>
A question on discuss prompted me to read this page, and I spotted a
couple typos.
As a side note, I find references to DAML-LF versions unhelpful. I don't
think it's fair to expect our users to know the mapping between DAML
versions and DAML-LF versions.
CHANGELOG_BEGIN
CHANGELOG_END
* Link concepts "gRPC Ledger API" and "Ledger API" in glossary for #8029.
CHANGELOG_BEGIN
CHANGELOG_END
* remove gRPC Ledger API which was in the wrong place
* rephrase alternative names
Co-authored-by: Bernhard Elsner <40762178+bame-da@users.noreply.github.com>
Co-authored-by: Bernhard Elsner <40762178+bame-da@users.noreply.github.com>
This addresses feedback on the upgrade documentation. We switch the
example from coins to carbon certificates and add a section for the
centralized database case to make the base case clear.
CHANGELOG_BEGIN
CHANGELOG_END
* concretize item on "serving the API"
CHANGELOG_BEGIN
CHANGELOG_END
* Revert "concretize item on "serving the API""
This reverts commit 83e35114c4.
* change authentication to authorization
* remove "etc." to make item clearer