luxe 0.1.5: a provider picker, model ids, and a guided review that says less

The dock's provider row opens a list of providers, and the model picker opens on the provider in use, with tab to widen it; signing in opens it on the provider just signed in to. Models go by their id unless config names them, and the model row wears its maker's mark.

The guided review's guide prompt is shorter, the pull request brief shows the start of the description with the rest behind p, its commits drop the Luxe-review and Luxe-revision lines, and the weakened-gates signal is gone.

luxe update reruns the installer it was installed with, in place of luxe-cli-update. The preview's FILE tab reads files the session changed outside the project, and only those. Smaller fixes: bash headers are highlighted, the preview loses a blank row, the launcher divider sits inside its frame, and the phone app's top bar is clear of iOS's blur.

rustls-webpki 0.103.16 and webpki-roots 1.0.10 fix RUSTSEC-2026-0381 and RUSTSEC-2026-0382, and vite 8.3.4 fixes GHSA-587h-7wmj-h5pm, GHSA-698v-4r3x-3vcv and GHSA-r825-w8mm-5pxw.
This commit is contained in:
Evan Whittaker
2026-10-22 13:25:32 -05:00
parent 4705c2abaa
commit f3ed35beb5
123 changed files with 3788 additions and 1745 deletions

View File

@@ -0,0 +1,62 @@
//! Project reads — what the preview's FILE tab may read, as the engine answers it.
use std::sync::Arc;
use luxe_core::engine::{Action, Engine, EngineConfig};
use luxe_core::event::Event;
use luxe_core::external_work::ExternalWork;
use luxe_core::project_files::{FileReadRequestId, ProjectFileFailure};
use luxe_core::session::SessionStore;
use crate::fixtures::*;
/// A file this session changed outside the project reads back like a project file, and a file
/// beside it that the session never touched is still refused.
#[tokio::test]
async fn the_preview_reads_what_the_session_changed_outside_the_project() {
let (project, elsewhere) = (tempfile::tempdir().unwrap(), tempfile::tempdir().unwrap());
let changed = elsewhere.path().join("notes.md");
let work = ExternalWork::new();
work.observe(&changed);
std::fs::write(&changed, "# notes\n").unwrap();
std::fs::write(elsewhere.path().join("secret.md"), "hush\n").unwrap();
let (actions, mut events) = Engine::spawn(engine_with(project.path(), work));
let read = read_back(&actions, &mut events, &changed).await;
assert_eq!(read.map(|file| file.text), Ok("# notes\n".to_owned()));
let refused = read_back(&actions, &mut events, &elsewhere.path().join("secret.md")).await;
assert_eq!(refused, Err(ProjectFileFailure::OutsideProject));
let _ = actions.send(Action::Close).await;
}
/// An engine on `project` that knows the session's outside work is `work`.
fn engine_with(project: &std::path::Path, work: ExternalWork) -> EngineConfig {
let mut store = project_store(project);
let session_id = store.create(&luxe_core::paths::display(project)).unwrap();
let provider = Arc::new(RemediationProvider { reply: String::new() });
EngineConfig {
guided_review_project_root: Some(project.to_path_buf()),
external_work: Some(work),
..base_config(store, session_id, provider)
}
}
/// What the engine answers a FILE-tab read of `path` with.
async fn read_back(
actions: &tokio::sync::mpsc::Sender<Action>,
events: &mut tokio::sync::mpsc::Receiver<Event>,
path: &std::path::Path,
) -> Result<luxe_core::project_files::ProjectFile, ProjectFileFailure> {
let request_id = FileReadRequestId::new();
let path = luxe_core::paths::display(path);
let asked = Action::ReadProjectFile { request_id: request_id.clone(), path };
actions.send(asked).await.unwrap();
first(events, "the file read", |event| match event {
Event::ProjectFileRead { request_id: id, file } if id == request_id => Some(Ok(*file)),
Event::ProjectFileReadFailed { request_id: id, error, .. } if id == request_id => {
Some(Err(error))
}
_ => None,
})
.await
}