Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

@ton-org deps migration #89

Merged
merged 3 commits into from
Dec 1, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,9 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
### Added
- Continuous integration to run Tact tests on Linux, macOS and Windows: PR [#96](https://github.com/tact-lang/tact/pull/96)

### Changed
- Migration to `@ton` NPM packages: PR [#89](https://github.com/tact-lang/tact/pull/89)

### Fixed
- Struct and message identifiers need to be capitalized: PRs [#81](https://github.com/tact-lang/tact/pull/81) and [#83](https://github.com/tact-lang/tact/pull/83)
- Fixed the signature of the `checkDataSignature` function in `stdlib/std/crypto.tact`: PR [#50](https://github.com/tact-lang/tact/pull/50)
Expand Down
28 changes: 19 additions & 9 deletions examples/__snapshots__/increment.spec.ts.snap
Original file line number Diff line number Diff line change
Expand Up @@ -12,14 +12,17 @@ exports[`increment should deploy 1`] = `
"$type": "received",
"message": {
"body": {
"cell": "x{946A98B60000000000000000}",
"type": "cell",
"type": "known",
"value": {
"$$type": "Deploy",
"queryId": 0n,
},
},
"bounce": true,
"from": "@treasure(treasure)",
"to": "kQDeI5IisUF0tSvWxNDeA-Og-_S1nAT8ZdqTvOZ30HeNgzC1",
"type": "internal",
"value": 10000000000n,
"value": "10",
},
},
{
Expand All @@ -31,14 +34,17 @@ exports[`increment should deploy 1`] = `
"messages": [
{
"body": {
"cell": "x{AFF90F570000000000000000}",
"type": "cell",
"type": "known",
"value": {
"$$type": "DeployOk",
"queryId": 0n,
},
},
"bounce": false,
"from": "kQDeI5IisUF0tSvWxNDeA-Og-_S1nAT8ZdqTvOZ30HeNgzC1",
"to": "@treasure(treasure)",
"type": "internal",
"value": 9990313000n,
"value": "9.990313",
},
],
},
Expand All @@ -56,14 +62,18 @@ exports[`increment should deploy 2`] = `
"$type": "received",
"message": {
"body": {
"cell": "x{20064F3B00000000000000000000000000000000000000000000000000000000000000007FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFECC2_}",
"type": "cell",
"type": "known",
"value": {
"$$type": "Increment",
"key": 0n,
"value": -1232n,
},
},
"bounce": true,
"from": "@treasure(treasure)",
"to": "kQDeI5IisUF0tSvWxNDeA-Og-_S1nAT8ZdqTvOZ30HeNgzC1",
"type": "internal",
"value": 10000000000n,
"value": "10",
},
},
{
Expand Down
2 changes: 1 addition & 1 deletion examples/__snapshots__/multisig-3.spec.ts.snap
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ exports[`muiltisig-3 should deploy 1`] = `
"from": "@treasure(treasure)",
"to": "kQA2dtHnP8ywA0dgkHw5rQTXGtbBDktii55xFgnShHpu1XtQ",
"type": "internal",
"value": 10000000000n,
"value": "10",
},
},
{
Expand Down
22 changes: 17 additions & 5 deletions examples/__snapshots__/wallet.spec.ts.snap
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ exports[`wallet should deploy 1`] = `
"from": "@treasure(treasure)",
"to": "kQCjmMHzL6dRv6HCrACYpCe1qJbXqGp_P1ObgRO1orr1RW5j",
"type": "internal",
"value": 10000000000n,
"value": "10",
},
},
{
Expand All @@ -31,6 +31,10 @@ exports[`wallet should deploy 1`] = `
{
"$seq": 1,
"events": [
{
"$type": "storage-charged",
"amount": "0.000000006",
},
{
"$type": "received",
"message": {
Expand All @@ -43,7 +47,7 @@ exports[`wallet should deploy 1`] = `
"from": "@treasure(treasure)",
"to": "kQCjmMHzL6dRv6HCrACYpCe1qJbXqGp_P1ObgRO1orr1RW5j",
"type": "internal",
"value": 1000000000n,
"value": "1",
},
},
{
Expand All @@ -61,7 +65,7 @@ exports[`wallet should deploy 1`] = `
"from": "kQCjmMHzL6dRv6HCrACYpCe1qJbXqGp_P1ObgRO1orr1RW5j",
"to": "@treasure(treasure)",
"type": "internal",
"value": 10000000000n,
"value": "10",
},
],
},
Expand All @@ -75,6 +79,10 @@ exports[`wallet should deploy 2`] = `
{
"$seq": 2,
"events": [
{
"$type": "storage-charged",
"amount": "0.000000006",
},
{
"$type": "received",
"message": {
Expand All @@ -86,7 +94,7 @@ exports[`wallet should deploy 2`] = `
"from": "@treasure(treasure)",
"to": "kQCjmMHzL6dRv6HCrACYpCe1qJbXqGp_P1ObgRO1orr1RW5j",
"type": "internal",
"value": 1000000000n,
"value": "1",
},
},
{
Expand All @@ -103,6 +111,10 @@ exports[`wallet should deploy 3`] = `
{
"$seq": 3,
"events": [
{
"$type": "storage-charged",
"amount": "0.000000006",
},
{
"$type": "received",
"message": {
Expand All @@ -113,7 +125,7 @@ exports[`wallet should deploy 3`] = `
"from": "@treasure(treasure)",
"to": "kQCjmMHzL6dRv6HCrACYpCe1qJbXqGp_P1ObgRO1orr1RW5j",
"type": "internal",
"value": 1000000000n,
"value": "1",
},
},
{
Expand Down
2 changes: 1 addition & 1 deletion examples/increment.spec.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { IncrementContract } from "./output/increment_IncrementContract";
import { ContractSystem } from "@tact-lang/emulator";
import { toNano } from "ton-core";
import { toNano } from "@ton/core";

describe('increment', () => {
it('should deploy', async () => {
Expand Down
2 changes: 1 addition & 1 deletion examples/multisig-3.spec.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { toNano } from "ton-core";
import { toNano } from "@ton/core";
import { ContractSystem } from "@tact-lang/emulator";
import { MultisigContract } from "./output/multisig-3_MultisigContract";

Expand Down
2 changes: 1 addition & 1 deletion examples/output/echo_Echo.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ import {
ABIReceiver,
TupleBuilder,
DictionaryValue
} from 'ton-core';
} from '@ton/core';

export type StateInit = {
$$type: 'StateInit';
Expand Down
2 changes: 1 addition & 1 deletion examples/output/external_External.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ import {
ABIReceiver,
TupleBuilder,
DictionaryValue
} from 'ton-core';
} from '@ton/core';

export type StateInit = {
$$type: 'StateInit';
Expand Down
2 changes: 1 addition & 1 deletion examples/output/increment_IncrementContract.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ import {
ABIReceiver,
TupleBuilder,
DictionaryValue
} from 'ton-core';
} from '@ton/core';

export type StateInit = {
$$type: 'StateInit';
Expand Down
2 changes: 1 addition & 1 deletion examples/output/inheritance_Contract.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ import {
ABIReceiver,
TupleBuilder,
DictionaryValue
} from 'ton-core';
} from '@ton/core';

export type StateInit = {
$$type: 'StateInit';
Expand Down
2 changes: 1 addition & 1 deletion examples/output/large_Large.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ import {
ABIReceiver,
TupleBuilder,
DictionaryValue
} from 'ton-core';
} from '@ton/core';

export type StateInit = {
$$type: 'StateInit';
Expand Down
2 changes: 1 addition & 1 deletion examples/output/maps_MapTestContract.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ import {
ABIReceiver,
TupleBuilder,
DictionaryValue
} from 'ton-core';
} from '@ton/core';

export type StateInit = {
$$type: 'StateInit';
Expand Down
2 changes: 1 addition & 1 deletion examples/output/multisig-3_MultisigContract.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ import {
ABIReceiver,
TupleBuilder,
DictionaryValue
} from 'ton-core';
} from '@ton/core';

export type StateInit = {
$$type: 'StateInit';
Expand Down
2 changes: 1 addition & 1 deletion examples/output/multisig_Multisig.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ import {
ABIReceiver,
TupleBuilder,
DictionaryValue
} from 'ton-core';
} from '@ton/core';

export type StateInit = {
$$type: 'StateInit';
Expand Down
2 changes: 1 addition & 1 deletion examples/output/multisig_MultisigSigner.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ import {
ABIReceiver,
TupleBuilder,
DictionaryValue
} from 'ton-core';
} from '@ton/core';

export type StateInit = {
$$type: 'StateInit';
Expand Down
2 changes: 1 addition & 1 deletion examples/output/native_Native.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ import {
ABIReceiver,
TupleBuilder,
DictionaryValue
} from 'ton-core';
} from '@ton/core';

export type StateInit = {
$$type: 'StateInit';
Expand Down
2 changes: 1 addition & 1 deletion examples/output/payouts_Beacon.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ import {
ABIReceiver,
TupleBuilder,
DictionaryValue
} from 'ton-core';
} from '@ton/core';

export type StateInit = {
$$type: 'StateInit';
Expand Down
2 changes: 1 addition & 1 deletion examples/output/payouts_Payouts.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ import {
ABIReceiver,
TupleBuilder,
DictionaryValue
} from 'ton-core';
} from '@ton/core';

export type StateInit = {
$$type: 'StateInit';
Expand Down
2 changes: 1 addition & 1 deletion examples/output/rugpull_RugPull.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ import {
ABIReceiver,
TupleBuilder,
DictionaryValue
} from 'ton-core';
} from '@ton/core';

export type StateInit = {
$$type: 'StateInit';
Expand Down
2 changes: 1 addition & 1 deletion examples/output/treasure_Treasure.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ import {
ABIReceiver,
TupleBuilder,
DictionaryValue
} from 'ton-core';
} from '@ton/core';

export type StateInit = {
$$type: 'StateInit';
Expand Down
2 changes: 1 addition & 1 deletion examples/output/wallet-opt_Wallet.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ import {
ABIReceiver,
TupleBuilder,
DictionaryValue
} from 'ton-core';
} from '@ton/core';

export type StateInit = {
$$type: 'StateInit';
Expand Down
2 changes: 1 addition & 1 deletion examples/output/wallet_Wallet.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ import {
ABIReceiver,
TupleBuilder,
DictionaryValue
} from 'ton-core';
} from '@ton/core';

export type StateInit = {
$$type: 'StateInit';
Expand Down
4 changes: 2 additions & 2 deletions examples/wallet.spec.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { storeTransfer, Transfer, Wallet } from "./output/wallet_Wallet";
import { ContractSystem, testKey } from "@tact-lang/emulator";
import { beginCell, toNano } from "ton-core";
import { sign } from "ton-crypto";
import { beginCell, toNano } from "@ton/core";
import { sign } from "@ton/crypto";

describe('wallet', () => {
it('should deploy', async () => {
Expand Down
2 changes: 1 addition & 1 deletion jest.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,5 +5,5 @@ module.exports = {
maxWorkers: 1,
globalSetup: './jest.setup.js',
globalTeardown: './jest.teardown.js',
snapshotSerializers: ["ton-jest/serializers"],
snapshotSerializers: ["@tact-lang/ton-jest/serializers"],
};
15 changes: 8 additions & 7 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
},
"dependencies": {
"@ipld/dag-pb": "2.1.18",
"@tact-lang/opcode": "^0.0.13",
"@tact-lang/opcode": "^0.0.14",
"arg": "^5.0.2",
"blockstore-core": "1.0.5",
"change-case": "^4.1.2",
Expand All @@ -40,15 +40,15 @@
"path-normalize": "^6.0.10",
"prando": "^6.0.1",
"qs": "^6.11.0",
"ton-core": ">=0.49.0",
"ton-crypto": "^3.2.0",
"@ton/core": "0.49.2",
"@ton/crypto": "^3.2.0",
"zod": "^3.20.2"
},
"devDependencies": {
"@ohm-js/cli": "^1.1.0",
"@release-it/keep-a-changelog": "^3.1.0",
"@tact-lang/coverage": "^0.0.5",
"@tact-lang/emulator": "^3.4.1",
"@tact-lang/coverage": "^0.0.8",
"@tact-lang/emulator": "^4.2.3",
"@types/glob": "^8.1.0",
"@types/jest": "^29.2.3",
"@types/js-yaml": "^4.0.5",
Expand All @@ -63,10 +63,11 @@
"rollup": "^3.17.2",
"shiki": "^0.12.1",
"ton-compiler": "^2.3.0",
"ton-jest": "^0.0.3",
"@tact-lang/ton-jest": "^0.0.4",
"ts-jest": "^29.0.3",
"ts-node": "^10.9.1",
"typescript": "^4.9.3"
"typescript": "^4.9.3",
"@tact-lang/ton-abi": "^0.0.3"
},
"publishConfig": {
"access": "public",
Expand Down
2 changes: 1 addition & 1 deletion scripts/prepare.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import fs from 'fs';
import { decompileAll } from '@tact-lang/opcode';
import { run } from '../src/node';
import { Cell } from 'ton-core';
import { Cell } from '@ton/core';
import { build } from '../src/pipeline/build';
import { FuncCompilationResult, funcCompile } from '../src/func/funcCompile';
import path from 'path';
Expand Down
Loading