mirror of
https://github.com/zyycn/codex-proxy-rs.git
synced 2026-11-06 08:06:19 +00:00
@@ -17,7 +17,7 @@ use crate::{
|
||||
|
||||
use super::{
|
||||
coordinator::SchedulerHandle,
|
||||
periodic::{PeriodicTaskConfig, PeriodicTaskRunner, spawn_periodic_task},
|
||||
periodic::{spawn_periodic_task, PeriodicTaskConfig, PeriodicTaskRunner},
|
||||
};
|
||||
|
||||
/// 主动配额刷新后台任务。
|
||||
|
||||
@@ -4,7 +4,7 @@ use std::{collections::HashMap, sync::Arc, time::Duration};
|
||||
|
||||
use chrono::Utc;
|
||||
use thiserror::Error;
|
||||
use tokio::time::{Instant, sleep};
|
||||
use tokio::time::{sleep, Instant};
|
||||
use tracing::warn;
|
||||
|
||||
use crate::upstream::accounts::{
|
||||
|
||||
@@ -5,16 +5,16 @@ use codex_proxy_rs::infra::database::connect_sqlite;
|
||||
use codex_proxy_rs::upstream::accounts::cookies::SqliteCookieStore;
|
||||
use codex_proxy_rs::upstream::accounts::model::AccountStatus;
|
||||
use codex_proxy_rs::upstream::accounts::quota::{
|
||||
RuntimeQuotaRefreshService, quota_from_usage, quota_snapshot_limit_reached,
|
||||
quota_snapshot_limit_window_seconds, quota_snapshot_reset_at,
|
||||
quota_from_usage, quota_snapshot_limit_reached, quota_snapshot_limit_window_seconds,
|
||||
quota_snapshot_reset_at, RuntimeQuotaRefreshService,
|
||||
};
|
||||
use codex_proxy_rs::upstream::accounts::store::{NewAccount, SqliteAccountStore};
|
||||
use codex_proxy_rs::upstream::transport::CodexBackendClient;
|
||||
use secrecy::SecretString;
|
||||
use serde_json::{Value, json};
|
||||
use serde_json::{json, Value};
|
||||
use wiremock::{
|
||||
Mock, MockServer, ResponseTemplate,
|
||||
matchers::{method, path},
|
||||
Mock, MockServer, ResponseTemplate,
|
||||
};
|
||||
|
||||
#[test]
|
||||
|
||||
Reference in New Issue
Block a user