Skip to content

Commit e462b5e

Browse files
committed
Post rebase fix
1 parent 18186db commit e462b5e

File tree

4 files changed

+21
-20
lines changed

4 files changed

+21
-20
lines changed

cmd/chainlink-ton-extras/lock.nix

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# Notice: `pkgs.lib.fakeHash` can be used as a placeholder,
22
# but `lock-nix-tidy` will only replace actual hashes.
33
{pkgs}: {
4-
chainlink-ton-extras = "sha256-m9CNhGr7TU7Fg/vZAzPpIS5H1OBlZJOVx4dRqABQzMQ=";
4+
chainlink-ton-extras = "sha256-tzNZ2jnRMcF29DSgFmJCeMhfAEzy5qfynocz5zVqwjU=";
55
}

cmd/chainlink-ton/lock.nix

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# Notice: `pkgs.lib.fakeHash` can be used as a placeholder,
22
# but `lock-nix-tidy` will only replace actual hashes.
33
{pkgs}: {
4-
chainlink-ton = "sha256-m9CNhGr7TU7Fg/vZAzPpIS5H1OBlZJOVx4dRqABQzMQ=";
4+
chainlink-ton = "sha256-tzNZ2jnRMcF29DSgFmJCeMhfAEzy5qfynocz5zVqwjU=";
55
}

deployment/pkg/ops/lib/versioning/upgradeable/upgrade.go

Lines changed: 18 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -4,20 +4,21 @@ import (
44
"fmt"
55

66
"github.com/Masterminds/semver/v3"
7+
"github.com/xssnick/tonutils-go/ton"
78
"github.com/xssnick/tonutils-go/ton/wallet"
89

910
"github.com/smartcontractkit/chainlink-deployments-framework/operations"
1011

1112
"github.com/smartcontractkit/chainlink-ton/pkg/bindings/lib/versioning/upgradeable"
1213
"github.com/smartcontractkit/chainlink-ton/pkg/ton/codec"
1314

14-
"github.com/smartcontractkit/chainlink-ton/deployment/pkg/ops/ton"
15+
opston "github.com/smartcontractkit/chainlink-ton/deployment/pkg/ops/ton"
1516
)
1617

1718
var (
18-
_ ton.PlannerOption = UpgradeInput{}
19-
_ ton.Planner[ton.MessagePlanRaw] = UpgradeOutput{}
20-
_ ton.MessageSender = UpgradeOutput{}
19+
_ opston.PlannerOption = UpgradeInput{}
20+
_ opston.Planner[opston.MessagePlanRaw] = UpgradeOutput{}
21+
_ opston.MessageSender = UpgradeOutput{}
2122
)
2223

2324
type UpgradeInput struct {
@@ -28,29 +29,29 @@ type UpgradeInput struct {
2829
}
2930

3031
type UpgradeMessage struct {
31-
Message ton.InternalMessage[upgradeable.Upgrade] `json:"message"`
32-
ContractMeta ton.ContractMetadata `json:"contract_meta"`
32+
Message opston.InternalMessage[upgradeable.Upgrade] `json:"message"`
33+
ContractMeta opston.ContractMetadata `json:"contract_meta"`
3334
}
3435

3536
func (in UpgradeInput) IsPlan() bool {
3637
return in.Plan
3738
}
3839

3940
type UpgradeOutput struct {
40-
Plans []ton.MessagePlanRaw `json:"plans"`
41-
Transaction *ton.TransactionInfo `json:"transaction,omitempty"`
41+
Plans []opston.MessagePlanRaw `json:"plans"`
42+
Transaction *opston.TransactionInfo `json:"transaction,omitempty"`
4243
}
4344

44-
func (o UpgradeOutput) GetPlans() []ton.MessagePlanRaw {
45+
func (o UpgradeOutput) GetPlans() []opston.MessagePlanRaw {
4546
return o.Plans
4647
}
4748

48-
func (o UpgradeOutput) GetTransaction() *ton.TransactionInfo {
49+
func (o UpgradeOutput) GetTransaction() *opston.TransactionInfo {
4950
return o.Transaction
5051
}
5152

5253
type UpgradeDeps struct {
53-
ContractProvider ton.ContractCodeProvider
54+
ContractProvider opston.ContractCodeProvider
5455
Wallet *wallet.Wallet
5556
Client ton.APIClientWrapped
5657
}
@@ -60,8 +61,8 @@ var Upgrade = operations.NewOperation(
6061
semver.MustParse("0.1.0"),
6162
"Upgrades upgradeable contracts to a new implementation",
6263
func(b operations.Bundle, deps UpgradeDeps, in UpgradeInput) (UpgradeOutput, error) {
63-
// Load contracts and prepare the underlying []ton.InternalMessage[any]
64-
_messages := make([]ton.InternalMessage[any], len(in.Messages))
64+
// Load contracts and prepare the underlying []opston.InternalMessage[any]
65+
_messages := make([]opston.InternalMessage[any], len(in.Messages))
6566
for i, u := range in.Messages {
6667
c, err := deps.ContractProvider.GetContract(u.ContractMeta)
6768
if err != nil {
@@ -74,7 +75,7 @@ var Upgrade = operations.NewOperation(
7475
val.Code = c.Code
7576
valAny := any(val)
7677

77-
_messages[i] = ton.InternalMessage[any]{
78+
_messages[i] = opston.InternalMessage[any]{
7879
Bounce: m.Bounce,
7980
DstAddr: m.DstAddr,
8081
Amount: m.Amount,
@@ -87,18 +88,18 @@ var Upgrade = operations.NewOperation(
8788
}
8889
}
8990

90-
_in := ton.SendMessagesInput{
91+
_in := opston.SendMessagesInput{
9192
Messages: _messages,
9293
Plan: in.Plan,
9394
}
9495

9596
// TOOD: improve deps passing
96-
opdeps := ton.SendMessagesDeps{
97+
opdeps := opston.SendMessagesDeps{
9798
Wallet: deps.Wallet,
9899
Client: deps.Client,
99100
}
100101

101-
r, err := operations.ExecuteOperation(b, ton.SendMessages, opdeps, _in)
102+
r, err := operations.ExecuteOperation(b, opston.SendMessages, opdeps, _in)
102103
if err != nil {
103104
return UpgradeOutput{}, fmt.Errorf("failed to exec send messages operation: %w", err)
104105
}

scripts/oplint/lock.nix

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
{pkgs}: {
2-
oplint = "sha256-m9CNhGr7TU7Fg/vZAzPpIS5H1OBlZJOVx4dRqABQzMQ=";
2+
oplint = "sha256-tzNZ2jnRMcF29DSgFmJCeMhfAEzy5qfynocz5zVqwjU=";
33
}

0 commit comments

Comments
 (0)