repo
stringlengths
6
65
file_url
stringlengths
81
311
file_path
stringlengths
6
227
content
stringlengths
0
32.8k
language
stringclasses
1 value
license
stringclasses
7 values
commit_sha
stringlengths
40
40
retrieved_at
stringdate
2026-01-04 15:31:58
2026-01-04 20:25:31
truncated
bool
2 classes
nikivdev/flow
https://github.com/nikivdev/flow/blob/85db313c274056cf0dbb36cc0aee35e037a66cfd/src/main.rs
src/main.rs
use std::net::IpAddr; use std::path::Path; use anyhow::{Result, bail}; use clap::{Parser, error::ErrorKind}; use flowd::{ agents, ai, cli::{Cli, Commands, RerunOpts, TaskRunOpts, TasksOpts}, commit, commits, daemon, deploy, docs, doctor, env, fixup, history, hub, init, init_tracing, log_server, notify,...
rust
MIT
85db313c274056cf0dbb36cc0aee35e037a66cfd
2026-01-04T15:40:10.857433Z
false
nikivdev/flow
https://github.com/nikivdev/flow/blob/85db313c274056cf0dbb36cc0aee35e037a66cfd/src/daemon.rs
src/daemon.rs
//! Generic daemon management for flow. //! //! Allows starting, stopping, and monitoring background daemons defined in flow.toml. use std::{ fs, path::{Path, PathBuf}, process::Command, time::Duration, }; use anyhow::{Context, Result, bail}; use reqwest::blocking::Client; use crate::{ cli::{Daem...
rust
MIT
85db313c274056cf0dbb36cc0aee35e037a66cfd
2026-01-04T15:40:10.857433Z
false
nikivdev/flow
https://github.com/nikivdev/flow/blob/85db313c274056cf0dbb36cc0aee35e037a66cfd/src/ai.rs
src/ai.rs
//! AI session management for Claude Code and Codex integration. //! //! Tracks and manages AI coding sessions per project, allowing users to: //! - List sessions for the current project (Claude, Codex, or both) //! - Save/bookmark sessions with names //! - Resume sessions //! - Add notes to sessions //! - Copy session...
rust
MIT
85db313c274056cf0dbb36cc0aee35e037a66cfd
2026-01-04T15:40:10.857433Z
true
nikivdev/flow
https://github.com/nikivdev/flow/blob/85db313c274056cf0dbb36cc0aee35e037a66cfd/src/running.rs
src/running.rs
use std::{ collections::HashMap, fs, path::{Path, PathBuf}, process::Command, time::{SystemTime, UNIX_EPOCH}, }; use anyhow::{Context, Result}; use serde::{Deserialize, Serialize}; /// A process started by flow #[derive(Debug, Clone, Serialize, Deserialize)] pub struct RunningProcess { /// Pro...
rust
MIT
85db313c274056cf0dbb36cc0aee35e037a66cfd
2026-01-04T15:40:10.857433Z
false
nikivdev/flow
https://github.com/nikivdev/flow/blob/85db313c274056cf0dbb36cc0aee35e037a66cfd/src/release.rs
src/release.rs
use anyhow::{bail, Result}; use crate::{ cli::ReleaseOpts, tasks::{self, find_task}, }; fn available_tasks(cfg: &crate::config::Config) -> String { let mut names: Vec<_> = cfg.tasks.iter().map(|task| task.name.clone()).collect(); names.sort(); names.join(", ") } fn resolve_release_task(cfg: &crat...
rust
MIT
85db313c274056cf0dbb36cc0aee35e037a66cfd
2026-01-04T15:40:10.857433Z
false
nikivdev/flow
https://github.com/nikivdev/flow/blob/85db313c274056cf0dbb36cc0aee35e037a66cfd/src/logs.rs
src/logs.rs
use std::{ io::{BufRead, BufReader}, thread, time::Duration, }; use anyhow::{Context, Result, bail}; use reqwest::blocking::Client; use crate::{ cli::LogsOpts, servers::{LogLine, LogStream, ServerSnapshot}, }; pub fn run(opts: LogsOpts) -> Result<()> { if opts.follow && opts.server.is_none() ...
rust
MIT
85db313c274056cf0dbb36cc0aee35e037a66cfd
2026-01-04T15:40:10.857433Z
false
nikivdev/flow
https://github.com/nikivdev/flow/blob/85db313c274056cf0dbb36cc0aee35e037a66cfd/src/tools.rs
src/tools.rs
//! AI tools management - execute TypeScript tools via localcode/bun. //! //! Tools are stored in .ai/tools/<name>.ts use std::fs; use std::path::PathBuf; use std::process::Command; use anyhow::{Context, Result, bail}; use crate::cli::{ToolsAction, ToolsCommand}; /// Run the tools subcommand. pub fn run(cmd: ToolsC...
rust
MIT
85db313c274056cf0dbb36cc0aee35e037a66cfd
2026-01-04T15:40:10.857433Z
false
nikivdev/flow
https://github.com/nikivdev/flow/blob/85db313c274056cf0dbb36cc0aee35e037a66cfd/src/docs.rs
src/docs.rs
//! Auto-generated documentation management. //! //! Maintains documentation in `.ai/docs/` that stays in sync with the codebase. use std::fs; use std::path::Path; use std::process::Command; use anyhow::{Context, Result, bail}; use crate::cli::{DocsCommand, DocsAction}; /// Docs directory relative to project root. ...
rust
MIT
85db313c274056cf0dbb36cc0aee35e037a66cfd
2026-01-04T15:40:10.857433Z
false
nikivdev/flow
https://github.com/nikivdev/flow/blob/85db313c274056cf0dbb36cc0aee35e037a66cfd/src/lin_runtime.rs
src/lin_runtime.rs
use std::{ fs, path::{Path, PathBuf}, process::Command, }; use anyhow::{Context, Result}; use serde::{Deserialize, Serialize}; /// Location and metadata for the lin binary that flow should launch. #[derive(Debug, Clone, Serialize, Deserialize)] pub struct LinRuntime { pub binary: PathBuf, pub vers...
rust
MIT
85db313c274056cf0dbb36cc0aee35e037a66cfd
2026-01-04T15:40:10.857433Z
false
nikivdev/flow
https://github.com/nikivdev/flow/blob/85db313c274056cf0dbb36cc0aee35e037a66cfd/src/skills.rs
src/skills.rs
//! Codex skills management. //! //! Skills are stored in .ai/skills/<name>/skill.md use std::fs; use std::path::PathBuf; use std::process::Command; use anyhow::{Context, Result, bail}; use crate::cli::{SkillsAction, SkillsCommand}; use crate::config; /// Run the skills subcommand. pub fn run(cmd: SkillsCommand) ->...
rust
MIT
85db313c274056cf0dbb36cc0aee35e037a66cfd
2026-01-04T15:40:10.857433Z
false
nikivdev/flow
https://github.com/nikivdev/flow/blob/85db313c274056cf0dbb36cc0aee35e037a66cfd/src/indexer.rs
src/indexer.rs
use std::{ env, fs, path::{Path, PathBuf}, process::Command, time::{SystemTime, UNIX_EPOCH}, }; use anyhow::{Context, Result, bail}; use rusqlite::Connection; use crate::cli::IndexOpts; pub fn run(opts: IndexOpts) -> Result<()> { let codanna_path = which::which(&opts.binary).with_context(|| { ...
rust
MIT
85db313c274056cf0dbb36cc0aee35e037a66cfd
2026-01-04T15:40:10.857433Z
false
nikivdev/flow
https://github.com/nikivdev/flow/blob/85db313c274056cf0dbb36cc0aee35e037a66cfd/src/start.rs
src/start.rs
//! Project bootstrap and initialization. //! //! Creates `.ai/` folder structure with public (tracked) and internal (gitignored) sections. //! //! Structure: //! .ai/ //! ├── actions/ # TRACKED - fixer/action scripts //! ├── skills/ # TRACKED - shared skills //! ├── tools/ # TRACKED - s...
rust
MIT
85db313c274056cf0dbb36cc0aee35e037a66cfd
2026-01-04T15:40:10.857433Z
false
nikivdev/flow
https://github.com/nikivdev/flow/blob/85db313c274056cf0dbb36cc0aee35e037a66cfd/src/servers_tui.rs
src/servers_tui.rs
use std::{ io, time::{Duration, Instant}, }; use anyhow::{Context, Result}; use crossterm::{ event::{self, Event as CEvent, KeyCode, KeyEvent}, execute, terminal::{EnterAlternateScreen, LeaveAlternateScreen, disable_raw_mode, enable_raw_mode}, }; use ratatui::{ Terminal, backend::CrosstermB...
rust
MIT
85db313c274056cf0dbb36cc0aee35e037a66cfd
2026-01-04T15:40:10.857433Z
false
nikivdev/flow
https://github.com/nikivdev/flow/blob/85db313c274056cf0dbb36cc0aee35e037a66cfd/src/screen.rs
src/screen.rs
use anyhow::{Context, Result}; use serde::Serialize; use std::{ fmt, sync::Arc, time::{Duration, SystemTime, UNIX_EPOCH}, }; use tokio::{ sync::{RwLock, broadcast}, time, }; use crate::cli::ScreenOpts; #[derive(Clone)] pub struct ScreenBroadcaster { sender: broadcast::Sender<ScreenFrame>, ...
rust
MIT
85db313c274056cf0dbb36cc0aee35e037a66cfd
2026-01-04T15:40:10.857433Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/test/packages/deptry_reproducer/src/lib.rs
test/packages/deptry_reproducer/src/lib.rs
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-dev/src/generate_sysconfig_mappings.rs
crates/uv-dev/src/generate_sysconfig_mappings.rs
//! Generate sysconfig mappings for supported python-build-standalone *nix platforms. use anstream::println; use anyhow::{Result, bail}; use pretty_assertions::StrComparison; use serde::Deserialize; use std::collections::BTreeMap; use std::fmt::Write; use std::path::PathBuf; use crate::ROOT_DIR; use crate::generate_al...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-dev/src/generate_options_reference.rs
crates/uv-dev/src/generate_options_reference.rs
//! Generate a Markdown-compatible listing of configuration options for `pyproject.toml`. //! //! Based on: <https://github.com/astral-sh/ruff/blob/dc8db1afb08704ad6a788c497068b01edf8b460d/crates/ruff_dev/src/generate_options.rs> use std::fmt::Write; use std::path::PathBuf; use anstream::println; use anyhow::{Result, ...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-dev/src/clear_compile.rs
crates/uv-dev/src/clear_compile.rs
use std::path::PathBuf; use clap::Parser; use tracing::info; use walkdir::WalkDir; #[derive(Parser)] pub(crate) struct ClearCompileArgs { /// Compile all `.py` in this or any subdirectory to bytecode root: PathBuf, } pub(crate) fn clear_compile(args: &ClearCompileArgs) -> anyhow::Result<()> { let mut rem...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-dev/src/lib.rs
crates/uv-dev/src/lib.rs
use std::env; use anyhow::Result; use clap::Parser; use tracing::instrument; use uv_settings::EnvironmentOptions; use crate::clear_compile::ClearCompileArgs; use crate::compile::CompileArgs; use crate::generate_all::Args as GenerateAllArgs; use crate::generate_cli_reference::Args as GenerateCliReferenceArgs; use cra...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-dev/src/generate_all.rs
crates/uv-dev/src/generate_all.rs
//! Run all code and documentation generation steps. use anyhow::Result; use crate::{ generate_cli_reference, generate_env_vars_reference, generate_json_schema, generate_options_reference, generate_sysconfig_mappings, }; #[derive(clap::Args)] pub(crate) struct Args { #[arg(long, default_value_t, value_en...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-dev/src/compile.rs
crates/uv-dev/src/compile.rs
use std::path::PathBuf; use clap::Parser; use tracing::info; use uv_cache::{Cache, CacheArgs}; use uv_configuration::Concurrency; use uv_preview::Preview; use uv_python::{EnvironmentPreference, PythonEnvironment, PythonPreference, PythonRequest}; #[derive(Parser)] pub(crate) struct CompileArgs { /// Compile all ...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-dev/src/list_packages.rs
crates/uv-dev/src/list_packages.rs
use anstream::println; use anyhow::Result; use clap::Parser; use uv_cache::{Cache, CacheArgs}; use uv_client::{BaseClientBuilder, RegistryClientBuilder}; use uv_distribution_types::IndexUrl; use uv_settings::EnvironmentOptions; #[derive(Parser)] pub(crate) struct ListPackagesArgs { /// The Simple API index URL (e...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-dev/src/render_benchmarks.rs
crates/uv-dev/src/render_benchmarks.rs
#![cfg(feature = "render")] use std::path::{Path, PathBuf}; use anyhow::{Result, anyhow}; use clap::Parser; use poloto::build; use resvg::usvg_text_layout::{TreeTextToPath, fontdb}; use serde::Deserialize; use tagu::prelude::*; #[derive(Parser)] pub(crate) struct RenderBenchmarksArgs { /// Path to a JSON output ...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-dev/src/generate_json_schema.rs
crates/uv-dev/src/generate_json_schema.rs
use std::path::PathBuf; use anstream::println; use anyhow::{Result, bail}; use pretty_assertions::StrComparison; use schemars::JsonSchema; use serde::Deserialize; use uv_settings::Options as SettingsOptions; use uv_workspace::pyproject::ToolUv as WorkspaceOptions; use crate::ROOT_DIR; use crate::generate_all::Mode; ...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-dev/src/validate_zip.rs
crates/uv-dev/src/validate_zip.rs
use std::ops::Deref; use anyhow::{Result, bail}; use clap::Parser; use futures::TryStreamExt; use tokio_util::compat::FuturesAsyncReadCompatExt; use uv_cache::{Cache, CacheArgs}; use uv_client::{BaseClientBuilder, RegistryClientBuilder}; use uv_pep508::VerbatimUrl; use uv_pypi_types::ParsedUrl; use uv_settings::Envir...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-dev/src/main.rs
crates/uv-dev/src/main.rs
use std::env; use std::path::PathBuf; use std::process::ExitCode; use std::str::FromStr; use std::time::Instant; use anstream::eprintln; use owo_colors::OwoColorize; use tracing::{debug, trace}; use tracing_durations_export::DurationsLayerBuilder; use tracing_durations_export::plot::PlotConfig; use tracing_subscriber:...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-dev/src/generate_cli_reference.rs
crates/uv-dev/src/generate_cli_reference.rs
//! Generate a Markdown-compatible reference for the uv command-line interface. use std::cmp::max; use std::path::PathBuf; use anstream::println; use anyhow::{Result, bail}; use clap::{Command, CommandFactory}; use itertools::Itertools; use pretty_assertions::StrComparison; use crate::ROOT_DIR; use crate::generate_al...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-dev/src/wheel_metadata.rs
crates/uv-dev/src/wheel_metadata.rs
use std::str::FromStr; use anstream::println; use anyhow::{Result, bail}; use clap::Parser; use uv_cache::{Cache, CacheArgs}; use uv_client::{BaseClientBuilder, RegistryClientBuilder}; use uv_distribution_filename::WheelFilename; use uv_distribution_types::{BuiltDist, DirectUrlBuiltDist, IndexCapabilities, RemoteSour...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-dev/src/generate_env_vars_reference.rs
crates/uv-dev/src/generate_env_vars_reference.rs
//! Generate the environment variables reference from `uv_static::EnvVars`. use anyhow::bail; use pretty_assertions::StrComparison; use std::collections::BTreeSet; use std::path::PathBuf; use uv_static::EnvVars; use crate::ROOT_DIR; use crate::generate_all::Mode; #[derive(clap::Args)] pub(crate) struct Args { #...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-normalize/src/lib.rs
crates/uv-normalize/src/lib.rs
use std::error::Error; use std::fmt::{Display, Formatter}; pub use dist_info_name::DistInfoName; pub use extra_name::{DefaultExtras, ExtraName}; pub use group_name::{DEV_DEPENDENCIES, DefaultGroups, GroupName, PipGroupName}; pub use package_name::PackageName; use uv_small_str::SmallString; mod dist_info_name; mod ex...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-normalize/src/extra_name.rs
crates/uv-normalize/src/extra_name.rs
use std::fmt; use std::fmt::{Display, Formatter}; use std::str::FromStr; use serde::ser::SerializeSeq; use serde::{Deserialize, Deserializer, Serialize}; use uv_small_str::SmallString; use crate::{InvalidNameError, validate_and_normalize_ref}; /// Either the literal "all" or a list of extras #[derive(Debug, Clone, ...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-normalize/src/group_name.rs
crates/uv-normalize/src/group_name.rs
#[cfg(feature = "schemars")] use std::borrow::Cow; use std::fmt::{Display, Formatter}; use std::path::PathBuf; use std::str::FromStr; use std::sync::LazyLock; use serde::ser::SerializeSeq; use serde::{Deserialize, Deserializer, Serialize, Serializer}; use uv_small_str::SmallString; use crate::{ InvalidNameError,...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-normalize/src/package_name.rs
crates/uv-normalize/src/package_name.rs
use std::borrow::Cow; use std::cmp::PartialEq; use std::str::FromStr; use serde::{Deserialize, Deserializer, Serialize}; use uv_small_str::SmallString; use crate::{InvalidNameError, validate_and_normalize_ref}; /// The normalized name of a package. /// /// Converts the name to lowercase and collapses runs of `-`, `...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-normalize/src/dist_info_name.rs
crates/uv-normalize/src/dist_info_name.rs
use std::borrow::Cow; use std::fmt; use std::fmt::{Display, Formatter}; /// The normalized name of a `.dist-info` directory. /// /// Like [`PackageName`](crate::PackageName), but without restrictions on the set of allowed /// characters, etc. /// /// See: <https://github.com/pypa/pip/blob/111eed14b6e9fba7c78a5ec2b7594...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-performance-memory-allocator/src/lib.rs
crates/uv-performance-memory-allocator/src/lib.rs
//! The only purpose of this crate is to pull in `mimalloc` on windows and //! `tikv-jemallocator` on most other platforms. #[cfg(target_os = "windows")] #[global_allocator] static GLOBAL: mimalloc::MiMalloc = mimalloc::MiMalloc; #[cfg(all( not(target_os = "windows"), not(target_os = "openbsd"), not(targe...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-client/src/tls.rs
crates/uv-client/src/tls.rs
use reqwest::Identity; use std::ffi::OsStr; use std::io::Read; #[derive(thiserror::Error, Debug)] pub(crate) enum CertificateError { #[error(transparent)] Io(#[from] std::io::Error), #[error(transparent)] Reqwest(reqwest::Error), } /// Return the `Identity` from the provided file. pub(crate) fn read_i...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-client/src/registry_client.rs
crates/uv-client/src/registry_client.rs
use std::collections::BTreeMap; use std::fmt::Debug; use std::path::PathBuf; use std::str::FromStr; use std::sync::Arc; use std::time::Duration; use async_http_range_reader::AsyncHttpRangeReader; use futures::{FutureExt, StreamExt, TryStreamExt}; use http::{HeaderMap, StatusCode}; use itertools::Either; use reqwest::{...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
true
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-client/src/html.rs
crates/uv-client/src/html.rs
use std::str::FromStr; use jiff::Timestamp; use tl::HTMLTag; use tracing::{debug, instrument, warn}; use uv_normalize::PackageName; use uv_pep440::VersionSpecifiers; use uv_pypi_types::{BaseUrl, CoreMetadata, Hashes, PypiFile, Yanked}; use uv_pypi_types::{HashError, LenientVersionSpecifiers}; use uv_redacted::{Displa...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
true
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-client/src/lib.rs
crates/uv-client/src/lib.rs
pub use base_client::{ AuthIntegration, BaseClient, BaseClientBuilder, DEFAULT_MAX_REDIRECTS, DEFAULT_RETRIES, ExtraMiddleware, RedirectClientWithMiddleware, RedirectPolicy, RequestBuilder, RetryParsingError, RetryState, UvRetryableStrategy, }; pub use cached_client::{CacheControl, CachedClient, CachedClien...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-client/src/linehaul.rs
crates/uv-client/src/linehaul.rs
use std::env; use serde::{Deserialize, Serialize}; use tracing::instrument; use uv_pep508::MarkerEnvironment; use uv_platform_tags::{Os, Platform}; use uv_static::EnvVars; use uv_version::version; #[derive(Debug, Clone, PartialEq, Deserialize, Serialize)] pub struct Installer { pub name: Option<String>, pub ...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-client/src/rkyvutil.rs
crates/uv-client/src/rkyvutil.rs
/*! Defines some helpers for use with `rkyv`. # Owned archived type Typical usage patterns with rkyv involve using an `&Archived<T>`, where values of that type are cast from a `&[u8]`. The owned archive type in this module effectively provides a way to use `Archive<T>` without needing to worry about the lifetime of t...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-client/src/base_client.rs
crates/uv-client/src/base_client.rs
use std::error::Error; use std::fmt::Debug; use std::fmt::Write; use std::num::ParseIntError; use std::path::Path; use std::sync::Arc; use std::time::{Duration, SystemTime}; use std::{env, io, iter}; use anyhow::anyhow; use http::{ HeaderMap, HeaderName, HeaderValue, Method, StatusCode, header::{ AUTHO...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
true
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-client/src/middleware.rs
crates/uv-client/src/middleware.rs
use http::Extensions; use std::fmt::Debug; use uv_redacted::DisplaySafeUrl; use reqwest::{Request, Response}; use reqwest_middleware::{Middleware, Next}; /// A custom error type for the offline middleware. #[derive(Debug, Clone, PartialEq, Eq)] pub(crate) struct OfflineError { url: DisplaySafeUrl, } impl Offline...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-client/src/error.rs
crates/uv-client/src/error.rs
use async_http_range_reader::AsyncHttpRangeReaderError; use async_zip::error::ZipError; use serde::Deserialize; use std::fmt::{Display, Formatter}; use std::ops::Deref; use std::path::PathBuf; use uv_cache::Error as CacheError; use uv_distribution_filename::{WheelFilename, WheelFilenameError}; use uv_normalize::Packag...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-client/src/flat_index.rs
crates/uv-client/src/flat_index.rs
use std::path::{Path, PathBuf}; use futures::{FutureExt, StreamExt}; use reqwest::Response; use tracing::{Instrument, debug, info_span, warn}; use url::Url; use uv_cache::{Cache, CacheBucket}; use uv_cache_key::cache_digest; use uv_distribution_filename::DistFilename; use uv_distribution_types::{File, FileLocation, I...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-client/src/remote_metadata.rs
crates/uv-client/src/remote_metadata.rs
use crate::{Error, ErrorKind}; use async_http_range_reader::AsyncHttpRangeReader; use futures::io::BufReader; use tokio_util::compat::TokioAsyncReadCompatExt; use url::Url; use uv_distribution_filename::WheelFilename; use uv_metadata::find_archive_dist_info; /// Read the `.dist-info/METADATA` file from a async remote ...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-client/src/cached_client.rs
crates/uv-client/src/cached_client.rs
use std::{borrow::Cow, path::Path}; use futures::FutureExt; use reqwest::{Request, Response}; use rkyv::util::AlignedVec; use serde::de::DeserializeOwned; use serde::{Deserialize, Serialize}; use tracing::{Instrument, debug, info_span, instrument, trace, warn}; use uv_cache::{CacheEntry, Freshness}; use uv_fs::write_...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
true
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-client/src/httpcache/control.rs
crates/uv-client/src/httpcache/control.rs
use std::collections::HashSet; use crate::rkyvutil::OwnedArchive; /// Represents values for relevant cache-control directives. /// /// This does include some directives that we don't use mostly because they are /// trivial to support. (For example, `must-understand` at time of writing is /// not used in our HTTP cach...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-client/src/httpcache/mod.rs
crates/uv-client/src/httpcache/mod.rs
/*! A somewhat simplistic implementation of HTTP cache semantics. This implementation was guided by the following things: * RFCs 9110 and 9111. * The `http-cache-semantics` crate. (The implementation here is completely different, but the source of `http-cache-semantics` helped guide the implementation here and un...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
true
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-client/tests/it/user_agent_version.rs
crates/uv-client/tests/it/user_agent_version.rs
use std::str::FromStr; use anyhow::Result; use insta::{assert_json_snapshot, assert_snapshot, with_settings}; use url::Url; use uv_cache::Cache; use uv_client::RegistryClientBuilder; use uv_client::{BaseClientBuilder, LineHaul}; use uv_pep508::{MarkerEnvironment, MarkerEnvironmentBuilder}; use uv_platform_tags::{Arch...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-client/tests/it/main.rs
crates/uv-client/tests/it/main.rs
mod http_util; mod remote_metadata; mod ssl_certs; mod user_agent_version;
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-client/tests/it/http_util.rs
crates/uv-client/tests/it/http_util.rs
use std::net::SocketAddr; use std::path::PathBuf; use std::sync::Arc; use anyhow::{Context, Result}; use futures::future; use http_body_util::combinators::BoxBody; use http_body_util::{BodyExt, Full}; use hyper::body::{Bytes, Incoming}; use hyper::header::USER_AGENT; use hyper::service::service_fn; use hyper::{Request...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-client/tests/it/ssl_certs.rs
crates/uv-client/tests/it/ssl_certs.rs
use std::str::FromStr; use anyhow::Result; use rustls::AlertDescription; use url::Url; use uv_cache::Cache; use uv_client::BaseClientBuilder; use uv_client::RegistryClientBuilder; use uv_redacted::DisplaySafeUrl; use uv_static::EnvVars; use crate::http_util::{ generate_self_signed_certs, generate_self_signed_cer...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-client/tests/it/remote_metadata.rs
crates/uv-client/tests/it/remote_metadata.rs
use std::str::FromStr; use anyhow::Result; use uv_cache::Cache; use uv_client::{BaseClientBuilder, RegistryClientBuilder}; use uv_distribution_filename::WheelFilename; use uv_distribution_types::{BuiltDist, DirectUrlBuiltDist, IndexCapabilities}; use uv_pep508::VerbatimUrl; use uv_redacted::DisplaySafeUrl; #[tokio::...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-build-frontend/src/lib.rs
crates/uv-build-frontend/src/lib.rs
//! Build wheels from source distributions. //! //! <https://packaging.python.org/en/latest/specifications/source-distribution-format/> mod error; mod pipreqs; use std::borrow::Cow; use std::ffi::OsString; use std::fmt::Formatter; use std::fmt::Write; use std::io; use std::path::{Path, PathBuf}; use std::process::Exi...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
true
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-build-frontend/src/pipreqs.rs
crates/uv-build-frontend/src/pipreqs.rs
use std::str::FromStr; use std::sync::LazyLock; use rustc_hash::FxHashMap; use uv_normalize::PackageName; /// A mapping from module name to PyPI package name. pub(crate) struct ModuleMap<'a>(FxHashMap<&'a str, PackageName>); impl<'a> ModuleMap<'a> { /// Generate a [`ModuleMap`] from a string representation, enco...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-build-frontend/src/error.rs
crates/uv-build-frontend/src/error.rs
use std::env; use std::fmt::{Display, Formatter}; use std::io; use std::path::PathBuf; use std::process::ExitStatus; use std::sync::LazyLock; use crate::PythonRunnerOutput; use owo_colors::OwoColorize; use regex::Regex; use thiserror::Error; use tracing::error; use uv_configuration::BuildOutput; use uv_distribution_ty...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-build/src/main.rs
crates/uv-build/src/main.rs
use std::env; use std::io::Write; use std::path::PathBuf; use anyhow::{Context, Result, bail}; use tracing_subscriber::filter::LevelFilter; use tracing_subscriber::layer::SubscriberExt; use tracing_subscriber::util::SubscriberInitExt; use tracing_subscriber::{EnvFilter, Layer}; use uv_logging::UvFormat; /// Entrypoi...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-extract/src/stream.rs
crates/uv-extract/src/stream.rs
use std::path::{Component, Path, PathBuf}; use std::pin::Pin; use async_zip::base::read::cd::Entry; use async_zip::error::ZipError; use futures::{AsyncReadExt, StreamExt}; use rustc_hash::{FxHashMap, FxHashSet}; use tokio_util::compat::{FuturesAsyncReadCompatExt, TokioAsyncReadCompatExt}; use tracing::{debug, warn}; ...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-extract/src/lib.rs
crates/uv-extract/src/lib.rs
use std::sync::LazyLock; pub use error::Error; use regex::Regex; pub use sync::*; use uv_static::EnvVars; mod error; pub mod hash; pub mod stream; mod sync; mod vendor; static CONTROL_CHARACTERS_RE: LazyLock<Regex> = LazyLock::new(|| Regex::new(r"\p{C}").unwrap()); static REPLACEMENT_CHARACTER: &str = "\u{FFFD}"; /...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-extract/src/sync.rs
crates/uv-extract/src/sync.rs
use std::path::{Path, PathBuf}; use std::sync::{LazyLock, Mutex}; use crate::vendor::{CloneableSeekableReader, HasLength}; use crate::{Error, insecure_no_validate, validate_archive_member_name}; use rayon::prelude::*; use rustc_hash::FxHashSet; use tracing::warn; use uv_configuration::RAYON_INITIALIZE; use zip::ZipArc...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-extract/src/error.rs
crates/uv-extract/src/error.rs
use std::{ffi::OsString, path::PathBuf}; #[derive(Debug, thiserror::Error)] pub enum Error { #[error("I/O operation failed during extraction")] Io(#[source] std::io::Error), #[error("Invalid zip file")] Zip(#[from] zip::result::ZipError), #[error("Invalid zip file structure")] AsyncZip(#[from] ...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-extract/src/hash.rs
crates/uv-extract/src/hash.rs
use blake2::digest::consts::U32; use sha2::Digest; use std::pin::Pin; use std::task::{Context, Poll}; use tokio::io::{AsyncReadExt, ReadBuf}; use uv_pypi_types::{HashAlgorithm, HashDigest}; #[derive(Debug)] pub enum Hasher { Md5(md5::Md5), Sha256(sha2::Sha256), Sha384(sha2::Sha384), Sha512(sha2::Sha51...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-extract/src/vendor/cloneable_seekable_reader.rs
crates/uv-extract/src/vendor/cloneable_seekable_reader.rs
// Copyright 2022 Google LLC // Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or // https://www.apache.org/licenses/LICENSE-2.0> or the MIT license // <LICENSE-MIT or https://opensource.org/licenses/MIT>, at your // option. This file may not be copied, modified, or distributed // except according to t...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-extract/src/vendor/mod.rs
crates/uv-extract/src/vendor/mod.rs
pub(crate) use cloneable_seekable_reader::{CloneableSeekableReader, HasLength}; mod cloneable_seekable_reader;
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-bench/src/lib.rs
crates/uv-bench/src/lib.rs
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-bench/benches/uv.rs
crates/uv-bench/benches/uv.rs
use std::hint::black_box; use std::str::FromStr; use criterion::{Criterion, criterion_group, criterion_main, measurement::WallTime}; use uv_cache::Cache; use uv_client::{BaseClientBuilder, RegistryClientBuilder}; use uv_distribution_types::Requirement; use uv_python::PythonEnvironment; use uv_resolver::Manifest; fn r...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-bench/inputs/platform_tags.rs
crates/uv-bench/inputs/platform_tags.rs
&[("cp310", "abi3", "linux_x86_64"), ("cp310", "abi3", "manylinux1_x86_64"), ("cp310", "abi3", "manylinux2010_x86_64"), ("cp310", "abi3", "manylinux2014_x86_64"), ("cp310", "abi3", "manylinux_2_10_x86_64"), ("cp310", "abi3", "manylinux_2_11_x86_64"), ("cp310", "abi3", "manylinux_2_12_x86_64"), ("cp310", "abi3", "manyli...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
true
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-platform/src/lib.rs
crates/uv-platform/src/lib.rs
//! Platform detection for operating system, architecture, and libc. use std::cmp; use std::fmt; use std::str::FromStr; use target_lexicon::Architecture; use thiserror::Error; use tracing::trace; pub use crate::arch::{Arch, ArchVariant}; pub use crate::libc::{Libc, LibcDetectionError, LibcVersion}; pub use crate::os:...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-platform/src/os.rs
crates/uv-platform/src/os.rs
use crate::Error; use std::fmt; use std::fmt::Display; use std::ops::Deref; use std::str::FromStr; #[derive(Debug, Eq, PartialEq, Clone, Copy, Hash)] pub struct Os(pub(crate) target_lexicon::OperatingSystem); impl Os { pub fn new(os: target_lexicon::OperatingSystem) -> Self { Self(os) } pub fn fr...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-platform/src/cpuinfo.rs
crates/uv-platform/src/cpuinfo.rs
//! Fetches CPU information. use std::io::Error; #[cfg(target_os = "linux")] use procfs::{CpuInfo, Current}; /// Detects whether the hardware supports floating-point operations using ARM's Vector Floating Point (VFP) hardware. /// /// This function is relevant specifically for ARM architectures, where the presence o...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-platform/src/libc.rs
crates/uv-platform/src/libc.rs
//! Determine the libc (glibc or musl) on linux. //! //! Taken from `glibc_version` (<https://github.com/delta-incubator/glibc-version-rs>), //! which used the Apache 2.0 license (but not the MIT license) use crate::cpuinfo::detect_hardware_floating_point_support; use fs_err as fs; use goblin::elf::Elf; use regex::Reg...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-platform/src/arch.rs
crates/uv-platform/src/arch.rs
use crate::Error; use std::str::FromStr; /// Architecture variants, e.g., with support for different instruction sets #[derive(Debug, Eq, PartialEq, Clone, Copy, Hash, Ord, PartialOrd)] pub enum ArchVariant { /// Targets 64-bit Intel/AMD CPUs newer than Nehalem (2008). /// Includes SSE3, SSE4 and other post-20...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-git/src/rate_limit.rs
crates/uv-git/src/rate_limit.rs
use reqwest::{Response, StatusCode}; use std::sync::atomic::{AtomicBool, Ordering}; /// A global state on whether we are being rate-limited by GitHub's REST API. /// If we are, avoid "fast-path" attempts. pub(crate) static GITHUB_RATE_LIMIT_STATUS: GitHubRateLimitStatus = GitHubRateLimitStatus::new(); /// GitHub REST...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-git/src/source.rs
crates/uv-git/src/source.rs
//! Git support is derived from Cargo's implementation. //! Cargo is dual-licensed under either Apache 2.0 or MIT, at the user's choice. //! Source: <https://github.com/rust-lang/cargo/blob/23eb492cf920ce051abfc56bbaf838514dc8365c/src/cargo/sources/git/source.rs> use std::borrow::Cow; use std::path::{Path, PathBuf}; u...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-git/src/lib.rs
crates/uv-git/src/lib.rs
pub use crate::credentials::{GIT_STORE, store_credentials_from_url}; pub use crate::git::{GIT, GIT_LFS, GitError}; pub use crate::resolver::{ GitResolver, GitResolverError, RepositoryReference, ResolvedRepositoryReference, }; pub use crate::source::{Fetch, GitSource, Reporter}; mod credentials; mod git; mod rate_l...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-git/src/git.rs
crates/uv-git/src/git.rs
//! Git support is derived from Cargo's implementation. //! Cargo is dual-licensed under either Apache 2.0 or MIT, at the user's choice. //! Source: <https://github.com/rust-lang/cargo/blob/23eb492cf920ce051abfc56bbaf838514dc8365c/src/cargo/sources/git/utils.rs> use std::fmt::Display; use std::path::{Path, PathBuf}; us...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-git/src/credentials.rs
crates/uv-git/src/credentials.rs
use std::collections::HashMap; use std::sync::{Arc, LazyLock, RwLock}; use tracing::trace; use uv_auth::Credentials; use uv_cache_key::RepositoryUrl; use uv_redacted::DisplaySafeUrl; /// Global authentication cache for a uv invocation. /// /// This is used to share Git credentials within a single process. pub static G...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-git/src/resolver.rs
crates/uv-git/src/resolver.rs
use std::borrow::Cow; use std::path::PathBuf; use std::str::FromStr; use std::sync::Arc; use dashmap::DashMap; use dashmap::mapref::one::Ref; use fs_err::tokio as fs; use reqwest_middleware::ClientWithMiddleware; use tracing::debug; use uv_cache_key::{RepositoryUrl, cache_digest}; use uv_fs::{LockedFile, LockedFileEr...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-shell/src/shlex.rs
crates/uv-shell/src/shlex.rs
use crate::{Shell, Simplified}; use std::path::Path; /// Quote a path, if necessary, for safe use in a POSIX-compatible shell command. pub fn shlex_posix(executable: impl AsRef<Path>) -> String { // Convert to a display path. let executable = executable.as_ref().portable_display().to_string(); // Like Pyt...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-shell/src/lib.rs
crates/uv-shell/src/lib.rs
pub mod runnable; mod shlex; pub mod windows; pub use shlex::{escape_posix_for_single_quotes, shlex_posix, shlex_windows}; use std::env::home_dir; use std::path::{Path, PathBuf}; use uv_fs::Simplified; use uv_static::EnvVars; #[cfg(unix)] use tracing::debug; /// Shells for which virtualenv activation scripts are a...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-shell/src/windows.rs
crates/uv-shell/src/windows.rs
//! Windows-specific utilities for manipulating the environment. //! //! Based on rustup's Windows implementation: <https://github.com/rust-lang/rustup/commit/bce3ed67d219a2b754857f9e231287794d8c770d> #![cfg(windows)] use std::path::Path; use anyhow::Context; use tracing::warn; use windows::Win32::Foundation::{ERROR...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-shell/src/runnable.rs
crates/uv-shell/src/runnable.rs
//! Utilities for running executables and scripts. Particularly in Windows. use std::env::consts::EXE_EXTENSION; use std::ffi::OsStr; use std::path::Path; use std::process::Command; use uv_fs::with_added_extension; #[derive(Debug)] pub enum WindowsRunnable { /// Windows PE (.exe) Executable, /// `PowerSh...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-preview/src/lib.rs
crates/uv-preview/src/lib.rs
use std::{ fmt::{Display, Formatter}, str::FromStr, }; use thiserror::Error; use uv_warnings::warn_user_once; bitflags::bitflags! { #[derive(Debug, Clone, Copy, PartialEq, Eq, Default)] pub struct PreviewFeatures: u32 { const PYTHON_INSTALL_DEFAULT = 1 << 0; const PYTHON_UPGRADE = 1 <<...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-installer/src/uninstall.rs
crates/uv-installer/src/uninstall.rs
use uv_distribution_types::{InstalledDist, InstalledDistKind, InstalledEggInfoFile}; /// Uninstall a package from the specified Python environment. pub async fn uninstall( dist: &InstalledDist, ) -> Result<uv_install_wheel::Uninstall, UninstallError> { let uninstall = tokio::task::spawn_blocking({ let ...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-installer/src/installer.rs
crates/uv-installer/src/installer.rs
use std::convert; use std::sync::{Arc, LazyLock}; use anyhow::{Context, Error, Result}; use rayon::iter::{IntoParallelRefIterator, ParallelIterator}; use tokio::sync::oneshot; use tracing::instrument; use uv_cache::Cache; use uv_configuration::RAYON_INITIALIZE; use uv_distribution_types::CachedDist; use uv_install_wh...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-installer/src/lib.rs
crates/uv-installer/src/lib.rs
pub use compile::{CompileError, compile_tree}; pub use installer::{Installer, Reporter as InstallReporter}; pub use plan::{Plan, Planner}; pub use preparer::{Error as PrepareError, Preparer, Reporter as PrepareReporter}; pub use site_packages::{ InstallationStrategy, SatisfiesResult, SitePackages, SitePackagesDiagn...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-installer/src/compile.rs
crates/uv-installer/src/compile.rs
use std::panic::AssertUnwindSafe; use std::path::{Path, PathBuf}; use std::process::Stdio; use std::time::Duration; use std::{env, io, panic}; use async_channel::{Receiver, SendError}; use tempfile::tempdir_in; use thiserror::Error; use tokio::io::{AsyncBufReadExt, AsyncReadExt, AsyncWriteExt, BufReader}; use tokio::p...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-installer/src/satisfies.rs
crates/uv-installer/src/satisfies.rs
use std::borrow::Cow; use std::fmt::Debug; use same_file::is_same_file; use tracing::{debug, trace}; use url::Url; use uv_cache_info::CacheInfo; use uv_cache_key::{CanonicalUrl, RepositoryUrl}; use uv_distribution_filename::ExpandedTags; use uv_distribution_types::{ BuildInfo, BuildVariables, ConfigSettings, Extr...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-installer/src/plan.rs
crates/uv-installer/src/plan.rs
use std::sync::Arc; use anyhow::{Result, bail}; use owo_colors::OwoColorize; use tracing::{debug, warn}; use uv_cache::{Cache, CacheBucket, WheelCache}; use uv_cache_info::Timestamp; use uv_configuration::{BuildOptions, Reinstall}; use uv_distribution::{ BuiltWheelIndex, HttpArchivePointer, LocalArchivePointer, R...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
true
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-installer/src/preparer.rs
crates/uv-installer/src/preparer.rs
use std::cmp::Reverse; use std::sync::Arc; use futures::{FutureExt, Stream, TryFutureExt, TryStreamExt, stream::FuturesUnordered}; use tracing::{debug, instrument}; use uv_cache::Cache; use uv_configuration::BuildOptions; use uv_distribution::{DistributionDatabase, LocalWheel}; use uv_distribution_types::{ Builda...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-installer/src/site_packages.rs
crates/uv-installer/src/site_packages.rs
use std::borrow::Cow; use std::collections::BTreeSet; use std::iter::Flatten; use std::path::PathBuf; use anyhow::{Context, Result}; use fs_err as fs; use rustc_hash::{FxBuildHasher, FxHashMap, FxHashSet}; use uv_distribution_types::{ ConfigSettings, Diagnostic, ExtraBuildRequires, ExtraBuildVariables, InstalledD...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-settings/src/settings.rs
crates/uv-settings/src/settings.rs
use std::{fmt::Debug, num::NonZeroUsize, path::Path, path::PathBuf}; use serde::{Deserialize, Serialize}; use uv_cache_info::CacheKey; use uv_configuration::{ BuildIsolation, IndexStrategy, KeyringProviderType, PackageNameSpecifier, Reinstall, RequiredVersion, TargetTriple, TrustedHost, TrustedPublishing, Upg...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
true
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-settings/src/lib.rs
crates/uv-settings/src/lib.rs
use std::num::NonZeroUsize; use std::ops::Deref; use std::path::{Path, PathBuf}; use std::time::Duration; use uv_dirs::{system_config_file, user_config_dir}; use uv_flags::EnvironmentFlags; use uv_fs::Simplified; use uv_static::EnvVars; use uv_warnings::warn_user; pub use crate::combine::*; pub use crate::settings::*...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-settings/src/combine.rs
crates/uv-settings/src/combine.rs
use std::path::PathBuf; use std::{collections::BTreeMap, num::NonZeroUsize}; use url::Url; use uv_configuration::{ BuildIsolation, ExportFormat, IndexStrategy, KeyringProviderType, Reinstall, RequiredVersion, TargetTriple, TrustedPublishing, Upgrade, }; use uv_distribution_types::{ ConfigSettings, ExtraBu...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-pep440/src/lib.rs
crates/uv-pep440/src/lib.rs
//! A library for python version numbers and specifiers, implementing //! [PEP 440](https://peps.python.org/pep-0440) //! //! PEP 440 has a lot of unintuitive features, including: //! //! * An epoch that you can prefix the version which, e.g. `1!1.2.3`. Lower epoch always means lower //! version (`1.0 <=2!0.1`) //! *...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-pep440/src/version.rs
crates/uv-pep440/src/version.rs
use serde::{Deserialize, Deserializer, Serialize, Serializer, de}; use std::fmt::Formatter; use std::num::NonZero; use std::ops::Deref; use std::sync::LazyLock; use std::{ borrow::Borrow, cmp::Ordering, hash::{Hash, Hasher}, str::FromStr, sync::Arc, }; use uv_cache_key::{CacheKey, CacheKeyHasher}; ...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
true
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-pep440/src/version_ranges.rs
crates/uv-pep440/src/version_ranges.rs
//! Convert [`VersionSpecifiers`] to [`Ranges`]. use std::cmp::Ordering; use std::collections::Bound; use std::ops::Deref; use version_ranges::Ranges; use crate::{ LocalVersion, LocalVersionSlice, Operator, Prerelease, Version, VersionSpecifier, VersionSpecifiers, }; impl From<VersionSpecifiers> for Ranges<V...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-pep440/src/version_specifier.rs
crates/uv-pep440/src/version_specifier.rs
use std::borrow::Cow; use std::cmp::Ordering; use std::fmt::Formatter; use std::ops::Bound; use std::str::FromStr; use crate::{ Operator, OperatorParseError, Version, VersionPattern, VersionPatternParseError, version, }; use serde::{Deserialize, Deserializer, Serialize, Serializer, de}; #[cfg(feature = "tracing")]...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
true
astral-sh/uv
https://github.com/astral-sh/uv/blob/2318e48e819080f37a002551035c2b1880a81a70/crates/uv-auth/src/lib.rs
crates/uv-auth/src/lib.rs
pub use access_token::AccessToken; pub use cache::CredentialsCache; pub use credentials::{Credentials, Username}; pub use index::{AuthPolicy, Index, Indexes}; pub use keyring::KeyringProvider; pub use middleware::AuthMiddleware; pub use pyx::{ DEFAULT_TOLERANCE_SECS, PyxJwt, PyxOAuthTokens, PyxTokenStore, PyxTokens...
rust
Apache-2.0
2318e48e819080f37a002551035c2b1880a81a70
2026-01-04T15:31:58.679374Z
false