Skip to content

Commit

Permalink
Merge pull request #4 from Olex-Engineering/feature/update-anchor
Browse files Browse the repository at this point in the history
[FEATURE] - Update anchor-lang to 0.29.0, bump clockwork version to 2…
  • Loading branch information
iamvon authored Jan 17, 2024
2 parents 0d24781 + ea40943 commit 2b34160
Show file tree
Hide file tree
Showing 17 changed files with 434 additions and 211 deletions.
511 changes: 367 additions & 144 deletions Cargo.lock

Large diffs are not rendered by default.

30 changes: 15 additions & 15 deletions cli/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "clockwork-cli"
version = "2.0.19"
version = "2.0.20"
description = "Command line interface for Clockwork"
edition = "2021"
license = "AGPL-3.0-or-later"
Expand All @@ -12,31 +12,31 @@ keywords = ["solana"]
build = "build.rs"

[dependencies]
anchor-lang = "0.28.0"
anchor-spl = { features = ["mint", "token"], version = "0.28.0" }
anchor-lang = "0.29.0"
anchor-spl = { features = ["mint", "token"], version = "0.29.0" }
anyhow = "1.0.61"
bincode = "1.3.3"
bzip2 = "0.4"
clap = { version = "3.1.2", features = ["derive"] }
clockwork-cron = { path = "../cron", version = "=2.0.19" }
clockwork-network-program = { path = "../programs/network", version = "=2.0.19", features = ["no-entrypoint"] }
clockwork-relayer-api = { path = "../relayer/api", version = "=2.0.19" }
clockwork-plugin-utils= { path = "../plugin/utils", version = "=2.0.19" }
clockwork-thread-program = { path = "../programs/thread", version = "=2.0.19", features = ["no-entrypoint"] }
clockwork-utils = { path = "../utils", version = "=2.0.19" }
clockwork-webhook-program = { path = "../programs/webhook", version = "=2.0.19", features = ["no-entrypoint"] }
clockwork-cron = { path = "../cron", version = "=2.0.20" }
clockwork-network-program = { path = "../programs/network", version = "=2.0.20", features = ["no-entrypoint"] }
clockwork-relayer-api = { path = "../relayer/api", version = "=2.0.20" }
clockwork-plugin-utils= { path = "../plugin/utils", version = "=2.0.20" }
clockwork-thread-program = { path = "../programs/thread", version = "=2.0.20", features = ["no-entrypoint"] }
clockwork-utils = { path = "../utils", version = "=2.0.20" }
clockwork-webhook-program = { path = "../programs/webhook", version = "=2.0.20", features = ["no-entrypoint"] }
chrono = { version = "0.4.19", default-features = false, features = ["alloc"] }
dirs-next = "2.0.0"
indicatif = "0.16"
reqwest = "0.11.14"
serde = { version = "1.0.136", features = ["derive"] }
serde_json = "1.0.79"
serde_yaml = "0.9.4"
solana-account-decoder = "=1.16.12"
solana-client = "=1.16.12"
solana-clap-utils = "=1.16.12"
solana-cli-config = "=1.16.12"
solana-sdk = "=1.16.12"
solana-account-decoder = "^1.16.13"
solana-client = "^1.16.13"
solana-clap-utils = "^1.16.13"
solana-cli-config = "^1.16.13"
solana-sdk = "^1.16.13"
spl-associated-token-account = "1.1.1"
spl-memo = "4.0.0"
spl-token = "~4.0.0"
Expand Down
2 changes: 1 addition & 1 deletion cron/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "clockwork-cron"
version = "2.0.19"
version = "2.0.20"
description = "A cron expression parser that's safe to use in the Solana runtime"
edition = "2021"
license = "AGPL-3.0-or-later"
Expand Down
32 changes: 16 additions & 16 deletions plugin/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "clockwork_plugin"
version = "2.0.19"
version = "2.0.20"
# this needs to match whatever solana uses!
rust-version = "1.72.0"
edition = "2021"
Expand All @@ -19,21 +19,21 @@ crate-type = ["cdylib", "rlib"]
name = "clockwork_plugin"

