Skip to content

Releases: CashScript/cashscript

v0.2.2

08 Nov 20:11
Compare
Choose a tag to compare
v0.2.2 Pre-release
Pre-release

CashScript SDK

  • 🐛 Remove minimaldata encoding in OP_RETURN outputs that caused incompatibility with SLP.
  • 📛 Renamed Contract.fromCashFile to Contract.compile.
    • The new function allows to pass in a path to a .cash file, or a string of the contract source code.
    • Contract.fromCashFile still exists for backward compatibility, but is deprecated and will be removed in a later release.
  • 📛 Renamed Contract.fromArtifact to Contract.import.
    • The new function allows to pass in a path to a .json artifact file, or a JSON object of the artifact.
    • Contract.fromArtifact still exists for backward compatibility, but is deprecated and will be removed in a later release.
  • 🛠️ instance.export's fn argument is now optional.
    • If it is provided, the artifact is written to the file, if not, it is returned as an object.

https://twitter.com/RoscoKalis/status/1192900277105389568

v0.2.1

22 Oct 07:59
Compare
Choose a tag to compare
v0.2.1 Pre-release
Pre-release

cashc compiler

  • ✨ Support bytes types with bounded size, e.g. bytes1, bytes13, bytes32.
  • 🐛 Fix bug in bytecode optimisation

CashScript SDK

  • ✨ Support bytes types with bounded size, e.g. bytes1, bytes13, bytes32.
  • 🐦 Automatically output meep command on failed transaction error.
  • 🔨 Make the hashtype parameter in signature placeholders optional.

https://twitter.com/RoscoKalis/status/1186554051720167424

v0.2.0

01 Oct 00:52
Compare
Choose a tag to compare
v0.2.0 Pre-release
Pre-release

cashc compiler

  • 🐎 Implement compiler optimisations
    • For the final use of a variable, it is retrieved with OP_ROLL rather than OP_PICK. This removes the need to clean the stack at the end of a contract.
    • Final OP_VERIFY OP_TRUE is removed as there is an implicit OP_VERIFY at the end of a Script.
    • OP_VERIFY is merged with preceding opcode where applicable.
    • Shallow OP_PICK and OP_ROLL are replaced by hardcoded opcodes (e.g. OP_SWAP, OP_DUP).
    • Several other bytecode optimisations.
  • ✨ Add pragma keyword to specify intended compiler version.
    • Example: pragma cashscript ^0.2.0;
    • Contract fails to compile when compiler version does not satisfy constraints.
  • 🚨 Add CashProof for all individual bytecode optimisations and for example contracts from 0.1.2 to 0.2.0.
  • 🐛 Add "default case" for function selection that fixes a vulnerability where people could spend funds by not calling any function.
  • ⬆️ Update dependencies.

CashScript SDK

  • ⬆️ Update cashc and other dependencies.

Update notes

Due to compiler optimisations, this version of CashScript will output different bytecode than version 0.1.x. Keep this in mind when updating. If you are using contracts compiled with version 0.1.2 make sure to store an artifact file compiled with version 0.1.2 before upgrading to 0.2.0 to keep using these contracts.

Going forward, it is also recommended to add a pragma directive at the start of each contract file to enforce the compiler version that this contract was written for.


https://twitter.com/RoscoKalis/status/1178843657069154305

v0.1.2

19 Sep 09:24
Compare
Choose a tag to compare
v0.1.2 Pre-release
Pre-release

CashScript SDK

  • ✨ Add support for OP_RETURN outputs (fixes #17)
  • 🐛 Improved error handling (fixes #5)
  • 🐛 Poll for transaction details to make sure it's available (fixes #11)
  • 🔥 Enable optional mainnet - NOT RECOMMENDED
  • 🔨 UTXO selection refactor
  • 🚨 Improve Transaction testing

https://twitter.com/RoscoKalis/status/1174910060691984385

v0.1.1

28 Jun 15:50
Compare
Choose a tag to compare
v0.1.1 Pre-release
Pre-release

CashScript SDK

  • 🐛 Bug fixes with incorrect parameter encoding for string/bool/int types.

v0.1.0

13 Jun 07:42
Compare
Choose a tag to compare
v0.1.0 Pre-release
Pre-release
  • 🎉 Initial release.