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

soroban-rpc: Add auth-next information to simulateTransaction response #395

Merged
merged 18 commits into from
Feb 7, 2023
Merged
Show file tree
Hide file tree
Changes from 16 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/workflows/soroban-rpc.yml
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ jobs:
env:
SOROBAN_RPC_INTEGRATION_TESTS_ENABLED: true
SOROBAN_RPC_INTEGRATION_TESTS_CAPTIVE_CORE_BIN: /usr/bin/stellar-core
PROTOCOL_20_CORE_DEBIAN_PKG_VERSION: 19.6.1-1158.c0ad35aa1.focal~soroban
PROTOCOL_20_CORE_DEBIAN_PKG_VERSION: 19.7.1-1178.e352f0012.focal~soroban
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v3
Expand Down
148 changes: 103 additions & 45 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

12 changes: 6 additions & 6 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -10,32 +10,32 @@ default-members = ["cmd/soroban-cli"]
[workspace.dependencies.soroban-env-host]
version = "0.0.12"
git = "https://github.com/stellar/rs-soroban-env"
rev = "993c527abce72748405d71467498bffd63e061c1"
rev = "d65b04f1793c48471995bf67850fffee53b90bd2"
2opremio marked this conversation as resolved.
Show resolved Hide resolved

[workspace.dependencies.soroban-spec]
version = "0.4.1"
git = "https://github.com/stellar/rs-soroban-sdk"
rev = "e1c3de33942f0e997680645941787102ebf61e85"
rev = "8a11d747d969b137ef0dccbc37f23f2966f5fcd1"

[workspace.dependencies.soroban-token-spec]
version = "0.4.1"
git = "https://github.com/stellar/rs-soroban-sdk"
rev = "e1c3de33942f0e997680645941787102ebf61e85"
rev = "8a11d747d969b137ef0dccbc37f23f2966f5fcd1"

[workspace.dependencies.soroban-sdk]
version = "0.4.1"
git = "https://github.com/stellar/rs-soroban-sdk"
rev = "e1c3de33942f0e997680645941787102ebf61e85"
rev = "8a11d747d969b137ef0dccbc37f23f2966f5fcd1"

[workspace.dependencies.soroban-ledger-snapshot]
version = "0.4.1"
git = "https://github.com/stellar/rs-soroban-sdk"
rev = "e1c3de33942f0e997680645941787102ebf61e85"
rev = "8a11d747d969b137ef0dccbc37f23f2966f5fcd1"

[workspace.dependencies.stellar-strkey]
version = "0.0.7"
git = "https://github.com/stellar/rs-stellar-strkey"
rev = "6e9bb10"
rev = "e6ba45c60c16de28c7522586b80ed0150157df73"

# [patch."https://github.com/stellar/rs-soroban-env"]
# soroban-env-host = { path = "../rs-soroban-env/soroban-env-host/" }
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#![no_std]
use soroban_sdk::{contractimpl, contracttype, symbol, vec, AccountId, Bytes, Env, Symbol, Vec};
use soroban_sdk::{contractimpl, contracttype, symbol, vec, Address, Bytes, Env, Symbol, Vec};

pub struct Contract;

Expand Down Expand Up @@ -63,8 +63,8 @@ impl Contract {
complex
}

pub fn account(_env: Env, account: AccountId) -> AccountId {
account
pub fn account(_env: Env, address: Address) -> Address {
address
}

pub fn bytes(_env: Env, bytes: Bytes) -> Bytes {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#![no_std]
use soroban_sdk::{contractimpl, symbol, vec, Env, Symbol, Vec};
use soroban_sdk::{contractimpl, symbol, vec, Address, Env, Symbol, Vec};

pub struct Contract;

Expand All @@ -16,6 +16,11 @@ impl Contract {
pub fn not(env: Env, boolean: bool) -> Vec<bool> {
vec![&env, !boolean]
}

pub fn auth(env: Env, addr: Address, world: Symbol) -> Vec<Symbol> {
addr.require_auth();
vec![&env, symbol!("Hello"), world]
}
}

#[cfg(test)]
Expand Down
Loading