[dependencies]
anchor-lang = "0.28.0"
anchor-lang = "0.29.0"
async_once = "0.2.6"
async-trait = "0.1.64"
bincode = "1.3.3"
bs58 = "0.4.0"
bugsnag = "0.2.1"
chrono = { version = "0.4.19", default-features = false, features = ["alloc"] }
clockwork-cron = { path = "../cron", version = "=2.0.19" }
clockwork-network-program = { path = "../programs/network", version = "=2.0.19" }
clockwork-plugin-utils = { path = "utils", version = "=2.0.19" }
clockwork-relayer-api = { path = "../relayer/api", version = "=2.0.19" }
clockwork-thread-program = { package = "clockwork-thread-program", path = "../programs/thread", version = "=2.0.19" }
clockwork-cron = { path = "../cron", version = "=2.0.20" }
clockwork-network-program = { path = "../programs/network", version = "=2.0.20" }
clockwork-plugin-utils = { path = "utils", version = "=2.0.20" }
clockwork-relayer-api = { path = "../relayer/api", version = "=2.0.20" }
clockwork-thread-program = { package = "clockwork-thread-program", path = "../programs/thread", version = "=2.0.20" }
clockwork-thread-program-v1 = { package = "clockwork-thread-program-v1", path = "../programs/thread/v1", version = "=1.4.4" }
clockwork-webhook-program = { path = "../programs/webhook", version = "=2.0.19" }
clockwork-utils = { path = "../utils", version = "=2.0.19" }
clockwork-webhook-program = { path = "../programs/webhook", version = "=2.0.20" }
clockwork-utils = { path = "../utils", version = "=2.0.20" }
lazy_static = "1.4.0"
log = "0.4"
prost = "0.10.0"
Expand All @@ -42,13 +42,13 @@ reqwest = "0.11.11"
serde = { version = "1.0", features = ["derive"] }
serde_json = "1.0"
simple-error = "0.2.3"
solana-account-decoder = "=1.16.12"
solana-client = "=1.16.12"
solana-geyser-plugin-interface = "=1.16.12"
solana-logger = "=1.16.12"
solana-program = "=1.16.12"
solana-sdk = "=1.16.12"
solana-transaction-status = "=1.16.12"
solana-account-decoder = "^1.16.13"
solana-client = "^1.16.13"
solana-geyser-plugin-interface = "^1.16.13"
solana-logger = "^1.16.13"
solana-program = "^1.16.13"
solana-sdk = "^1.16.13"
solana-transaction-status = "^1.16.13"
thiserror = "1.0.30"
tokio = "1.18.4"
futures = "0.3.26"
Expand Down
4 changes: 2 additions & 2 deletions plugin/utils/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "clockwork-plugin-utils"
version = "2.0.19"
version = "2.0.20"
edition = "2021"
description = "Clockwork Plugin Utils"
license = "AGPL-3.0-or-later"
Expand All @@ -17,4 +17,4 @@ name = "clockwork_plugin_utils"
[dependencies]
serde = { version = "1.0", features = ["derive"] }
serde_json = "1.0"
solana-geyser-plugin-interface = "=1.16.12"
solana-geyser-plugin-interface = "^1.16.13"
8 changes: 4 additions & 4 deletions programs/network/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "clockwork-network-program"
version = "2.0.19"
version = "2.0.20"
description = "Clockwork networking protocol"
edition = "2021"
license = "AGPL-3.0-or-later"
Expand All @@ -22,6 +22,6 @@ cpi = ["no-entrypoint"]
default = []

