샘플
polars 1.43.2: Port pandas DataFrame code to polars on Alpine, without the wheel surprise or the silently wrong answers
검증된 샘플 — pypi polars 1.43.2: Port pandas DataFrame code to polars on Alpine, without the wheel surprise or the silently wrong answers. python 3.12 · linux…
sha256:a238e626062c628c548646e46144b6aac21a07492cf10e1617eb4286c853ac05
이 네트워크가 제공하는 것은 하나입니다. 빌드되는 샘플. 샌드박스에서 돌리고 서명된 영수증을 보관합니다. 등급을 매기지 않고 무엇도 보증하지 않습니다 — 같은 코드가 당신 환경에서 빌드되는지는 측정한 적이 없습니다.
통과한 계약 영수증을 낸 서로 다른 서명 키의 수입니다. 하나면 작성자 혼자이고, 둘 이상이면 다른 사람도 빌드했다는 뜻입니다. 키는 스스로 만드는 것이고 뒤에 등록된 신원이 없으므로, 세는 것은 사람이 아니라 키입니다.
MIT-0
실행 증거
선언된 환경과 서명된 실행을 분리해 두었습니다. 이 샘플이 무엇을 어디서 실행했는지 그대로 볼 수 있습니다.
- 증거 기준
- 서명된 컨트랙트 통과
- 검증 영수증
- 2
- 빌드한 서명 키
- 2
선언된 환경
python 3.12 linux · musl x64 python 3.12 python pip
검증 실행 환경
| 환경 | 컨트랙트 | 단계 | 실행일 |
|---|---|---|---|
| python 3.12 · linux alpine/x64 · docker ed25519:a2ec939a4c60e243 | PASS | compile:SKIPPED · contract:PASS · load:PASS · resolve:PASS CONTAINER_RUN · pypi@1 |
2026-08-14 |
| python 3.12 · linux alpine/x64 · docker ed25519:d91480838ac982c9 | PASS | compile:SKIPPED · contract:PASS · load:PASS · resolve:PASS CONTAINER_RUN · pypi@1 |
2026-08-18 |
케이스
MIGRATION- 목표
- Port pandas DataFrame code to polars on Alpine, without the wheel surprise or the silently wrong answers
- 심벌
-
- polars.DataFrame
- polars.LazyFrame
- polars.col
- polars.len
- DataFrame.filter
- DataFrame.select
- DataFrame.with_columns
- DataFrame.with_row_index
- DataFrame.group_by
- GroupBy.agg
- LazyFrame.collect
- LazyFrame.explain
- LazyFrame.collect_schema
- Expr.map_elements
- Expr.alias
- Series.is_null
- Series.is_nan
- Series.fill_null
- Series.fill_nan
- Series.eq_missing
- polars.exceptions.ColumnNotFoundError
- polars.exceptions.DuplicateError
- polars.exceptions.PerformanceWarning
- DataFrame.vstack
- DataFrame.hstack
- DataFrame.extend
- DataFrame.insert_column
- DataFrame.drop_in_place
- 환경
- python 3.12
- 생성일
- 2026-08-14T12:56:07Z
컨트랙트
- assert pip took the musllinux wheel for the engine, polars_runtime_32-1.43.2-cp310-abi3-musllinux_1_2_x86_64.whl, reconstructed from the recorded dist-info tag
- assert polars itself is a pure-Python py3-none-any distribution carrying no compiled file, which depends on polars-runtime-32==1.43.2 for the engine
- assert the engine's shared object is named .abi3.so rather than this interpreter's EXT_SUFFIX, so one cp310-abi3 build serves 3.12
- assert the interpreter reports musl and polars.__version__ agrees with the distribution metadata, which is the check a half-installed polars fails
- assert a DataFrame has none of index, loc, iloc, at, iat, values, reset_index, sort_values, assign, query or apply
- assert filtering renumbers rows from zero, and with_row_index before the filter is what carries the original positions through, as UInt32 data
- assert brackets take a column by name and a row by position, and an unknown name raises ColumnNotFoundError
- assert a boolean mask in brackets selects columns rather than rows, raising ValueError when its length does not match the column count
- assert the same mask on a frame with as many columns as rows returns the wrong columns with no error at all
- assert filter with a pl.col boolean expression returns the intended rows and select takes strings, pl.col and an anchored regex
- assert an Expr has no truth value, so `and` and `or` both raise TypeError, and dropping the parentheses around & raises that identical message
- assert separate positional predicates mean AND, and the keyword form is equality against a literal
- assert with_columns returns a new frame, leaves the input's columns and values untouched, and has no inplace parameter
- assert item assignment on a DataFrame raises TypeError naming DataFrame.with_columns as the replacement
- assert the new frame shares the untouched column's Arrow allocation with the old one, so returning a frame copies the column list rather than the data
- assert polars does keep a mutating escape hatch: hstack and vstack take in_place= and hand the same object back, and extend, insert_column and drop_in_place mutate the receiver
- assert an unaliased expression is named after the first column it mentions, so with_columns replaces that column instead of adding one
- assert explain returns the plan as a string while the per-row Python hook has still not been called once
- assert the optimizer moves the filter below the projection, the reverse of both the unoptimized plan and the order written
- assert collect runs the hook on only the two surviving rows, where the identical eager pipeline runs it on all six
- assert a LazyFrame naming a missing column is built without complaint and raises ColumnNotFoundError only when the plan is resolved, which explain also does
- assert a LazyFrame has no shape, and asking it for columns emits a PerformanceWarning because that resolves the schema
- assert is_null and is_nan disagree on every hole, and is_nan over a null is null rather than False
- assert null_count reports one null while the mean is nan, count excludes the null and pl.len counts every row
- assert a column holding a NaN and no null reports null_count zero with a nan mean, so a missing-data check written as null_count() == 0 passes on it
- assert min and max ignore the NaN that sum and mean propagate
- assert comparison against a null yields null while eq_missing yields False
- assert polars orders NaN above every number and compares it equal to itself, the opposite of Python, so a > 0 filter keeps the NaN and drops the null
- assert nulls sort first in both directions unless nulls_last is set
- assert drop_nulls keeps NaN and drop_nans keeps null, neither fill touches the other's hole, and fill_nan(None) collapses the two into one
- assert an integer column with a missing value stays Int64 and its aggregates skip the null on both sides of the division
- assert group_by returns the group keys first, then one column per agg expression in the order given
- assert maintain_order gives first-appearance order, which is not sorted order, and without it only the set of rows is defined
- assert two aggregates over one column collide as DuplicateError, worded one way inside agg and another inside select
파일
- csx.json
- requirements.txt
- src/__init__.py
- src/frames.py
- src/install.py
- test/contract.py