Skip to content

Commit 314acf1

Browse files
committed
v3.0.12
update deps
1 parent d88808a commit 314acf1

39 files changed

Lines changed: 2977 additions & 2700 deletions

.github/workflows/ci.yml

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -272,39 +272,39 @@ jobs:
272272
- host: ubuntu-22.04
273273
docker: ghcr.io/napi-rs/napi-rs/nodejs-rust:lts-alpine
274274
build: |
275-
rustup install 1.85.0
276-
rustup default 1.85.0
275+
rustup install 1.89.0
276+
rustup default 1.89.0
277277
yarn build:debug
278278
strip -x *.node
279279
280280
- host: ubuntu-22.04
281281
docker: ghcr.io/napi-rs/napi-rs/nodejs-rust:lts-debian-aarch64
282282
build: |
283-
rustup install 1.85.0
284-
rustup default 1.85.0
283+
rustup install 1.89.0
284+
rustup default 1.89.0
285285
rustup target add aarch64-unknown-linux-gnu
286286
yarn build:debug --target aarch64-unknown-linux-gnu
287287
aarch64-unknown-linux-gnu-strip *.node
288288
289289
- host: macos-13
290290
architecture: x64
291291
build: |
292-
rustup install 1.85.0
293-
rustup default 1.85.0
292+
rustup install 1.89.0
293+
rustup default 1.89.0
294294
yarn build:debug
295295
strip -x *.node
296296
297297
- host: windows-latest
298298
build: |
299-
rustup install 1.85.0
300-
rustup default 1.85.0
299+
rustup install 1.89.0
300+
rustup default 1.89.0
301301
yarn build:debug
302302
architecture: x64
303303

304304
- host: ubuntu-22.04
305305
build: |
306-
rustup install 1.85.0
307-
rustup default 1.85.0
306+
rustup install 1.89.0
307+
rustup default 1.89.0
308308
yarn build:debug
309309
strip *.node
310310
@@ -316,8 +316,8 @@ jobs:
316316
export CXX=$(xcrun -f clang++);
317317
SYSROOT=$(xcrun --sdk macosx --show-sdk-path);
318318
export CFLAGS="-isysroot $SYSROOT -isystem $SYSROOT";
319-
rustup install 1.85.0
320-
rustup default 1.85.0
319+
rustup install 1.89.0
320+
rustup default 1.89.0
321321
rustup target add aarch64-apple-darwin
322322
yarn build:debug --target aarch64-apple-darwin
323323
strip -x *.node

.github/workflows/release.yml

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -182,17 +182,17 @@ jobs:
182182
- host: ubuntu-22.04
183183
docker: ghcr.io/napi-rs/napi-rs/nodejs-rust:lts-alpine
184184
build: |
185-
rustup install 1.85.0
186-
rustup default 1.85.0
185+
rustup install 1.89.0
186+
rustup default 1.89.0
187187
yarn build
188188
strip -x *.node
189189
artifact-name: linux-x64-musl
190190

191191
- host: ubuntu-22.04
192192
docker: ghcr.io/napi-rs/napi-rs/nodejs-rust:lts-debian-aarch64
193193
build: |
194-
rustup install 1.85.0
195-
rustup default 1.85.0
194+
rustup install 1.89.0
195+
rustup default 1.89.0
196196
rustup target add aarch64-unknown-linux-gnu
197197
yarn build --target aarch64-unknown-linux-gnu
198198
aarch64-unknown-linux-gnu-strip *.node
@@ -209,24 +209,24 @@ jobs:
209209
- host: macos-13
210210
architecture: x64
211211
build: |
212-
rustup install 1.85.0
213-
rustup default 1.85.0
212+
rustup install 1.89.0
213+
rustup default 1.89.0
214214
yarn build
215215
strip -x *.node
216216
artifact-name: macos
217217

218218
- host: windows-latest
219219
build: |
220-
rustup install 1.85.0
221-
rustup default 1.85.0
220+
rustup install 1.89.0
221+
rustup default 1.89.0
222222
yarn build
223223
architecture: x64
224224
artifact-name: windows
225225

226226
- host: ubuntu-22.04
227227
build: |
228-
rustup install 1.85.0
229-
rustup default 1.85.0
228+
rustup install 1.89.0
229+
rustup default 1.89.0
230230
yarn build
231231
strip *.node
232232
artifact-name: linux-x64
@@ -239,8 +239,8 @@ jobs:
239239
export CXX=$(xcrun -f clang++);
240240
SYSROOT=$(xcrun --sdk macosx --show-sdk-path);
241241
export CFLAGS="-isysroot $SYSROOT -isystem $SYSROOT";
242-
rustup install 1.85.0
243-
rustup default 1.85.0
242+
rustup install 1.89.0
243+
rustup default 1.89.0
244244
rustup target add aarch64-apple-darwin
245245
yarn build --target aarch64-apple-darwin
246246
strip -x *.node

