PocketIC Version 7.0.0: Bitcoin integration and Windows Support

Pocket IC

We have released PocketIC server 7.0.0 and its Rust library 6.0.0. This release contains Bitcoin integration from the roadmap shared in the past PocketIC release forum post and Windows support.

Changelog

Here’s an overview of the new features included in the latest PocketIC release and their use cases:

  • Bitcoin integration: support for IC Bitcoin API via the management canister (tutorial);
  • Windows support: the Rust library can be used natively on Windows if WSL 2 (Windows Subsystem for Linux) is available;
  • New server endpoint /instances/<instance_id>/_/topology returning the topology of the PocketIC instance (also served at /_/topology by the PocketIC HTTP gateway);
  • Rust library convenience functions for the management canister API (canister snapshots, WASM chunk store, canister logs);
  • A new Rust library module pocket_ic::management_canister containing Rust types for the management canister according to its specification.

For a complete list of changes, see the server changelog and the library changelog.

Roadmap

The current main priority is to make PocketIC the default option for canister testing in DFX and allow impersonating principals in selected requests (e.g., impersonating canister controllers when changing canister settings).

To enable testing reentrancy (bugs) in your canisters, we also plan to make it possible to control message execution order in PocketIC, as already shared in the past PocketIC release forum post.

Conclusion

Your feedback helps us improve PocketIC, so please let us know your thoughts and questions in this thread.

Thank you for providing feature requests and feedback on your PocketIC user experience!

5 Likes

Are the inclusions of BTC stuff anything that wouldn’t just consist of internally calling the system canister in our contracts? And if that is the case, should we be able to swap out the server for pic.js and be able to use this version(I guess without access to the new topology endpoint?)

Are the inclusions of BTC stuff anything that wouldn’t just consist of internally calling the system canister in our contracts?

I’d recommend you to follow the linked tutorial to see how to set up PocketIC and its test environment. In your canisters, you’d just call the Bitcoin API (via the management canister or the bitcoin testnet canister).

should we be able to swap out the server for pic.js and be able to use this version

you’d likely need library support to set up the address of your local bitcoind