Skip to content

Commit

Permalink
push bin fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
CyberHoward committed May 29, 2024
1 parent 64c4f55 commit b800ee7
Show file tree
Hide file tree
Showing 12 changed files with 32 additions and 79 deletions.
2 changes: 0 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
/target

artifacts

Cargo.lock

.env
Expand Down
2 changes: 2 additions & 0 deletions artifacts/checksums.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
cc97f662a3c2531c01b79f2104ff11c3c29e566797a69080f1ebc23082e9a42d ibcmail_client-aarch64.wasm
49d94f6e23f3ca549d4536911e8805ed23419d1c13988208f82f0e3eb1275856 ibcmail_server-aarch64.wasm
2 changes: 2 additions & 0 deletions artifacts/checksums_intermediate.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
c42e5cd5be2f9865d1cd67b9d2c651ce8a9d15cbb2bca42bc6f28873ee15cf6d target/wasm32-unknown-unknown/release/ibcmail_client.wasm
2540d503f00364ac656aecaf6e39cc49e0bdb17084d09d6dbcae2413a3de79a9 target/wasm32-unknown-unknown/release/ibcmail_server.wasm
Binary file added artifacts/ibcmail_client-aarch64.wasm
Binary file not shown.
Binary file added artifacts/ibcmail_server-aarch64.wasm
Binary file not shown.
2 changes: 1 addition & 1 deletion contracts/client/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ cw-asset = { workspace = true }
abstract-app = "0.22"
ibcmail = { workspace = true }
cw-paginate = { workspace = true }
base64 = { version = "0.22.1", default-features = false }
base64 = { version = "0.22.1", default-features = false, features = ["alloc"]}