Cargo.toml

Lines changed: 66 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,72 @@
11
[workspace]
2-
package.edition = "2024"
32
resolver = "3"
43
members = ["rust", "python", "nodejs", "java", "c", "mcp"]
54

5+
[workspace.package]
6+
version = "3.0.12"
7+
edition = "2024"
8+
69
[profile.release]
710
lto = true
11+
12+
[workspace.dependencies]
13+
longport-wscli = { path = "rust/crates/wsclient", version = "3.0.12" }
14+
longport-httpcli = { path = "rust/crates/httpclient", version = "3.0.12" }
15+
longport-proto = { path = "rust/crates/proto", version = "3.0.12" }
16+
longport-candlesticks = { path = "rust/crates/candlesticks", version = "3.0.12" }
17+
longport = { path = "rust", version = "3.0.12" }
18+
19+
tokio = "1.47.1"
20+
tokio-tungstenite = "0.27.0"
21+
rust_decimal = "1.37.2"
22+
num_enum = "0.7.4"
23+
prost = "0.14.1"
24+
tracing = "0.1.41"
25+
bitflags = "2.9.2"
26+
futures-util = "0.3.31"
27+
time = "0.3.41"
28+
flume = "0.11.1"
29+
thiserror = "2.0.15"
30+
strum = "0.27.2"
31+
strum_macros = "0.27.2"
32+
serde = "1.0.219"
33+
serde_json = "1.0.142"
34+
dotenv = "0.15.0"
35+
http = "1.3.1"
36+
comfy-table = "7.1.4"
37+
itertools = "0.14.0"
38+
tracing-subscriber = "0.3.19"
39+
tracing-appender = "0.2.3"
40+
time-tz = "2.0.0"
41+
num-traits = "0.2.19"
42+
reqwest = { version = "0.12.23", default-features = false }
43+
parking_lot = "0.12.4"
44+
hmac = "0.12.1"
45+
sha1 = "0.10.6"
46+
sha2 = "0.10.9"
47+
percent-encoding = "2.3.1"
48+
byteorder = "1.5.0"
49+
url = "2.5.4"
50+
flate2 = "1.1.2"
51+
leaky-bucket = "1.1.2"
52+
pyo3 = "0.25.1"
53+
pythonize = "0.25.0"
54+
pyo3-build-config = "0.25.1"
55+
napi = { version = "3.2.4", default-features = false }
56+
napi-derive = "3.2.4"
57+
napi-build = "2.2.3"
58+
chrono = "0.4.41"
59+
poem-mcpserver = "0.2.5"
60+
poem-mcpserver-macros = "0.2.5"
61+
poem = "3.1.12"
62+
schemars = "1.0.4"
63+
clap = "4.5.45"
64+
dotenvy = "0.15.7"
65+
jni = "0.21.1"
66+
proc-macro2 = "1.0.101"
67+
quote = "1.0.40"
68+
syn = "2.0.106"
69+
darling = "0.21.2"
70+
convert_case = "0.8.0"
71+
Inflector = "0.11.4"
72+
cbindgen = "0.29.0"

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ LongPort OpenAPI provides programmatic quote trading interfaces for investors wi
1414

