Skip to content

Commit 5630fa4

Browse files
committed
Merge branch 'main' into user-warning
2 parents c557349 + ab0e4bd commit 5630fa4

27 files changed

+215
-119
lines changed

.github/workflows/ci.yml

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ jobs:
3232
- run: rustup component add llvm-tools-preview
3333

3434
- name: install uv
35-
uses: astral-sh/setup-uv@v3
35+
uses: astral-sh/setup-uv@v4
3636
with:
3737
enable-cache: true
3838

@@ -55,7 +55,7 @@ jobs:
5555

5656
- run: coverage-prepare lcov python/pydantic_core/*.so
5757

58-
- uses: codecov/codecov-action@v4
58+
- uses: codecov/codecov-action@v5
5959

6060
# See https://github.com/PyO3/pyo3/discussions/2781
6161
# tests intermittently segfault with pypy and cpython 3.7 when using `coverage run ...`, hence separate job
@@ -88,7 +88,7 @@ jobs:
8888
key: test-v3
8989

9090
- name: install uv
91-
uses: astral-sh/setup-uv@v3
91+
uses: astral-sh/setup-uv@v4
9292
with:
9393
enable-cache: true
9494

@@ -127,7 +127,7 @@ jobs:
127127
uses: Swatinem/rust-cache@v2
128128

129129
- name: install uv
130-
uses: astral-sh/setup-uv@v3
130+
uses: astral-sh/setup-uv@v4
131131
with:
132132
enable-cache: true
133133

@@ -152,7 +152,7 @@ jobs:
152152
- uses: actions/checkout@v4
153153

154154
- name: install uv
155-
uses: astral-sh/setup-uv@v3
155+
uses: astral-sh/setup-uv@v4
156156
with:
157157
enable-cache: true
158158

@@ -197,7 +197,7 @@ jobs:
197197
- uses: actions/checkout@v4
198198

199199
- name: install uv
200-
uses: astral-sh/setup-uv@v3
200+
uses: astral-sh/setup-uv@v4
201201
with:
202202
enable-cache: true
203203

@@ -239,7 +239,7 @@ jobs:
239239
uses: Swatinem/rust-cache@v2
240240

241241
- name: install uv
242-
uses: astral-sh/setup-uv@v3
242+
uses: astral-sh/setup-uv@v4
243243
with:
244244
enable-cache: true
245245

@@ -283,7 +283,7 @@ jobs:
283283
node-version: '18'
284284

285285
- name: install uv
286-
uses: astral-sh/setup-uv@v3
286+
uses: astral-sh/setup-uv@v4
287287
with:
288288
enable-cache: true
289289

@@ -343,7 +343,7 @@ jobs:
343343
actions-cache-folder: emsdk-cache
344344

345345
- name: install uv
346-
uses: astral-sh/setup-uv@v3
346+
uses: astral-sh/setup-uv@v4
347347
with:
348348
enable-cache: true
349349

@@ -543,7 +543,7 @@ jobs:
543543
- uses: actions/checkout@v4
544544

545545
- name: install uv
546-
uses: astral-sh/setup-uv@v3
546+
uses: astral-sh/setup-uv@v4
547547
with:
548548
enable-cache: true
549549

@@ -668,7 +668,7 @@ jobs:
668668
- uses: actions/checkout@v4
669669

670670
- name: install uv
671-
uses: astral-sh/setup-uv@v3
671+
uses: astral-sh/setup-uv@v4
672672
with:
673673
enable-cache: true
674674

.github/workflows/codspeed.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ jobs:
2626
python-version: ${{ env.UV_PYTHON}}
2727

2828
- name: install uv
29-
uses: astral-sh/setup-uv@v3
29+
uses: astral-sh/setup-uv@v4
3030
with:
3131
enable-cache: true
3232

Cargo.lock

Lines changed: 22 additions & 14 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -33,18 +33,17 @@ pyo3 = { version = "0.23.2", features = ["generate-import-lib", "num-bigint", "p
3333
regex = "1.11.1"
3434
strum = { version = "0.26.3", features = ["derive"] }
3535
strum_macros = "0.26.4"
36-
serde_json = {version = "1.0.132", features = ["arbitrary_precision", "preserve_order"]}
36+
serde_json = {version = "1.0.133", features = ["arbitrary_precision", "preserve_order"]}
3737
enum_dispatch = "0.3.13"
38-
serde = { version = "1.0.214", features = ["derive"] }
38+
serde = { version = "1.0.215", features = ["derive"] }
3939
speedate = "0.15.0"
4040
smallvec = "1.13.2"
4141
ahash = "0.8.10"
4242
url = "2.5.0"
4343
# idna is already required by url, added here to be explicit
44-
idna = "1.0.2"
44+
idna = "1.0.3"
4545
base64 = "0.22.1"
4646
num-bigint = "0.4.6"
47-
python3-dll-a = "0.2.10"
4847
uuid = "1.11.0"
4948
jiter = { version = "0.8.0", features = ["python"] }
5049
hex = "0.4.3"

src/errors/validation_exception.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -582,7 +582,7 @@ struct ValidationErrorSerializer<'py> {
582582
input_type: &'py InputType,
583583
}
584584

585-
impl<'py> Serialize for ValidationErrorSerializer<'py> {
585+
impl Serialize for ValidationErrorSerializer<'_> {
586586
fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
587587
where
588588
S: Serializer,
@@ -614,7 +614,7 @@ struct PyLineErrorSerializer<'py> {
614614
input_type: &'py InputType,
615615
}
616616

617-
impl<'py> Serialize for PyLineErrorSerializer<'py> {
617+
impl Serialize for PyLineErrorSerializer<'_> {
618618
fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
619619
where
620620
S: Serializer,

src/input/datetime.rs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ pub enum EitherDate<'a> {
2424
Py(Bound<'a, PyDate>),
2525
}
2626

27-
impl<'a> From<Date> for EitherDate<'a> {
27+
impl From<Date> for EitherDate<'_> {
2828
fn from(date: Date) -> Self {
2929
Self::Raw(date)
3030
}
@@ -45,7 +45,7 @@ pub fn pydate_as_date(py_date: &Bound<'_, PyAny>) -> PyResult<Date> {
4545
})
4646
}
4747

48-
impl<'a> EitherDate<'a> {
48+
impl EitherDate<'_> {
4949
pub fn as_raw(&self) -> PyResult<Date> {
5050
match self {
5151
Self::Raw(date) => Ok(date.clone()),
@@ -68,7 +68,7 @@ pub enum EitherTime<'a> {
6868
Py(Bound<'a, PyTime>),
6969
}
7070

71-
impl<'a> From<Time> for EitherTime<'a> {
71+
impl From<Time> for EitherTime<'_> {
7272
fn from(time: Time) -> Self {
7373
Self::Raw(time)
7474
}
@@ -87,7 +87,7 @@ pub enum EitherTimedelta<'a> {
8787
PySubclass(Bound<'a, PyDelta>),
8888
}
8989

90-
impl<'a> From<Duration> for EitherTimedelta<'a> {
90+
impl From<Duration> for EitherTimedelta<'_> {
9191
fn from(timedelta: Duration) -> Self {
9292
Self::Raw(timedelta)
9393
}
@@ -200,7 +200,7 @@ pub fn pytime_as_time(py_time: &Bound<'_, PyAny>, py_dt: Option<&Bound<'_, PyAny
200200
})
201201
}
202202

203-
impl<'a> EitherTime<'a> {
203+
impl EitherTime<'_> {
204204
pub fn as_raw(&self) -> PyResult<Time> {
205205
match self {
206206
Self::Raw(time) => Ok(time.clone()),
@@ -240,7 +240,7 @@ pub enum EitherDateTime<'a> {
240240
Py(Bound<'a, PyDateTime>),
241241
}
242242

243-
impl<'a> From<DateTime> for EitherDateTime<'a> {
243+
impl From<DateTime> for EitherDateTime<'_> {
244244
fn from(dt: DateTime) -> Self {
245245
Self::Raw(dt)
246246
}

src/input/input_abstract.rs

Lines changed: 12 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -268,7 +268,6 @@ pub trait ValidatedSet<'py> {
268268

269269
/// This type is used for inputs which don't support certain types.
270270
/// It implements all the associated traits, but never actually gets called.
271-
272271
pub enum Never {}
273272

274273
impl<'py> ValidatedDict<'py> for Never {
@@ -330,7 +329,10 @@ impl Arguments<'_> for Never {
330329
}
331330

332331
impl<'py> PositionalArgs<'py> for Never {
333-
type Item<'a> = Bound<'py, PyAny> where Self: 'a;
332+
type Item<'a>
333+
= Bound<'py, PyAny>
334+
where
335+
Self: 'a;
334336
fn len(&self) -> usize {
335337
unreachable!()
336338
}
@@ -343,8 +345,14 @@ impl<'py> PositionalArgs<'py> for Never {
343345
}
344346

345347
impl<'py> KeywordArgs<'py> for Never {
346-
type Key<'a> = Bound<'py, PyAny> where Self: 'a;
347-
type Item<'a> = Bound<'py, PyAny> where Self: 'a;
348+
type Key<'a>
349+
= Bound<'py, PyAny>
350+
where
351+
Self: 'a;
352+
type Item<'a>
353+
= Bound<'py, PyAny>
354+
where
355+
Self: 'a;
348356
fn len(&self) -> usize {
349357
unreachable!()
350358
}

0 commit comments

Comments
 (0)