mirror of
https://github.com/astral-sh/uv.git
synced 2025-11-03 05:03:46 +00:00
Remove URI type from JSON Schema (#6449)
## Summary Relative paths (like `./foo/bar`) are also welcome here!
This commit is contained in:
parent
fa3446651f
commit
4591d0b4b2
2 changed files with 2 additions and 6 deletions
|
|
@ -34,7 +34,6 @@ impl schemars::JsonSchema for IndexUrl {
|
||||||
fn json_schema(_gen: &mut schemars::gen::SchemaGenerator) -> schemars::schema::Schema {
|
fn json_schema(_gen: &mut schemars::gen::SchemaGenerator) -> schemars::schema::Schema {
|
||||||
schemars::schema::SchemaObject {
|
schemars::schema::SchemaObject {
|
||||||
instance_type: Some(schemars::schema::InstanceType::String.into()),
|
instance_type: Some(schemars::schema::InstanceType::String.into()),
|
||||||
format: Some("uri".to_owned()),
|
|
||||||
metadata: Some(Box::new(schemars::schema::Metadata {
|
metadata: Some(Box::new(schemars::schema::Metadata {
|
||||||
description: Some("The URL of an index to use for fetching packages (e.g., `https://pypi.org/simple`).".to_string()),
|
description: Some("The URL of an index to use for fetching packages (e.g., `https://pypi.org/simple`).".to_string()),
|
||||||
..schemars::schema::Metadata::default()
|
..schemars::schema::Metadata::default()
|
||||||
|
|
@ -193,7 +192,6 @@ impl schemars::JsonSchema for FlatIndexLocation {
|
||||||
fn json_schema(_gen: &mut schemars::gen::SchemaGenerator) -> schemars::schema::Schema {
|
fn json_schema(_gen: &mut schemars::gen::SchemaGenerator) -> schemars::schema::Schema {
|
||||||
schemars::schema::SchemaObject {
|
schemars::schema::SchemaObject {
|
||||||
instance_type: Some(schemars::schema::InstanceType::String.into()),
|
instance_type: Some(schemars::schema::InstanceType::String.into()),
|
||||||
format: Some("uri".to_owned()),
|
|
||||||
metadata: Some(Box::new(schemars::schema::Metadata {
|
metadata: Some(Box::new(schemars::schema::Metadata {
|
||||||
description: Some("The path to a directory of distributions, or a URL to an HTML file with a flat listing of distributions.".to_string()),
|
description: Some("The path to a directory of distributions, or a URL to an HTML file with a flat listing of distributions.".to_string()),
|
||||||
..schemars::schema::Metadata::default()
|
..schemars::schema::Metadata::default()
|
||||||
|
|
|
||||||
6
uv.schema.json
generated
6
uv.schema.json
generated
|
|
@ -451,8 +451,7 @@
|
||||||
},
|
},
|
||||||
"FlatIndexLocation": {
|
"FlatIndexLocation": {
|
||||||
"description": "The path to a directory of distributions, or a URL to an HTML file with a flat listing of distributions.",
|
"description": "The path to a directory of distributions, or a URL to an HTML file with a flat listing of distributions.",
|
||||||
"type": "string",
|
"type": "string"
|
||||||
"format": "uri"
|
|
||||||
},
|
},
|
||||||
"IndexStrategy": {
|
"IndexStrategy": {
|
||||||
"oneOf": [
|
"oneOf": [
|
||||||
|
|
@ -481,8 +480,7 @@
|
||||||
},
|
},
|
||||||
"IndexUrl": {
|
"IndexUrl": {
|
||||||
"description": "The URL of an index to use for fetching packages (e.g., `https://pypi.org/simple`).",
|
"description": "The URL of an index to use for fetching packages (e.g., `https://pypi.org/simple`).",
|
||||||
"type": "string",
|
"type": "string"
|
||||||
"format": "uri"
|
|
||||||
},
|
},
|
||||||
"KeyringProviderType": {
|
"KeyringProviderType": {
|
||||||
"description": "Keyring provider type to use for credential lookup.",
|
"description": "Keyring provider type to use for credential lookup.",
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue