Releases: dfinity/sdk
SDK 0.7.0
DFX
feat: add output type to request-status
This change allows you to specify the format the return result for dfx canister request-status
.
fix: deleting a canister on a network removes entries for other networks
This change fixes a bug where deleting a canister on a network removed all other entries for
the canister in the canister_ids.json file.
feat: point built-in ic
network provider at mainnet
--network ic
now points to the mainnet IC (as Sodium has been deprecated.)
feat: add candid UI canister
The dedicated candid UI canister is installed on a local network when doing a dfx canister install
or dfx deploy
.
fix: Address already in use (os error 48) when issuing dfx start
This fixes an error which occurred when starting a replica right after stopping it.
feat: ledger subcommands
dfx now supports a dedicated dfx ledger
subcommand. This allows you to interact with the ledger
canister installed on the Internet Computer. Example commands include dfx ledger account-id
which
prints the Account Identifier associated with your selected identity, dfx ledger transfer
which
allows you to transfer ICP from your ledger account to another, and dfx ledger create-canister
which
allows you to create a canister from ICP.
feat: update to 0.17.0 of the Interface Spec
This is a breaking change to support 0.17.0 of the Interface Spec. Compute & memory allocation values
are set when creating a canister. An optional controller can also be specified when creating a canister.
Furthermore, dfx canister set-controller
is removed, in favor of dfx canister update-settings
which
allows the controller to update the controller, the compute allocation, and the memory allocation of the
canister. The freezing threshold value isn't exposed via dfx cli yet, but it may still be modified by
calling the management canister via dfx canister call aaaaa-aa update-settings
feat: add wallet subcommands
dfx now supports a dedicated dfx wallet
subcommand. This allows you to interact with the cycles wallet
associated with your selected identity. For example, dfx wallet balance
to get the cycle balance,
dfx wallet list-addresses
to display the associated controllers & custodians, and dfx wallet send <destination> <amount>
to send cycles to another wallet.
Cycles Wallet
- Module Hash: a609400f2576d1d6df72ce868b359fd08e1d68e58454ef17db2361d2f1c242a1
- dfinity/cycles-wallet@06bb256
feat: Use Internet Identity Service.
SDK 0.6.26
DFX
feat: add --no-wallet flag and --wallet option to allow Users to bypass Wallet or specify a Wallet to use for calls (#1476)
Added --no-wallet
flag to dfx canister
and dfx deploy
. This allows users to call canister management functionality with their Identity as the Sender (bypassing their Wallet canister.)
Added --wallet
option to dfx canister
and dfx deploy
. This allows users to specify a wallet canister id to use as the Sender for calls.
--wallet
and --no-wallet
conflict with each other. Omitting both will invoke the selected Identity's wallet canister to perform calls.
feat: add canister subcommands sign
and send
Users can use dfx canister sign ...
to generated a signed canister call in a json file. Then dfx canister send [message.json]
to the network.
Users can sign the message on an air-gapped computer which is secure to host private keys.
Note
-
sign
andsend
currently don't proxy through wallet canister. Users should use the subcommands withdfx canister --no-wallet sign ...
. -
The
sign
option--expire-after
will set theingress_expiry
to a future timestamp which is current plus the duration.
Then users can send the message during a 5 minutes time window ending in thatingress_expiry
timestamp. Sending the message earlier or later than the time window will both result in a replica error.
feat: implement the HTTP Request proposal in dfx' bootstrap webserver. +
And add support for http requests in the base storage canister (with a default to /index.html
).
This does not support other encodings than identity
for now (and doesn't even return any headers). This support will be added to the upgraded asset storage canister built in #1482.
Added a test that uses curl localhost
to test that the asset storage AND the webserver properly support the http requests.
This commit also upgrades tokio and reqwest in order to work correctly. There are also some performance issues noted (this is slower than the icx-http-server
for some reason), but those are not considered criticals and could be improved later on.
Renamed the project_name
in our own generated assets to canister_name
, for things that are generated during canister build (and not project generation).
feat: add support for ECDSA on secp256k1
You can now a generate private key via OpenSSL or a simlar tool, import it into dfx, and use it to sign an ingress message.
openssl ecparam -name secp256k1 -genkey -out identity.pem
dfx identity import <name> identity.pem
dfx identity use <name>
dfx canister call ...
Asset Canister
feat: The asset canister can now store assets that exceed the message ingress limit (2 MB)
- Please note that neither the JS agent nor the HTTP server have been updated yet to server such large assets.
- The existing interface is left in place for backwards-compatibility, but deprecated:
** retrieve(): use get() and get_chunk() instead
** store(): use create_batch(), create_chunk(), and commit_batch() instead
** list(): use keys() instead
0.6.25
DFX
- feat: dfx now provides CANISTER_ID_<canister_name> environment variables for all canisters to "npm build" when building the frontend.
Agents
Rust Agent
- feat: AgentError due to request::Error will now include the reqwest error message
in addition to "Could not reach the server" - feat: Add secp256k1 support (dfx support to follow)
0.6.24
DFX
- feat: add option to specify initial cycles for newly created canisters (#1433)
Added option to dfx canister create
and dfx deploy
commands: --with-cycles <with-cycles>
.
This allows the user to specify the initial cycle balance of a canister created by their wallet.
This option is a no-op for the Sodium network.
dfx canister create --with-cycles 8000000000 some_canister
dfx deploy --with-cycles 8000000000
Help string:
Specifies the initial cycle balance to deposit into the newly
created canister. The specified amount needs to take the
canister create fee into account. This amount is deducted
from the wallet's cycle balance
- feat: install
dfx
by version or tag (#1426)
This feature adds a new dfx command toolchain
which have intuitive subcommands.
The toolchain specifiers can be a complete version number, major minor version, or a tag name.
dfx toolchain install 0.6.24 # complete version
dfx toolchain install 0.6 # major minor
dfx toolchain install latest # tag name
dfx toolchain default latest
dfx toolchain list
dfx toolchain uninstall latest
- fix: onboarding related fixups (#1420)
Now that the Mercury Alpha application subnetwork is up and we are getting ready to onboard devs, the dfx error message for wallet creation has changed:
For example,
dfx canister --network=alpha create hello
Creating canister "hello"...
Creating the canister using the wallet canister...
Creating a wallet canister on the alpha network.
Unable to create a wallet canister on alpha:
The Replica returned an error: code 3, message: "Sender not authorized to use method."
Wallet canisters on alpha may only be created by an administrator.
Please submit your Principal ("dfx identity get-principal") in the intake form to have one created for you.
- feat: add deploy wallet subcommand to identity (#1414)
This feature adds the deploy-wallet subcommand to the dfx identity.
The User provides the ID of the canister onto which the wallet WASM is deployed.
dfx identity deploy-wallet --help
dfx-identity-deploy-wallet
Installs the wallet WASM to the provided canister id
USAGE:
dfx identity deploy-wallet <canister-id>
ARGS:
<canister-id> The ID of the canister where the wallet WASM will be deployed
FLAGS:
-h, --help Prints help information
-V, --version Prints version information
0.6.23
Highlights of what's new in 0.6.23
The 0.6.23 release consists of changes to support new features and enhancements that are not yet complete.
The most significant new feature enables you to use a locally-installed @dfinity/bootstrap
server.
SDK 0.6.22
DFX
-
feat: dfx call random value when argument is not provided (#1376)
-
fix: canister call can take canister ids for local canisters even if … (#1368)
-
fix: address panic in dfx replica command (#1338)
-
fix: dfx new webpack.config.js does not encourage running 'js' through ts-… (#1341)
Sample apps
-
There have been updates, improvements, and new sample apps added to the examples repository.
All of Motoko sample apps in the examples repository have been updated to work with the latest release of the SDK.
There are new sample apps to illustrate using arrays (Quicksort) and building create/read/update/delete (CRUD) operations for a web application Superheroes.
-
The LinkedUp sample application has been updated to work with the latest release of Motoko and the SDK.
Motoko
Agents
Canister Development Kit (CDK)
SDK 0.6.21
Release: 0.6.21
0.6.20
Highlights of what's new in 0.6.20
The0.6.20 release primarily both user-facing and internal enhancements, including fixes and updates to {proglang}, the {proglang} base library, and Candid.
The most significant new features and fixes include the following updates:
-
A new notification message that the DFINITY Canister SDK sends anonymous usage data to DFINITY Stiftung by
default has been added todfx
commands. The notification message is only displayed once, the first time you run anydfx
subcommand.
For example, the first time you rundfx new
to create a new project, the notification is displayed before any other project creation messages.The purpose of this notification is to inform you that
dfx
is configured to collect anonymous information aboutdfx
command activity and errors. Collecting anonymous data is enabled by default in an effort to improve the developer experience based on usage patterns and behavior.If you want to prevent the collection of data about
dfx
usage, you can explicitly opt-out by setting the following environment
variable:DFX_TELEMETRY_DISABLED=1
To find out more about the data collected and what your consent means, see the DFINITY Canister SDK Terms and Conditions.
-
The
dfx
commands that support the--network
option have been updated to support URLs when specifying the network value.Previously, the
--network
option required you to specify a network name that matched a network aliases configured in the project'sdfx.json
file.
Candid
The Candid web interface has been updated to provide easier navigation and a better user experience.
The updates to the Candid web interface include the following new features and improvements:
- A new Console drawer provides quick access to method output and a list of all available methods as links for fast navigation.
- Canister methods and their related form elements are more clearly separated and annotated.
- Method output is selectable and easier to toggle between text, UI, and JSON formats.
- The layout is now responsive to provide an optimized display when viewing service using mobile devices or other media.
Motoko
-
The Motoko base documentation examples are now executable in the browser.
-
The Motoko compiler supports specifying command-line arguments using
--args <file>
and--args0 <file>
.The new options enable the compiler to read newline and NUL terminated arguments from a specified file name.
0.6.18
Highlights of what’s new in 0.6.18
The 0.6.18 release primarily includes user-visible new features, internal enhancements, and fixes and updates to the version of Motoko and, the Motoko base library that are supported, and Candid.
The most significant new features and fixes include the following updates:
-
A fix to
dfx upgrade
that prevents amain
thread panic whenOption::unwrap()
is called on aNone
value. -
A fix to the name of the language service command to restore its compatibility with IDEs.
Motoko
-
New syntax for option types: Option blocks
do ? <block>
and option checks<exp> !
.Inside an option block, an option check validates that its operand expression is not null. If it is, the entire option block is aborted and evaluates to null. This simplifies consecutive null handling by avoiding verbose switch expressions.
For example, the expression
do? { f(x!, y!) + z!.a }
evaluates to null if eitherx
,y
, orz
is null; otherwise, it takes the options' contents and ultimately returns?r
, wherer
is the result of the addition.The argument to a
do
ordo ?
expression must be a block { ... }, never a simple expression.
0.6.17
Release: 0.6.17