[package]
name = "namada_core"
description = "Namada core"
resolver = "2"
authors.workspace = true
edition.workspace = true
documentation.workspace = true
homepage.workspace = true
keywords.workspace = true
license.workspace = true
readme.workspace = true
repository.workspace = true
version.workspace = true

[features]
default = []
mainnet = []
rand = ["dep:rand", "rand_core"]
ethers-derive = ["ethbridge-structs/ethers-derive"]
# for tests and test utilities
testing = ["rand", "proptest"]
migrations = ["namada_migrations", "linkme"]
benches = ["proptest"]
control_flow = ["lazy_static", "tokio", "wasmtimer"]
arbitrary = [
  "dep:arbitrary",
  "chrono/arbitrary",
  "ibc/arbitrary",
  "indexmap/arbitrary",
  "masp_primitives/arbitrary",
]
task_env = ["tokio"]

[dependencies]
namada_macros.workspace = true
namada_migrations = { workspace = true, optional = true }

arbitrary = { workspace = true, optional = true }
arse-merkle-tree.workspace = true
bech32.workspace = true
borsh.workspace = true
chrono.workspace = true
data-encoding.workspace = true
ed25519-consensus.workspace = true
ethabi.workspace = true
ethbridge-structs.workspace = true
eyre.workspace = true
ibc.workspace = true
ics23.workspace = true
impl-num-traits.workspace = true
usize-set.workspace = true
indexmap.workspace = true
k256.workspace = true
lazy_static = { workspace = true, optional = true }
linkme = { workspace = true, optional = true }
masp_primitives.workspace = true
num256.workspace = true
num_enum.workspace = true
num-integer.workspace = true
num-rational.workspace = true
num-traits.workspace = true
primitive-types.workspace = true
proptest = { workspace = true, optional = true }
prost-types.workspace = true
rand = { workspace = true, optional = true }
rand_core = { workspace = true, optional = true }
ripemd.workspace = true
serde.workspace = true
serde_json.workspace = true
sha2.workspace = true
smooth-operator.workspace = true
tendermint.workspace = true
tendermint-proto.workspace = true
thiserror.workspace = true
tiny-keccak.workspace = true
tracing.workspace = true
uint.workspace = true
zeroize.workspace = true
wasmtimer = { workspace = true, optional = true }


[target.'cfg(not(target_family = "wasm"))'.dependencies]
tokio = { workspace = true, optional = true, features = ["full"] }
rayon.workspace = true

[target.'cfg(target_family = "wasm")'.dependencies]
tokio = { workspace = true, optional = true, default-features = false, features = [
  "sync",
] }

[dev-dependencies]
assert_matches.workspace = true
lazy_static.workspace = true
proptest.workspace = true
rand.workspace = true
rand_core.workspace = true
tokio = { workspace = true, features = ["full"] }
toml.workspace = true

[lints.rust]
unexpected_cfgs = { level = "warn", check-cfg = ['cfg(fuzzing)'] }
