Skip to main content

inpsPyPI

inpsPyPI is a PyPI package for Python 3.10+ that provides useful tools for data conversion and validation, a custom EasySQL class for simplified SQLite operations, a custom excel file handler, and a custom file IO handler.


Features

inpsPyPI contains several distinct modules to help keep your codebase clean and readable:

Validation (Check)

A robust validation class to simplify standard string and format checks.

  • Email formatting and customizable domain validation.
  • Validates Philippine mobile numbers (+639 / 09).
  • Check for spaces, symbols, and pure numerical strings.

Cryptography (Cipher)

A basic cryptography class to implement classic cipher techniques.

  • Transposition Cipher
  • Giovanni Cipher
  • Keyword Cipher
  • Caesar Cipher

Data Conversion (Convert)

Effortless type casting and data encoding.

  • Hex, Binary, and Base64 encoding/decoding.
  • String reversal and byte-array conversions.
  • Quick casting for Int, Float, Double, and Long.

Data Structures

Custom implementations for improved data manipulation.

  • Dictionarily: An enhanced Dictionary object with built-in sorting (alphabetical and numerical-first).
  • Memory: A clean, object-oriented list/array wrapper to handle storage, indexing, and removal.
  • Stackily: A classic Stack implementation (push, pop, peek, is_empty, size).
  • Node: A lightweight binary tree node implementation.

Database Management (EasySQL)

A simplified wrapper around Python's built-in sqlite3.

  • Create tables with ease by passing lists of dictionaries.
  • Insert, delete, and clear records directly via Python dictionaries.
  • Fetch and print table values seamlessly.

Excel Operations

A wrapper for openpyxl allowing for extremely fast Excel file data manipulation.

  • Read and write to specific columns across single or multiple sheets.
  • Skip header rows easily using skip_rows.
  • Zero-hassle reading/writing to entire column letters (e.g., Column 'A').

File Handling (SimpleFileHandler)

Static methods to rapidly read(), write(), and append() to text files using utf-8 encoding.

Sorting Algorithms

A massive suite of sorting algorithms available as quick plug-and-play functions.

  • Quick Sort, Merge Sort, Heap Sort, Selection Sort, Insertion Sort, Bubble Sort.
  • Advanced/Niche Sorts: Tim Sort, Intro Sort, Cocktail Shaker Sort, Shell Sort, Pigeonhole Sort, Bead Sort, and even Bogo Sort!

Installation

pip install inpsPyPI

Dependencies

The package largely uses Python's standard library (e.g., sqlite3, math, re, base64). However, the Excel operations module requires:

  • openpyxl
  • unidecode

Quick Usage Examples

1. Simple SQLite Database Queries (EasySQL)

from inpsPyPI import EasySQL

db = EasySQL("my_database")

# Create a database table
db.create_table("users", {
    "id": "INTEGER PRIMARY KEY", 
    "name": "TEXT",
    "age": "INTEGER"
})

# Insert data
db.insert_to_table("users", {"id": 1, "name": "Alice", "age": 28})

# Fetch values
records = db.get_table_values("users")
print(records)

2. Validating Phone Numbers & Emails (Check)

from inpsPyPI import Check

# Validate Philippine Phone Numbers
is_valid = Check.is_a_valid_philippine_mobile_number("+639123456789")
print(is_valid)  # True

# Validate Emails with strict domain rules
Check.Email.add_valid_domain_name("gmail")
Check.Email.add_valid_domain_extension("com")
print(Check.Email.is_valid("user@gmail.com"))  # True

3. File Handling (SimpleFileHandler)

from inpsPyPI import SimpleFileHandler

# Write, Append, and Read
SimpleFileHandler.write("log.txt", "Process started.\n")
SimpleFileHandler.append("log.txt", "Process finished.\n")

print(SimpleFileHandler.read("log.txt"))

4. Text Encryption (Cipher)

from inpsPyPI import Cipher

encrypted = Cipher.caesar_cipher("HELLO WORLD", shift=3)
print(encrypted)  # KHOOR ZRUOG

5. Sorting Array Data

from inpsPyPI import quicksort, merge_sort

array = [5, 2, 9, 1, 5, 6]
print(quicksort(array)) #[1, 2, 5, 5, 6, 9]

Contributing

Pull requests are welcome! For major changes, please open an issue first to discuss what you would like to change.

License

MIT

Download files

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

Source Distribution

inpspypi-1.0.3.tar.gz (12.0 kB view details)

Uploaded Source

Built Distribution

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

inpspypi-1.0.3-py3-none-any.whl (3.9 kB view details)

Uploaded Python 3

File details

Details for the file inpspypi-1.0.3.tar.gz.

File metadata

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

File hashes

Hashes for inpspypi-1.0.3.tar.gz
Algorithm Hash digest
SHA256 6f10bd66405469599f62e0c39cfe12e44445c3b8f720777c664c195494986857
MD5 d52a2388f8dc2c21e96a0953b65c2c77
BLAKE2b-256 b9bcf50561861a5d02967f4cc3d92812f53ce5ff0461506878def476c255889d

See more details on using hashes here.

Provenance

The following attestation bundles were made for inpspypi-1.0.3.tar.gz:

Publisher: build_inpsPyPI.yml on isaiahnoelpulidosalazar/inpsPyPI

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

File details

Details for the file inpspypi-1.0.3-py3-none-any.whl.

File metadata

  • Download URL: inpspypi-1.0.3-py3-none-any.whl
  • Upload date:
  • Size: 3.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for inpspypi-1.0.3-py3-none-any.whl
Algorithm Hash digest
SHA256 c307f975d033936c5d8a02215bb2e08ed8251182d0c446663d4ea0edf612794a
MD5 409251dddb7969cb6a444097a0ce1354
BLAKE2b-256 814f7d33b07a4dc6debd3a6412bf44c52f789dc2f82c9f8850b284001c62d514

See more details on using hashes here.

Provenance

The following attestation bundles were made for inpspypi-1.0.3-py3-none-any.whl:

Publisher: build_inpsPyPI.yml on isaiahnoelpulidosalazar/inpsPyPI

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

Release history Release notifications | RSS feed

1.0.6

2 files

1.0.5

2 files

1.0.4

2 files

This release

1.0.3 This release

2 files

1.0.2

2 files

1.0.1

2 files

1.0.0

2 files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page