Skip to main content

A Python toolbox of validators, parsers, and datasets for Moroccan-specific data formats and regions.

Project description

Moroccan Atlas

A Python toolbox of validators, parsers, and datasets for Moroccan-specific data formats and regions.

Note: This project is in early development. Features and functionality may and will change over time.

Installation

pip install morocco-validators

Usage

from morocco_validators import is_valid_cin, is_valid_ice, is_valid_phone

print(is_valid_cin("AB123456"))          # True
print(is_valid_ice("001234567000084"))   # True
print(is_valid_phone("0600123456"))      # True

Validators Available

is_valid_XYZ, return True or False

  • is_valid_cin(value) — 8-character alphanumeric CIN, must start with letters.

Extractors

Do not perform validation. Just extract data directly.

Parsers

Parsers perform validation + extraction of data. If it's invalid, they raise a ValidationError exception.

Data

Compressed CSVs or JSONs

Load with importlib.resources (modern & zip-safe way)

Check size of package: python -m build du -sh dist/*

License

A commercial license is required for any organization with more than 10 employees or annual revenue over $500,000 USD, or using this software as part of a product or service offered for a fee.

See LICENSE, or contact the author, for more details.

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

moroccan_atlas-0.1.0.tar.gz (4.1 kB view details)

Uploaded Source

Built Distribution

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

moroccan_atlas-0.1.0-py3-none-any.whl (5.3 kB view details)

Uploaded Python 3

File details

Details for the file moroccan_atlas-0.1.0.tar.gz.

File metadata

  • Download URL: moroccan_atlas-0.1.0.tar.gz
  • Upload date:
  • Size: 4.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.1.2 CPython/3.10.14 Linux/6.8.0-57-generic

File hashes

Hashes for moroccan_atlas-0.1.0.tar.gz
Algorithm Hash digest
SHA256 37267d371438bafa6c982e1ca6460a51a37e9e39febefc5da92b5ff4828eda12
MD5 8e105a337b04361ea2a70046365aeae6
BLAKE2b-256 45a5cfd1e592d14a6919f889be6642c79e4c4cb3c8e8734806dcd2ca59126687

See more details on using hashes here.

File details

Details for the file moroccan_atlas-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: moroccan_atlas-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 5.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.1.2 CPython/3.10.14 Linux/6.8.0-57-generic

File hashes

Hashes for moroccan_atlas-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 86f210beafea663d63d02a18af91ba7466f7cb2ad155f2c9d88b205db17ddf0e
MD5 2586eadf8b85d2f1f6b8b7b3f5f0f0cc
BLAKE2b-256 104f115f0bdb5d3fc6e74b0f8500c642fc0d2d9bcd9a11ddfc3125a381fdcf7a

See more details on using hashes here.

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