1515
| Name | Document | Description |
1616
|-----------------------------|-----------------------------------------------------------------------|---------------------------------------------------|
17-
| [Rust](rust/README.md) | [Doc](https://longportapp.github.io/openapi/rust/longport/index.html) | LongPort OpenAPI for Rust `(>= 1.56.1)` |
17+
| [Rust](rust/README.md) | [Doc](https://longportapp.github.io/openapi/rust/longport/index.html) | LongPort OpenAPI for Rust `(>= 1.89.0)` |
1818
| [Python](python/README.md) | [Doc](https://longportapp.github.io/openapi/python/index.html) | LongPort OpenAPI for Python 3 `(>= 3.7)` |
1919
| [Node.js](nodejs/README.md) | [Doc](https://longportapp.github.io/openapi/nodejs/index.html) | LongPort OpenAPI for Node.js `(>= 10)` |
2020
| [Java](java/README.md) | [Doc](https://longportapp.github.io/openapi/java/index.html) | LongPort OpenAPI for Java `(>= 1.8)` |

SECURITY.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44

55
| Version | Supported |
66
|----------|--------------------|
7-
| >= 0.2.0 | :white_check_mark: |
7+
| >= 3.0.0 | :white_check_mark: |
88

99
## Reporting a Vulnerability
1010

c/Cargo.toml

Lines changed: 8 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
[package]
22
edition.workspace = true
33
name = "longport-c"
4-
version = "3.0.11"
4+
version.workspace = true
55
description = "LongPort OpenAPI SDK for C"
66
homepage = "https://open.longportapp.com/en/"
77
readme = "README.md"
@@ -14,15 +14,14 @@ categories = ["api-bindings"]
1414
crate-type = ["cdylib"]
1515

1616
[dependencies]
17-
longport = { path = "../rust" }
17+
longport.workspace = true
1818
longport-c-macros = { path = "crates/macros" }
1919

20-
rust_decimal = { version = "1.23.1", features = ["maths"] }
21-
tokio = { version = "1.19.2", features = ["rt-multi-thread"] }
22-
once_cell = "1.12.0"
23-
parking_lot = "0.12.1"
24-
time = "0.3.9"
25-
tracing = "0.1.34"
20+
rust_decimal = { workspace = true, features = ["maths"] }
21+
tokio = { workspace = true, features = ["rt-multi-thread"] }
22+
parking_lot.workspace = true
23+
time.workspace = true
24+
tracing.workspace = true
2625

2726
[build-dependencies]
28-
cbindgen = "0.28.0"
27+
cbindgen.workspace = true

c/crates/macros/Cargo.toml

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
11
[package]
22
name = "longport-c-macros"
3-
version = "3.0.11"
3+
version.workspace = true
44
edition.workspace = true
55

66
[lib]
77
proc-macro = true
88

99
[dependencies]
10-
darling = "0.20.10"
11-
proc-macro2 = "1.0.29"
12-
quote = "1.0.9"
13-
syn = { version = "2.0.77", features = [] }
14-
thiserror = "1.0.29"
10+
darling.workspace = true
11+
proc-macro2.workspace = true
12+
quote.workspace = true
13+
syn = { workspace = true, features = [] }
14+
thiserror.workspace = true

c/src/async_call.rs

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,15 @@
1-
use std::{ffi::c_void, future::Future, sync::Arc};
1+
use std::{
2+
ffi::c_void,
3+
future::Future,
4+
sync::{Arc, LazyLock},
5+
};
26

37
use longport::Result;
4-
use once_cell::sync::Lazy;
58
use tokio::runtime::Runtime;
69

710
use crate::error::CError;
811

9-
static RUNTIME: Lazy<Runtime> = Lazy::new(|| {
12+
static RUNTIME: LazyLock<Runtime> = LazyLock::new(|| {
1013
tokio::runtime::Builder::new_multi_thread()
1114
.enable_all()
1215
.build()

c/src/quote_context/context.rs

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
use std::{
22
ffi::{CString, c_void},
33
os::raw::c_char,
4-
sync::Arc,
4+
sync::{Arc, OnceLock},
55
time::Instant,
66
};
77

@@ -12,7 +12,6 @@ use longport::{
1212
SubFlags,
1313
},
1414
};
15-
use once_cell::sync::OnceCell;
1615
use parking_lot::Mutex;
1716

1817
use crate::{
@@ -73,7 +72,7 @@ unsafe impl Send for CQuoteContextState {}
7372
/// Quote context
7473
pub struct CQuoteContext {
7574
ctx: QuoteContext,
76-
quote_level: OnceCell<CString>,
75+
quote_level: OnceLock<CString>,
7776
state: Mutex<CQuoteContextState>,
7877
}
7978

@@ -108,7 +107,7 @@ pub unsafe extern "C" fn lb_quote_context_new(
108107
});
109108
let arc_ctx = Arc::new(CQuoteContext {
110109
ctx,
111-
quote_level: OnceCell::new(),
110+
quote_level: OnceLock::new(),
112111
state,
113112
});
114113
let weak_ctx = Arc::downgrade(&arc_ctx);

java/Cargo.toml

Lines changed: 9 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,19 @@
11
[package]
22
edition.workspace = true
33
name = "longport-java"
4-
version = "3.0.11"
4+
version.workspace = true
55

66
[lib]
77
crate-type = ["cdylib"]
88

99
[dependencies]
10-
longport = { path = "../rust" }
10+
longport.workspace = true
1111
longport-java-macros = { path = "./crates/macros" }
1212

13-
jni = "0.21.0"
14-
thiserror = "1.0.31"
15-
tokio = { version = "1.19.2", features = ["rt-multi-thread"] }
16-
once_cell = "1.12.0"
17-
time = "0.3.9"
18-
parking_lot = "0.12.1"
19-
serde_json = "1.0.93"
20-
serde = { version = "1.0.152", features = ["derive"] }
13+
jni.workspace = true
14+
thiserror.workspace = true
15+
tokio = { workspace = true, features = ["rt-multi-thread"] }
16+
time.workspace = true
17+
parking_lot.workspace = true
18+
serde_json.workspace = true
19+
serde = { workspace = true, features = ["derive"] }

0 commit comments

Comments
 (0)