[dependencies]
anchor-lang = "0.28.0"
anchor-spl = { features = ["mint", "token"], version = "0.28.0" }
clockwork-utils = { path = "../../utils", version = "=2.0.19" }
anchor-lang = "0.29.0"
anchor-spl = { features = ["mint", "token"], version = "0.29.0" }
clockwork-utils = { path = "../../utils", version = "=2.0.20" }
2 changes: 1 addition & 1 deletion programs/network/src/instructions/delegation_withdraw.rs
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ pub fn handler(ctx: Context<DelegationWithdraw>, amount: u64) -> Result<()> {
let token_program = &ctx.accounts.token_program;

// Transfer tokens from authority tokens to delegation
let bump = *ctx.bumps.get("delegation").unwrap();
let bump = ctx.bumps.delegation;
transfer(
CpiContext::new_with_signer(
token_program.to_account_info(),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ pub fn handler(ctx: Context<StakeDelegationsProcessDelegation>) -> Result<Thread

// Transfer tokens from delegation to worker account.
let amount = delegation_stake.amount;
let bump = *ctx.bumps.get("delegation").unwrap();
let bump = ctx.bumps.delegation;
transfer(
CpiContext::new_with_signer(
token_program.to_account_info(),
Expand Down
2 changes: 1 addition & 1 deletion programs/network/src/state/fee.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
use anchor_lang::{prelude::*, AnchorDeserialize};
use anchor_lang::prelude::*;

pub const SEED_FEE: &[u8] = b"fee";

Expand Down
10 changes: 5 additions & 5 deletions programs/thread/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "clockwork-thread-program"
version = "2.0.19"
version = "2.0.20"
description = "Clockwork thread program"
edition = "2021"
license = "AGPL-3.0-or-later"
Expand All @@ -22,12 +22,12 @@ cpi = ["no-entrypoint"]
default = []

[dependencies]
anchor-lang = "0.28.0"
anchor-lang = "0.29.0"
chrono = { version = "0.4.19", default-features = false, features = ["alloc"] }
clockwork-cron = { path = "../../cron", version = "=2.0.19" }
clockwork-network-program = { path = "../network", features = ["cpi"], version = "=2.0.19" }
clockwork-cron = { path = "../../cron", version = "=2.0.20" }
clockwork-network-program = { path = "../network", features = ["cpi"], version = "=2.0.20" }
clockwork-thread-program-v1 = { path = "v1", version = "=1.4.4" }
clockwork-utils = { path = "../../utils", version = "=2.0.19" }
clockwork-utils = { path = "../../utils", version = "=2.0.20" }
pyth-sdk-solana = "0.8.0"
static-pubkey = "1.0.3"
version = "3.0.0"
2 changes: 1 addition & 1 deletion programs/thread/src/instructions/thread_create.rs
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ pub fn handler(ctx: Context<ThreadCreate>, amount: u64, id: Vec<u8>, instruction
let thread = &mut ctx.accounts.thread;

// Initialize the thread
let bump = *ctx.bumps.get("thread").unwrap();
let bump = ctx.bumps.thread;
thread.authority = authority.key();
thread.bump = bump;
thread.created_at = Clock::get().unwrap().into();
Expand Down
2 changes: 1 addition & 1 deletion programs/thread/v1/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -18,5 +18,5 @@ no-log-ix-name = []
cpi = ["no-entrypoint"]

[dependencies]
anchor-lang = "0.28.0"
anchor-lang = "0.29.0"
clockwork-anchor-gen = { version = "0.3.2", features = ["compat-program-result"] }
8 changes: 4 additions & 4 deletions programs/webhook/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "clockwork-webhook-program"
version = "2.0.19"
version = "2.0.20"
description = "Clockwork webhook program"
edition = "2021"
license = "AGPL-3.0-or-later"
Expand All @@ -22,7 +22,7 @@ cpi = ["no-entrypoint"]
default = []

[dependencies]
anchor-lang = { features = ["init-if-needed"], version = "0.28.0" }
clockwork-network-program = { path = "../network", features = ["cpi"], version = "=2.0.19" }
clockwork-utils = { path = "../../utils", version = "=2.0.19" }
anchor-lang = { features = ["init-if-needed"], version = "0.29.0" }
clockwork-network-program = { path = "../network", features = ["cpi"], version = "=2.0.20" }
clockwork-utils = { path = "../../utils", version = "=2.0.20" }
serde = "1.0.152"
14 changes: 7 additions & 7 deletions relayer/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "clockwork-relayer"
version = "2.0.19"
version = "2.0.20"
edition = "2021"
description = "Clockwork relayer for webhook requests"
license = "AGPL-3.0-or-later"
Expand All @@ -16,18 +16,18 @@ publish = false
[dependencies]
actix-cors = "0.6.4"
actix-web = "4.3.1"
anchor-lang = "0.28.0"
anchor-lang = "0.29.0"
byte-unit = "4.0.18"
clockwork-webhook-program = { path = "../programs/webhook", version = "=2.0.19" }
clockwork-relayer-api = { path = "api", version = "=2.0.19" }
clockwork-webhook-program = { path = "../programs/webhook", version = "=2.0.20" }
clockwork-relayer-api = { path = "api", version = "=2.0.20" }
curve25519-dalek = "3.2.1"
lazy_static = "1.4.0"
reqwest = "0.11.14"
serde = "1.0.152"
serde_json = "1.0.94"
solana-client = "=1.16.12"
solana-zk-token-sdk = "=1.16.12"
solana-sdk = "=1.16.12"
solana-client = "^1.16.13"
solana-zk-token-sdk = "^1.16.13"
solana-sdk = "^1.16.13"
tokio = "1.26.0"
bincode = "1.3.3"
rayon = "1.7.0"
Expand Down
6 changes: 3 additions & 3 deletions relayer/api/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "clockwork-relayer-api"
version = "2.0.19"
version = "2.0.20"
edition = "2021"
description = "Clockwork relayer for webhook requests"
license = "AGPL-3.0-or-later"
Expand All @@ -23,7 +23,7 @@ name = "clockwork_relayer_api"
# lazy_static = "1.4.0"
serde = "1.0.152"
# shadow-drive-sdk = "0.6.1"
# solana-zk-token-sdk = "=1.16.12"
solana-sdk = "=1.16.12"
# solana-zk-token-sdk = "^1.16.13"
solana-sdk = "^1.16.13"
# tokio = "1.26.0"
bincode = "1.3.3"
6 changes: 3 additions & 3 deletions sdk/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "clockwork-sdk"
version = "2.0.19"
version = "2.0.20"
description = "An SDK for building automated programs on Solana"
edition = "2021"
license = "AGPL-3.0-or-later"
Expand All @@ -14,9 +14,9 @@ keywords = ["solana"]
name = "clockwork_sdk"

[dependencies]
anchor-lang = "0.28.0"
anchor-lang = "0.29.0"
chrono = { version = "0.4.19", default-features = false, features = ["alloc"] }
clockwork-thread-program = { path = "../programs/thread", features = ["cpi"], version = "=2.0.19" }
clockwork-thread-program = { path = "../programs/thread", features = ["cpi"], version = "=2.0.20" }
nom = "~7"
once_cell = "1.5.2"

Expand Down
4 changes: 2 additions & 2 deletions utils/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "clockwork-utils"
version = "2.0.19"
version = "2.0.20"
description = "Tools for building blocks on Solana"
edition = "2021"
license = "AGPL-3.0-or-later"
Expand All @@ -14,7 +14,7 @@ keywords = ["solana"]
name = "clockwork_utils"

[dependencies]
anchor-lang = "0.28.0"
anchor-lang = "0.29.0"
base64 = "~0.13"
serde = { version = "1.0", features = ["derive"] }
serde_json = "1.0"
Expand Down

0 comments on commit 2b34160

Please sign in to comment.