Skip to main content

Pyodide-friendly fork of fg-data-profiling (ydata-profiling) for browser WASM

Project description

fg-data-profiling-wasm

Pyodide-friendly fork of fg-data-profiling (formerly ydata-profiling / pandas-profiling).

You do not compile this package to WASM. Upstream already ships as a pure-Python wheel (py2.py3-none-any). This fork only does dependency surgery so it can install and run under Pyodide.

What changed vs upstream

Change Why
Drop hard deps: numba, minify-html, phik Native / JIT; broken or impractical in browser WASM
Default html.minify_html = False Avoid lazy-importing the Rust minify-html extension
Soft-fail if minify is requested but missing Safer in constrained environments
Keep phi_k off (already upstream default) Avoid needing phik
Package name fg-data-profiling-wasm Distinguish the Pyodide wheel from upstream
Allow pandas>=3 (<4) Upstream still pins <3.0; this fork patches typeset/string paths

Optional native extras remain under [project.optional-dependencies] native for desktop use.

Layout

src/                  # vendored upstream + patches
patches/              # 0001 pyodide defaults + 0002 pandas3 compat (reapplied on sync)
scripts/sync-upstream.sh
upstream.lock.json    # pinned upstream ref + commit
pyodide/              # install helper + dependency matrix
pyproject.toml        # Pyodide-friendly dependency set

Upgrading from upstream

Pinned upstream lives in upstream.lock.json.

# Is upstream ahead of our lock?
make check-upstream
# or: ./scripts/sync-upstream.sh --check

# Pull latest develop (or whatever ref is in the lock), re-apply patches,
# refresh dependency pins, update the lockfile
make sync
# or: ./scripts/sync-upstream.sh

# Sync a release tag / other ref
make sync-ref REF=v4.9.0
# or: ./scripts/sync-upstream.sh --ref v4.9.0

# After a successful sync, bump our PyPI version
./scripts/sync-upstream.sh --bump patch

# If a patch no longer applies: fix src/ by hand, then regenerate the patch series
./scripts/sync-upstream.sh --regen-patches

Typical release flow after upstream moves:

./scripts/sync-upstream.sh --ref develop --bump patch
python -m build
# review git diff, commit, push, twine upload dist/*

A weekly GitHub Action (.github/workflows/upstream-check.yml) opens/comments on an issue when the lock is behind.

Build a wheel

python -m pip install build
python -m build    # → dist/fg_data_profiling_wasm-*-py2.py3-none-any.whl

Current artifact:

  • dist/fg_data_profiling_wasm-0.1.1-py2.py3-none-any.whl (purelib; PyPI-compatible; pandas <4)

Publish to PyPI (GitHub Actions)

The package is not on PyPI yet. Publishing is automated via Trusted Publishing (OIDC) — no long-lived API token in the repo.

One-time PyPI setup

  1. Sign in at https://pypi.org/
  2. Open PublishingAdd a new pending publisher (project does not exist yet):
    • PyPI project name: fg-data-profiling-wasm
    • Owner: awesome-wasm-packages
    • Repository: fg-data-profiling-wasm
    • Workflow name: publish.yml
    • Environment name: pypi
  3. In GitHub → Settings → Environments → create environment pypi (optional protection rules / required reviewers).

Publish a version

# bump version in VERSION + pyproject.toml (or)
./scripts/sync-upstream.sh --bump patch
git add -A && git commit -m "Release $(tr -d '[:space:]' < VERSION)"
git tag "v$(tr -d '[:space:]' < VERSION)"
git push && git push --tags

Then create a GitHub Release for that tag (or use the UI). The Publish to PyPI workflow builds the wheel and uploads it.

You can also run the workflow manually: Actions → Publish to PyPI → Run workflow.

Use in Pyodide / PyConsole

Package name on PyPI is fg-data-profiling-wasm; import name is data_profiling.

import micropip
await micropip.install("fg-data-profiling-wasm")

import pandas as pd
from data_profiling import ProfileReport

df = pd.DataFrame({"a": [1, 2, 3], "b": ["x", "y", "x"]})
report = ProfileReport(
    df,
    minimal=True,
    progress_bar=False,
    correlations={"phi_k": {"calculate": False}},
    html={"minify_html": False},
)
html = report.to_html()

Notes for PyConsole (Pyodide 314 / Python 3.14):

  • Use >=0.1.2 (older releases reject Python 3.14 / pin numpy/scipy/matplotlib too tightly).
  • Auto-install-on-import will not find this package from import data_profiling — install by PyPI name first.
  • Prefer minimal=True and turn off phi_k / HTML minify for speed and missing native deps.

Helpers live in pyodide/install.py; dependency notes in pyodide/DEPS.md.

Difficulty (recap)

Goal Difficulty
Install this pure wheel in Pyodide Easy
Usable ProfileReport (core EDA, minimal=True) Medium
Full upstream fidelity (phik, minify, numba-shaped features) Hard / skip

Upstream

Based on Data-Centric-AI-Community/fg-data-profiling. Tracked commit is in upstream.lock.json. MIT-licensed; see LICENSE.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

fg_data_profiling_wasm-0.1.2.tar.gz (312.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

fg_data_profiling_wasm-0.1.2-py2.py3-none-any.whl (397.3 kB view details)

Uploaded Python 2Python 3

File details

Details for the file fg_data_profiling_wasm-0.1.2.tar.gz.

File metadata

  • Download URL: fg_data_profiling_wasm-0.1.2.tar.gz
  • Upload date:
  • Size: 312.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for fg_data_profiling_wasm-0.1.2.tar.gz
Algorithm Hash digest
SHA256 4ef85c79ba24f0fca2cb527c7b2785d422ba7857b0fbd1c7d3db0138205a5e07
MD5 6993f2a3e79b7629894c2c9aa8e11122
BLAKE2b-256 4fef2bd2070e88e88ea2d51844767216cc6b2d6aee06b832f1f7e6e6bb14aae9

See more details on using hashes here.

Provenance

The following attestation bundles were made for fg_data_profiling_wasm-0.1.2.tar.gz:

Publisher: publish.yml on awesome-wasm-packages/fg-data-profiling-wasm

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file fg_data_profiling_wasm-0.1.2-py2.py3-none-any.whl.

File metadata

File hashes

Hashes for fg_data_profiling_wasm-0.1.2-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 85c98623d24246c0fe34cfc41715b4ce88f6fbd6b43ef5a9db5496bf7cd07481
MD5 a2058416868df44776e7e3e733920fe9
BLAKE2b-256 376cabb90af1b2f54c46cc01d48eeacf9a8615b4263247d018a92c4b58537eb7

See more details on using hashes here.

Provenance

The following attestation bundles were made for fg_data_profiling_wasm-0.1.2-py2.py3-none-any.whl:

Publisher: publish.yml on awesome-wasm-packages/fg-data-profiling-wasm

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page