# Dependencies for interface
cw-orch = { workspace = true, optional = true }
Expand Down
4 changes: 2 additions & 2 deletions contracts/server/src/handlers/execute.rs
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ use abstract_adapter::std::{
IBC_CLIENT,
};
use abstract_adapter::traits::AbstractResponse;
use cosmwasm_std::{to_json_binary, wasm_execute, CosmosMsg, Deps, DepsMut, Env, MessageInfo};
use cosmwasm_std::{to_json_binary, wasm_execute, Addr, CosmosMsg, Deps, DepsMut, Env, MessageInfo};
use ibcmail::client::api::MailClient;
use ibcmail::{
client::api::ClientInterface,
Expand Down Expand Up @@ -130,7 +130,7 @@ pub(crate) fn route_msg(
callback_info: None,
};

let ibc_client_addr: cw_orch::prelude::Addr = app
let ibc_client_addr: Addr = app
.module_registry(deps.as_ref())?
.query_module(ModuleInfo::from_id_latest(IBC_CLIENT)?)?
.reference
Expand Down
8 changes: 0 additions & 8 deletions example.env

This file was deleted.

2 changes: 1 addition & 1 deletion packages/ibcmail/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ use abstract_app::std::objects::{
use const_format::concatcp;
use cosmwasm_std::Timestamp;

pub const IBCMAIL_NAMESPACE: &str = "ibcmail";
pub const IBCMAIL_NAMESPACE: &str = "ibcmail-demo";
pub const IBCMAIL_CLIENT_ID: &str = concatcp!(IBCMAIL_NAMESPACE, ":", "client");
pub const IBCMAIL_SERVER_ID: &str = concatcp!(IBCMAIL_NAMESPACE, ":", "server");

Expand Down
37 changes: 0 additions & 37 deletions template-setup.sh

This file was deleted.

10 changes: 8 additions & 2 deletions tests/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,18 @@ edition = "2021"

# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html

[[bin]]
name = "demo"

[features]
default = []

[dependencies]
abstract-app = { version = "0.22", features = ["test-utils"] }
abstract-cw-orch-polytone = "2.0.0"
abstract-interface = "0.22"
abstract-interchain-tests = { git = "https://github.com/AbstractSDK/abstract", version = "0.22.1", branch = "removemm" }
cw-orch = { package = "cw-orch-interchain", git = "ssh://[email protected]/AbstractSDK/cw-orch-interchain.git", tag = "v0.22.0" }

ibcmail = { workspace = true }
cosmwasm-std = { workspace = true }
cosmwasm-schema = { workspace = true }
Expand All @@ -23,4 +26,7 @@ cw-asset = { workspace = true }
client = { workspace = true, features = ["interface"] }
speculoos = { workspace = true }
server = { workspace = true, features = ["interface"] }
abstract-client = { workspace = true }
abstract-client = { workspace = true }
clap.workspace = true
env_logger = "0.11.3"
dotenv = { workspace = true }
42 changes: 16 additions & 26 deletions tests/bin/test_with_archway.rs → tests/src/bin/demo.rs
Original file line number Diff line number Diff line change
@@ -1,12 +1,3 @@
//! Publishes the module to the Abstract platform by uploading it and registering it on the client store.
//!
//! Info: The mnemonic used to register the module must be the same as the owner of the account that claimed the namespace.
//!
//! ## Example
//!
//! ```bash
//! $ just publish uni-6 osmo-test-5
//! ```
use abstract_app::{
objects::{
account::AccountTrace,
Expand All @@ -22,21 +13,17 @@ use abstract_app::{
},
};
use abstract_client::AbstractClient;
use abstract_interface::{Abstract, VersionControl};
use abstract_interface::{Abstract, DependencyCreation, VersionControl};
use clap::Parser;
use cw_orch::{
anyhow,
daemon::networks::{ARCHWAY_1, NEUTRON_1},
prelude::*,
tokio::runtime::Runtime,
};
use client::{msg::ClientInstantiateMsg, ClientInterface};
use cw_orch::{anyhow, prelude::*, tokio::runtime::Runtime};
use ibcmail::{client::msg::ClientExecuteMsgFns, Message, IBCMAIL_NAMESPACE};
use ibcmail_client::ClientInterface;
use networks::{HARPOON_4, PION_1};

const SRC: ChainInfo = ARCHWAY_1;
const DST: ChainInfo = NEUTRON_1;
const SRC: ChainInfo = HARPOON_4;
const DST: ChainInfo = PION_1;

const TEST_NAMESPACE: &str = "mailtest";
const TEST_NAMESPACE: &str = "ibcmail-demo";

fn test() -> anyhow::Result<()> {
let rt = Runtime::new()?;
Expand All @@ -56,13 +43,14 @@ fn test() -> anyhow::Result<()> {
.ibc
.client
.list_remote_hosts()?;

println!("hosts: {:?}", hosts);

update_ibc_host(abs_src.version_control())?;
update_ibc_host(abs_dst.version_control())?;
// update_ibc_host(abs_src.version_control())?;
// update_ibc_host(abs_dst.version_control())?;

approve_mail_modules(abs_src.version_control())?;
approve_mail_modules(abs_dst.version_control())?;
// approve_mail_modules(abs_src.version_control())?;
// approve_mail_modules(abs_dst.version_control())?;

let module_list = abs_src.version_control().module_list(
Some(ModuleFilter {
Expand All @@ -81,6 +69,8 @@ fn test() -> anyhow::Result<()> {
.install_on_sub_account(false)
.namespace(Namespace::new(TEST_NAMESPACE)?)
.build()?;

src_acc.install_app_with_dependencies::<ClientInterface<_>>(&ClientInstantiateMsg {}, Empty {}, &[])?;
// let app = src_acc.install_app_with_dependencies::<ClientInterface<_>>(&ClientInstantiateMsg {}, Empty {},&[])?;
// app.authorize_on_adapters(&[IBCMAIL_SERVER_ID])?;
let src_client = src_acc.application::<ClientInterface<_>>()?;
Expand Down Expand Up @@ -157,9 +147,9 @@ pub fn approve_mail_modules<Env: CwEnv>(vc: &VersionControl<Env>) -> anyhow::Res
#[command(author, version, about, long_about = None)]
struct Arguments {}

fn main() {
fn main() -> anyhow::Result<()> {
dotenv::dotenv().ok();
env_logger::init();
let _args = Arguments::parse();
test().unwrap();
test()
}

0 comments on commit b800ee7

Please sign in to comment.