Skip to content
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
2 changes: 1 addition & 1 deletion .github/packages/npm-package/package.json.tmpl
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@magicblock-labs/${node_pkg}",
"description": "MagicBlock Ephemeral VRF Oracle (${node_pkg})",
"version": "0.2.0",
"version": "0.2.1",
"repository": {
"type": "git",
"url": "git+https://github.com/magicblock-labs/ephemeral-vrf.git"
Expand Down
8 changes: 4 additions & 4 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ resolver = "2"
members = ["api", "program", "sdk", "src", "vrf", "vrf-cli", "vrf-oracle"]

[workspace.package]
version = "0.2.0"
version = "0.2.1"
edition = "2021"
license = "Business Source License 1.1"
authors = ["MagicBlock Labs <[email protected]>"]
Expand All @@ -26,9 +26,9 @@ crossbeam-channel = "0.5.15"
curve25519-dalek = { version = "4.1.3", default-features = false }
env_logger = "0.11.7"
ephemeral-rollups-sdk = "0.2.4"
ephemeral-vrf = { path = "./vrf", version = "0.2.0" }
ephemeral-vrf-api = { path = "./api", version = "0.2.0" }
ephemeral-vrf-sdk-vrf-macro = { path = "sdk/vrf-macro", version = "0.2.0" }
ephemeral-vrf = { path = "./vrf", version = "0.2.1" }
ephemeral-vrf-api = { path = "./api", version = "0.2.1" }
ephemeral-vrf-sdk-vrf-macro = { path = "sdk/vrf-macro", version = "0.2.1" }
futures = "0.3.31"
futures-core = "0.3.31"
futures-util = "0.3.31"
Expand Down
2 changes: 1 addition & 1 deletion sdk/src/anchor.rs
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ pub struct VrfProgram;

#[cfg(feature = "anchor")]
impl anchor_lang::Id for VrfProgram {
fn id() -> ::solana_program::pubkey::Pubkey {
fn id() -> anchor_lang::prelude::Pubkey {
crate::consts::VRF_PROGRAM_ID
}
}
7 changes: 2 additions & 5 deletions sdk/src/instructions.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
use crate::consts;
use crate::solana::{system_program, Pubkey};
use crate::types::{RequestRandomness, SerializableAccountMeta};
use ::solana_program::pubkey::Pubkey;

/// Parameters for creating a request randomness instruction
#[derive(Default)]
Expand All @@ -26,10 +26,7 @@ pub fn create_request_randomness_ix(
true,
),
solana_program::instruction::AccountMeta::new(params.oracle_queue, false),
solana_program::instruction::AccountMeta::new_readonly(
solana_program::system_program::ID,
false,
),
solana_program::instruction::AccountMeta::new_readonly(system_program::ID, false),
solana_program::instruction::AccountMeta::new_readonly(
solana_program::sysvar::slot_hashes::ID,
false,
Expand Down
16 changes: 15 additions & 1 deletion sdk/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,20 @@ pub mod pda;
pub mod rnd;
pub mod types;

pub const fn id() -> ::solana_program::pubkey::Pubkey {
#[cfg(not(feature = "anchor"))]
mod solana {
pub use solana_program::pubkey::Pubkey;
pub use solana_program::system_program;
}

#[cfg(feature = "anchor")]
mod solana {
pub use anchor_lang::prelude::Pubkey;
pub use anchor_lang::system_program;
}

pub use solana::Pubkey;

pub const fn id() -> Pubkey {
consts::VRF_PROGRAM_ID
}