Skip to main content

Python library to check for problematic Unicode code points.

Project description

RFC9839

PyPI - Version Coveralls License

Python library to check for problematic Unicode code points.

Port of Go library of the same name.

Based on the Unicode code-point subsets specified in RFC9839.

Usage

from rfc9839 import unicode_scalar, xml_character, unicode_assignable

code_point = 0xFDDA # ARABIC LIGATURE SAD WITH MEEM WITH ALEF MAKSURA FINAL FORM

print(unicode_scalar.is_valid_code_point(code_point)) # True
print(xml_character.is_valid_code_point(code_point)) # True
print(unicode_assignable.is_valid_code_point(code_point)) # False


print(unicode_assignable.is_valid_string(chr(code_point))) # False
print(xml_character.is_valid_utf8(chr(code_point).encode("utf-8"))) # True

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

rfc9839-0.0.2.tar.gz (3.0 kB view details)

Uploaded Source

Built Distribution

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

rfc9839-0.0.2-py3-none-any.whl (4.1 kB view details)

Uploaded Python 3

File details

Details for the file rfc9839-0.0.2.tar.gz.

File metadata

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

File hashes

Hashes for rfc9839-0.0.2.tar.gz
Algorithm Hash digest
SHA256 59d0ff00eec10af10668dd0079c99f6f0f2bc59f8b8cd7b1ba7584d2245752cd
MD5 c8982b71304a2211df1ddbd3c50fe807
BLAKE2b-256 164599785385cfc7ab424518988f97b343430d5d6ae1d34127153fb4b5d090c8

See more details on using hashes here.

Provenance

The following attestation bundles were made for rfc9839-0.0.2.tar.gz:

Publisher: release.yml on elliotwutingfeng/rfc9839

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

File details

Details for the file rfc9839-0.0.2-py3-none-any.whl.

File metadata

  • Download URL: rfc9839-0.0.2-py3-none-any.whl
  • Upload date:
  • Size: 4.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for rfc9839-0.0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 f99dfb99799a6b3650f907ee4d578b458f89613603611892c93efb7aceb8d4cc
MD5 08850b111d9a5ba521e369d5a7239725
BLAKE2b-256 14787081fa3751791a5a5dff559c8d0fbe2fe1c583be9239a99cbcec1170bacf

See more details on using hashes here.

Provenance

The following attestation bundles were made for rfc9839-0.0.2-py3-none-any.whl:

Publisher: release.yml on elliotwutingfeng/rfc9839

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