Skip to main content

CLI for converting and sanitizing data table files.

Project description

csv-converter-skart

PyPI Version Python Version CI GitHub Repo

Command-line tool for converting and sanitizing spreadsheet files, with a focus on inconsistent data and CSV generation backed by pandas.

Versão em português

Overview

This project converts .xlsx, .xls, and .csv files to CSV while applying normalization steps that are useful when the source data contains structural, content, or encoding issues.

Key features:

  • Convert spreadsheet files to CSV.
  • Normalize CSV files and rewrite them as UTF-8.
  • Sanitize internal XML content from XLSX files.
  • Detect text encoding for CSV inputs.
  • Use the project through both a CLI and a Python module.

Requirements

  • Python >= 3.10

Installation

pip install csv-converter-skart

Usage

Command line

If only the input file is provided, the File{OriginalFileName}Normalized directory is created in the current working directory. The generated CSV keeps the original base filename.

csv-converter ./my_files/file.xlsx

To define the output file explicitly, use -o or --output.

csv-converter ./my_files/file.xlsx --output ./csv/normalized_file.csv

To display the CLI help:

csv-converter --help

Module usage

The package also exposes the csv_converter function for direct import.

import pandas as pd
from pathlib import Path

from csv_converter import csv_converter

input_file = Path("./meu_arquivo.xlsx")
output_file = Path("./destino.csv")

generated_file = csv_converter(input_file, output_file)
dataframe = pd.read_csv(generated_file)

print(dataframe.info())

Output behavior

  • .xlsx and .xls inputs are processed and exported to CSV.
  • .csv inputs are read with encoding detection and rewritten as UTF-8.
  • When no output path is provided, one is created automatically.

License

MIT License - Copyright (c) 2026 Artur dos Santos Shon

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

csv_converter_skart-0.2.2.tar.gz (14.6 kB view details)

Uploaded Source

Built Distribution

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

csv_converter_skart-0.2.2-py3-none-any.whl (21.9 kB view details)

Uploaded Python 3

File details

Details for the file csv_converter_skart-0.2.2.tar.gz.

File metadata

  • Download URL: csv_converter_skart-0.2.2.tar.gz
  • Upload date:
  • Size: 14.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for csv_converter_skart-0.2.2.tar.gz
Algorithm Hash digest
SHA256 d227cf9dfe178ef70aabbef84864246c5ad601c6b8626fc84fae5f622cf92617
MD5 aa6cc53b8ae088b6da02997ee22b56c7
BLAKE2b-256 b3f689f99550c83c10f3d325aced00a4414d37c37634bed2ab8fa413537e3f91

See more details on using hashes here.

Provenance

The following attestation bundles were made for csv_converter_skart-0.2.2.tar.gz:

Publisher: cd.yml on SkyArtur/csv-converter-skart

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

File details

Details for the file csv_converter_skart-0.2.2-py3-none-any.whl.

File metadata

File hashes

Hashes for csv_converter_skart-0.2.2-py3-none-any.whl
Algorithm Hash digest
SHA256 cfb6ed6a1a666162012c7aaadbe71f89610ef3ef99fb51bb65ca0ddef833949c
MD5 3d698fd3be7c85d2609f171e88cfba98
BLAKE2b-256 549d8644b7f4b07d0c74df86f893ceb90e13d75f148d3efc30c866fd056b13e0

See more details on using hashes here.

Provenance

The following attestation bundles were made for csv_converter_skart-0.2.2-py3-none-any.whl:

Publisher: cd.yml on SkyArtur/csv-converter-skart

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