Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
04d809962c | ||
|
|
158549f7e4 | ||
|
|
66062a6427 |
No files matched your search
Generated
+1
-1
@@ -3856,7 +3856,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "rmcl"
|
||||
version = "0.6.3"
|
||||
version = "0.6.4"
|
||||
dependencies = [
|
||||
"async-trait",
|
||||
"base64",
|
||||
|
||||
+1
-1
@@ -1,6 +1,6 @@
|
||||
[package]
|
||||
name = "rmcl"
|
||||
version = "0.6.3"
|
||||
version = "0.6.4"
|
||||
authors = ["objz"]
|
||||
edition = "2024"
|
||||
description = "A fully featured Minecraft TUI launcher"
|
||||
|
||||
@@ -2,6 +2,8 @@
|
||||
|
||||
# rmcl
|
||||
|
||||
> **Development notice:** This project is not abandoned. I am taking a short break and expect to resume active development within a month at the latest. In the meantime, I will continue to review and merge pull requests and other contributions.
|
||||
|
||||
[![Contributors][contributors-shield]][contributors-url]
|
||||
[![Forks][forks-shield]][forks-url]
|
||||
[![Stargazers][stars-shield]][stars-url]
|
||||
|
||||
@@ -632,7 +632,7 @@ impl InstanceManager {
|
||||
|
||||
let config_path = self.instances_dir.join(name).join("instance.json");
|
||||
if !config_path.exists() {
|
||||
tracing::warn!(
|
||||
tracing::debug!(
|
||||
"Instance '{}' config is missing at {}",
|
||||
name,
|
||||
config_path.display()
|
||||
|
||||
+2
-2
@@ -522,8 +522,8 @@ pub async fn download_assets_from(
|
||||
serde_json::from_slice(&bytes).ok()
|
||||
}
|
||||
Ok(_) => {
|
||||
tracing::warn!(
|
||||
"Invalid cached asset index at {}; fetching again",
|
||||
tracing::debug!(
|
||||
"Cached asset index at {} does not match the requested version; fetching again",
|
||||
index_path.display()
|
||||
);
|
||||
None
|
||||
|
||||
+5
-2
@@ -411,8 +411,11 @@ async fn download_assets_writes_index_when_objects_is_empty() {
|
||||
assert!(body.get("objects").is_some());
|
||||
}
|
||||
|
||||
#[rstest::rstest]
|
||||
#[case(b"{\"objects\":{\"fake\":{}}}")]
|
||||
#[case(b"{\"objects\":{},\"virtual\":false}")]
|
||||
#[tokio::test]
|
||||
async fn invalid_cached_index_is_refetched() {
|
||||
async fn mismatched_cached_index_is_refetched(#[case] cached: &[u8]) {
|
||||
let server = MockServer::start().await;
|
||||
let body = serde_json::to_vec(&json!({"objects": {}})).unwrap();
|
||||
Mock::given(method("GET"))
|
||||
@@ -426,7 +429,7 @@ async fn invalid_cached_index_is_refetched() {
|
||||
let tmp = tempfile::tempdir().unwrap();
|
||||
let index_path = tmp.path().join("cache/minecraft/assets/indexes/5.json");
|
||||
std::fs::create_dir_all(index_path.parent().unwrap()).unwrap();
|
||||
std::fs::write(&index_path, b"{\"objects\":{\"fake\":{}}}").unwrap();
|
||||
std::fs::write(&index_path, cached).unwrap();
|
||||
|
||||
download_assets(&HttpClient::new(), &meta, tmp.path())
|
||||
.await
|
||||
|
||||
Reference in new issue
Block a user