-
Notifications
You must be signed in to change notification settings - Fork 45
Expand file tree
/
Copy pathCargo.toml
More file actions
100 lines (93 loc) · 4.07 KB
/
Copy pathCargo.toml
File metadata and controls
100 lines (93 loc) · 4.07 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
[workspace]
members = ["domain_types", "domain_types_macro"]
# `as` is one token meaning three different conversions, and a reader can't tell which without
# knowing both types. Denied here, so each one has to be named instead: `From` when it is exact,
# and `SaturatingInto` / `ApproxInto` (domain_types::traits) when something is lost. The last lint
# is what makes the exact case say `From` rather than pick one of the other two.
#
# Where a cast really is the answer, `#[allow]` with the reason is fine — on the narrowest scope
# that works, never a whole function, or it will cover the next cast written on that line too.
[workspace.lints.clippy]
cast_possible_wrap = "deny" # u64 -> i64, wraps
cast_possible_truncation = "deny" # u64 -> u32, f64 -> f32
cast_sign_loss = "deny" # i64 -> u64
cast_precision_loss = "deny" # u64 -> f64, digits past 2^53
cast_lossless = "deny" # u16 -> i64, exact: use From
[package]
name = "dick-grower-bot"
version = "0.1.0"
edition = "2024"
license-file = "LICENSE"
[lints]
workspace = true
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
[dependencies]
# Telegram Bot framework and localization library
teloxide = { git = "https://github.com/kozalosev/teloxide.git", branch = "feature/request-observer", default-features = false, features = ["macros", "webhooks-axum", "rustls", "ctrlc_handler", "throttle"] }
rust-i18n = "4.2.1"
# Asynchronous runtime, web server, metrics
tokio = { version = "1.53.1", default-features = false, features = ["rt-multi-thread", "macros", "signal"] }
axum = "0.8.9"
axum-prometheus = "0.10.0"
prometheus = "0.14.0"
autometrics = { version = "3.0.0", features = ["prometheus-exporter"] }
tokio-metrics-collector = "0.3.1"
# Logging, tracing and envs
tracing = "0.1.44"
tracing-subscriber = { version = "0.3.22", features = ["env-filter", "fmt", "json"] }
tracing-opentelemetry = "0.33.0"
opentelemetry = "0.32.0"
opentelemetry_sdk = { version = "0.32.1", features = ["rt-tokio"] }
opentelemetry-otlp = { version = "0.32.0", features = ["grpc-tonic"] }
opentelemetry-appender-tracing = { version = "0.32.0", features = ["experimental_span_attributes"] }
tonic-tracing-opentelemetry = "0.38.0"
tower = "0.5.3"
dotenvy = "0.15.7"
# Database and SQL
sqlx = { version = "0.9.0", features = [ "runtime-tokio", "postgres", "chrono", "tls-rustls", "macros" ] }
redis = { version = "1.5.0", default-features = false, features = ["tokio-comp", "connection-manager", "script"] }
# gRPC client
tonic = "0.14"
tonic-prost = "0.14"
prost = "0.14"
prost-types = "0.14"
# HTTP client with caching
reqwest = { version = "0.13.4", default-features = false, features = ["rustls", "json"] }
# Serialization / deserialization
serde = { version = "1.0.229", features = ["derive"] }
serde_json = "1"
serde-saphyr = "1.0.0-rc.1"
# HTML and templates
tinytemplate = "1.2.1"
# Derive macros
strum = "0.28.0"
strum_macros = "0.28.0"
derive_more = { version = "2.1.1", features = ["display", "from", "constructor", "error", "from_str", "add", "mul", "not", "add_assign", "mul_assign"] }
anyhow = { version = "1.0.104", features = ["backtrace"] }
# Other basic stuff
regex = "1.13.1"
rand = "0.10.2"
chrono = { version = "0.4.45", features = [ "serde" ] }
base64 = "0.23.0"
byteorder = "1.5.0"
sha2 = "0.11.0"
unicode-general-category = "1.1.0"
# Rust specific stuff
once_cell = "1.21.4"
futures = "0.3.33"
itertools = "0.15.0"
derive-where = "1.6.1"
async-trait = "0.1.91"
num-traits = "0.2.19"
downcast-rs = "2.0.2"
# Local subcrates
domain_types = { version = "0.1.0", path = "domain_types" }
domain_types_macro = { version = "0.1.0", path = "domain_types_macro" }
[dev-dependencies]
testcontainers = { version = "0.27.3", features = ["reusable-containers"] }
# `test-util` for `#[tokio::test(start_paused = true)]`, which advances the clock instead of waiting
# on it. Only a test that owns every clock involved may use it — anything asserting against a
# container waits for real, since pausing ours doesn't move theirs.
tokio = { version = "1.53.1", features = ["test-util"] }
[build-dependencies]
tonic-prost-build = "0.14"