Safer Stubs for PySpark
This is a project to create safer stubs for PySpark. The goal is to make it easier to use PySpark in a safer way, without having to worry about the underlying implementation. It implements only subset of working PySpark APIs with goal to have a minimal set of functions that can be used in a safer way.
How to use
To use the stubs, you need to install the package:
pip install pyspark-safestubs
Then, you can use the stubs in your code:
from pyspark.sql import SparkSession
from pyspark.sql import functions as F
def some_transform(df: DataFrame['col1', 'col2']):
df = df.withColumn('col5', F.col('col1').cast('int'))
# df has type DataFrame['col1', 'col2', 'col5']
return df
Metadata
Release files for pyspark-safestubs 0.1.6
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| pyspark_safestubs-0.1.6.tar.gz | 119.7 kB | Without provenance | Details for pyspark_safestubs-0.1.6.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| pyspark_safestubs-0.1.6-py3-none-any.whl | Python 3 | none | any | Details for pyspark_safestubs-0.1.6-py3-none-any.whl |
Total release size: 327.6 kB
Release files / pyspark_safestubs-0.1.6.tar.gz
| Download URL | pyspark_safestubs-0.1.6.tar.gz |
|---|---|
| Size | 119.7 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
cc0891850d72dcf1d2d2c2e1be0f8d0ac9a799345c3d7f8252e8e75f17b04754
|
|
BLAKE2b-256 checksum How to use checksums |
87a288732e490255efd68fc1d0e8709fde667ef5eb3cb9f6056ee22f27ba8490
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.11.11
|
Release files / pyspark_safestubs-0.1.6-py3-none-any.whl
| Download URL | pyspark_safestubs-0.1.6-py3-none-any.whl |
|---|---|
| Size | 207.9 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
3adcbe72ffb829aa71640f7671820cadd2ac105ff260edf3f0cc14f8af5707e6
|
|
BLAKE2b-256 checksum How to use checksums |
b0a7d41f3737cdf79466610e0636c67aee4a0b1e3c016f3beb2a8d3324c6c816
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.11.11
|
Security for pyspark-safestubs 0.1.6
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.