-
Notifications
You must be signed in to change notification settings - Fork 44
Expand file tree
/
Copy pathCargo.toml
More file actions
216 lines (193 loc) · 5.15 KB
/
Copy pathCargo.toml
File metadata and controls
216 lines (193 loc) · 5.15 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
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
[package]
name = "rs_poker"
version = "5.0.0"
authors = ["Elliott Clark <eclark@apache.org>"]
keywords = ["cards", "poker"]
categories = ["games"]
homepage = "https://docs.rs/rs_poker"
repository = "https://github.com/elliottneilclark/rs-poker"
description = "A library to help with any Rust code dealing with poker. This includes card values, suits, hands, hand ranks, 5 card hand strength calculation, 7 card hand strength calulcation, and monte carlo game simulation helpers."
readme = "README.md"
license = "Apache-2.0"
edition = "2024"
build = "build.rs"
# Dev-only files that have no business in the published crate. `.cargo/` build
# config only applies to in-tree builds (cargo invocation dir, not the package),
# so consumers ignore it anyway; the rest is tooling, CI, agent notes, and
# generated demo artifacts. docs/arena_tui.png is kept — the README embeds it.
exclude = [
".cargo/",
".github/",
"CLAUDE.md",
"mise.toml",
"mise.lock",
"examples/exports/",
]
[dependencies]
rand = { version = "~0.10.1" }
thiserror = "~2.0.12"
serde = { version = "1.0.219", optional = true, features = ["derive"] }
serde_json = { version = "~1.0.140", optional = true }
arbitrary = { version = "~1.4.1", optional = true, features = ["derive"] }
tracing = { version = "~0.1.41", optional = true }
approx = { version = "~0.5.1", optional = true }
little-sorry = { version = "~3.0.0", optional = true, features = [] }
chrono = { version = "~0.4.41", optional = true, features = ["serde"] }
itertools = { version = "~0.14.0", optional = true }
parking_lot = { version = "~0.12", optional = true }
smallvec = { version = "~1.15", optional = true, features = [
"const_generics",
"union",
] }
clap = { version = "~4.6", features = ["derive"], optional = true }
tracing-subscriber = { version = "~0.3.20", optional = true, default-features = true, features = [
"env-filter",
"fmt",
"json",
] }
ratatui = { version = "~0.30", optional = true, default-features = false, features = [
"crossterm",
] }
crossterm = { version = "~0.28", optional = true, features = ["event-stream"] }
tachyonfx = { version = "~0.25", optional = true, features = ["std-duration"] }
tempfile = { version = "~3.27.0", optional = true }
tokio = { version = "~1.43", optional = true, features = [
"rt",
"rt-multi-thread",
"macros",
"parking_lot",
"sync",
"time",
"fs",
"io-util",
] }
async-trait = { version = "~0.1", optional = true }
tokio-util = { version = "~0.7", optional = true }
[dev-dependencies]
criterion = "~0.8.0"
env_logger = { version = "~0.11.8" }
approx = { version = "~0.5.1" }
tracing-subscriber = { version = "~0.3.20", default-features = false, features = [
"registry",
"std",
] }
tempfile = "~3.27.0"
insta = "~1.41"
tokio = { version = "~1.43", features = [
"rt",
"rt-multi-thread",
"macros",
"parking_lot",
"sync",
"time",
"fs",
"io-util",
"test-util",
] }
tokio-test = "~0.4"
[target.'cfg(not(target_env = "msvc"))'.dev-dependencies]
# Benches set jemalloc as the global allocator to match the production `rsp`
# binary (which uses it via the `rsp` feature). Measuring CFR throughput under
# the system allocator would overstate allocation cost relative to production.
tikv-jemallocator = { version = "~0.6.0", features = [
"unprefixed_malloc_on_supported_platforms",
] }
[target.'cfg(not(target_env = "msvc"))'.dependencies]
tikv-jemallocator = { version = "~0.6.0", optional = true, features = [
"profiling",
"unprefixed_malloc_on_supported_platforms",
] }
[features]
default = ["arena", "serde", "omaha", "open-hand-history"]
omaha = []
serde = ["dep:serde", "dep:serde_json"]
arena = [
"dep:tracing",
"dep:little-sorry",
"dep:itertools",
"dep:approx",
"dep:parking_lot",
"dep:smallvec",
"dep:tokio",
"dep:async-trait",
"dep:tokio-util",
]
rsp = [
"arena",
"serde",
"omaha",
"open-hand-history",
"dep:clap",
"dep:tracing-subscriber",
"dep:tikv-jemallocator",
"dep:ratatui",
"dep:crossterm",
"dep:tachyonfx",
"dep:tempfile",
]
arena-test-util = ["arena", "dep:approx"]
open-hand-history = ["serde", "dep:chrono", "dep:approx"]
open-hand-history-test-util = ["open-hand-history"]
[[bin]]
name = "rsp"
path = "src/bin/rsp/main.rs"
required-features = ["rsp"]
[[bench]]
name = "arena"
harness = false
required-features = ["arena"]
[[bench]]
name = "monte_carlo_game"
harness = false
[[bench]]
name = "holdem_starting_hand"
harness = false
[[bench]]
name = "iter"
harness = false
[[bench]]
name = "parse"
harness = false
[[bench]]
name = "rank"
harness = false
[[bench]]
name = "icm_sim"
harness = false
[[bench]]
name = "deal_deck"
harness = false
[[bench]]
name = "cfr"
harness = false
required-features = ["arena"]
[[bench]]
name = "cfr_throughput"
harness = false
required-features = ["arena"]
[[bench]]
name = "node_arena"
harness = false
required-features = ["arena"]
[[bench]]
name = "sample_one"
harness = false
[[bench]]
name = "action_picker"
harness = false
required-features = ["arena"]
[[bench]]
name = "omaha"
harness = false
required-features = ["omaha"]
[[bench]]
name = "player_bit_set_init"
harness = false
[[bench]]
name = "hand_eval"
harness = false
[profile.release]
debug = "line-tables-only"
lto = true
codegen-units = 1
panic = "abort"