Skip to main content

Fast Nepali (Bikram Sambat) datetime library

Project description

NPDateTime - Python

Fast Nepali (Bikram Sambat) datetime library for Python, powered by Rust.

Installation

pip install npdatetime

Quick Start

from npdatetime import NepaliDate

# Create a Nepali date
date = NepaliDate(2077, 5, 19)
print(date)  # 2077-05-19

# Convert to Gregorian
year, month, day = date.to_gregorian()
print(f"{year}-{month:02d}-{day:02d}")  # 2020-09-04

# Create from Gregorian
date = NepaliDate.from_gregorian(2020, 9, 4)
print(date)  # 2077-05-19

# Get today's date
today = NepaliDate.today()
print(today)

# Format dates
formatted = date.format("%d %B %Y")
print(formatted)  # 19 Bhadra 2077

# Date arithmetic
future = date.add_days(30)
print(future)

Features

  • Blazing Fast: 100x faster than pure Python implementations
  • 🎯 Accurate: Verified against official BS calendar data (1975-2100)
  • 🔧 Simple API: Pythonic interface with full type hints
  • 🌍 Battle-tested: Rust core ensures reliability

License

MIT

Project details


Download files

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

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distributions

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

npdatetime-0.2.2-cp314-cp314-win_amd64.whl (148.1 kB view details)

Uploaded CPython 3.14Windows x86-64

npdatetime-0.2.2-cp314-cp314-manylinux_2_34_x86_64.whl (290.5 kB view details)

Uploaded CPython 3.14manylinux: glibc 2.34+ x86-64

npdatetime-0.2.2-cp314-cp314-macosx_11_0_arm64.whl (248.8 kB view details)

Uploaded CPython 3.14macOS 11.0+ ARM64

npdatetime-0.2.2-cp313-cp313-win_amd64.whl (148.1 kB view details)

Uploaded CPython 3.13Windows x86-64

npdatetime-0.2.2-cp313-cp313-manylinux_2_34_x86_64.whl (290.4 kB view details)

Uploaded CPython 3.13manylinux: glibc 2.34+ x86-64

npdatetime-0.2.2-cp313-cp313-macosx_11_0_arm64.whl (248.8 kB view details)

Uploaded CPython 3.13macOS 11.0+ ARM64

npdatetime-0.2.2-cp312-cp312-win_amd64.whl (148.1 kB view details)

Uploaded CPython 3.12Windows x86-64

npdatetime-0.2.2-cp312-cp312-manylinux_2_34_x86_64.whl (290.5 kB view details)

Uploaded CPython 3.12manylinux: glibc 2.34+ x86-64

npdatetime-0.2.2-cp312-cp312-macosx_11_0_arm64.whl (248.8 kB view details)

Uploaded CPython 3.12macOS 11.0+ ARM64

npdatetime-0.2.2-cp311-cp311-win_amd64.whl (148.5 kB view details)

Uploaded CPython 3.11Windows x86-64

npdatetime-0.2.2-cp311-cp311-manylinux_2_34_x86_64.whl (291.6 kB view details)

Uploaded CPython 3.11manylinux: glibc 2.34+ x86-64

npdatetime-0.2.2-cp311-cp311-macosx_11_0_arm64.whl (250.5 kB view details)

Uploaded CPython 3.11macOS 11.0+ ARM64

npdatetime-0.2.2-cp310-cp310-win_amd64.whl (150.7 kB view details)

Uploaded CPython 3.10Windows x86-64

npdatetime-0.2.2-cp310-cp310-manylinux_2_34_x86_64.whl (293.9 kB view details)

Uploaded CPython 3.10manylinux: glibc 2.34+ x86-64

npdatetime-0.2.2-cp310-cp310-macosx_11_0_arm64.whl (253.3 kB view details)

Uploaded CPython 3.10macOS 11.0+ ARM64

npdatetime-0.2.2-cp39-cp39-win_amd64.whl (152.1 kB view details)

Uploaded CPython 3.9Windows x86-64

npdatetime-0.2.2-cp39-cp39-manylinux_2_34_x86_64.whl (294.7 kB view details)

Uploaded CPython 3.9manylinux: glibc 2.34+ x86-64

npdatetime-0.2.2-cp39-cp39-macosx_11_0_arm64.whl (255.0 kB view details)

Uploaded CPython 3.9macOS 11.0+ ARM64

npdatetime-0.2.2-cp38-cp38-win_amd64.whl (151.7 kB view details)

Uploaded CPython 3.8Windows x86-64

npdatetime-0.2.2-cp38-cp38-manylinux_2_34_x86_64.whl (294.5 kB view details)

Uploaded CPython 3.8manylinux: glibc 2.34+ x86-64

npdatetime-0.2.2-cp38-cp38-macosx_11_0_arm64.whl (254.4 kB view details)

Uploaded CPython 3.8macOS 11.0+ ARM64

File details

Details for the file npdatetime-0.2.2-cp314-cp314-win_amd64.whl.

File metadata

  • Download URL: npdatetime-0.2.2-cp314-cp314-win_amd64.whl
  • Upload date:
  • Size: 148.1 kB
  • Tags: CPython 3.14, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for npdatetime-0.2.2-cp314-cp314-win_amd64.whl
Algorithm Hash digest
SHA256 1e41b75d041e043841e8d05c1c5fac5456492228a8f2cc3d62d623532fba221a
MD5 b34aa3decce80421b7ddc82f9c8dd12b
BLAKE2b-256 9d5b28a54c5119d9d340561c4aa45cca462dc07100f48c0affcf975c4b7c3475

See more details on using hashes here.

File details

Details for the file npdatetime-0.2.2-cp314-cp314-manylinux_2_34_x86_64.whl.

File metadata

File hashes

Hashes for npdatetime-0.2.2-cp314-cp314-manylinux_2_34_x86_64.whl
Algorithm Hash digest
SHA256 34412298acb72d57f9667b12c3f3536139eec36f0c82bdf4f54906be86b267b4
MD5 deb6e6816cdd16f18c5d90199a67b97a
BLAKE2b-256 638c7407ba2153cabab21220d01813540825bd828c07a8d8be50b1ed511b31d3

See more details on using hashes here.

File details

Details for the file npdatetime-0.2.2-cp314-cp314-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for npdatetime-0.2.2-cp314-cp314-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 0cb2ac4f02160d1f6873cda4707074961a28a9539132c4a6f40a3c3d5c4e8706
MD5 a8e1363d0e9739b1e5d2e04e7fe350db
BLAKE2b-256 3e01273fbbd98f240351d09d2763d4191c3a7b4e7c3318ef8ba701fb8d1c5fbd

See more details on using hashes here.

File details

Details for the file npdatetime-0.2.2-cp313-cp313-win_amd64.whl.

File metadata

  • Download URL: npdatetime-0.2.2-cp313-cp313-win_amd64.whl
  • Upload date:
  • Size: 148.1 kB
  • Tags: CPython 3.13, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for npdatetime-0.2.2-cp313-cp313-win_amd64.whl
Algorithm Hash digest
SHA256 7c45c75c52a5eb8197f3d36474af303324d1981c08c0004a70bc397722d69cfe
MD5 8b756653aad8d1c39c14af715e6bde9a
BLAKE2b-256 d0670065503acc2f0d1a0f5c96d89d4d09e32902577c4ea2a350de21e843ff00

See more details on using hashes here.

File details

Details for the file npdatetime-0.2.2-cp313-cp313-manylinux_2_34_x86_64.whl.

File metadata

File hashes

Hashes for npdatetime-0.2.2-cp313-cp313-manylinux_2_34_x86_64.whl
Algorithm Hash digest
SHA256 750f4a13dc7de35a70ec903ae25d810228c0ddf696fa96b3a3990556c86e3863
MD5 c4bfcc6aadbc943c1f3fd904aa968fbd
BLAKE2b-256 dc1f5993b45bc684fe30ad295a585a8e2a0c906a1ae5e5dbfc5341bcba995acc

See more details on using hashes here.

File details

Details for the file npdatetime-0.2.2-cp313-cp313-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for npdatetime-0.2.2-cp313-cp313-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 c5b15d622aed57c5c736bb04ef116edfbc37f944b7d0eda80f9bacb3f4a2e17e
MD5 74f6d3fef7e7e0609c079ca5a02d61a2
BLAKE2b-256 285b179b8c101646653358c80bf45fcb8d1acbd7fe2be0fb0a82e77579572088

See more details on using hashes here.

File details

Details for the file npdatetime-0.2.2-cp312-cp312-win_amd64.whl.

File metadata

  • Download URL: npdatetime-0.2.2-cp312-cp312-win_amd64.whl
  • Upload date:
  • Size: 148.1 kB
  • Tags: CPython 3.12, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for npdatetime-0.2.2-cp312-cp312-win_amd64.whl
Algorithm Hash digest
SHA256 186588f646bd599e108734814d88a1c4ed5fd3a90a4938f352c49e4518815b50
MD5 036f21b159c1a7787e74304f087270f6
BLAKE2b-256 1735ded6e4a59a834a6a0522c590d309ad44573b4b343237c2d0986566dd2e1b

See more details on using hashes here.

File details

Details for the file npdatetime-0.2.2-cp312-cp312-manylinux_2_34_x86_64.whl.

File metadata

File hashes

Hashes for npdatetime-0.2.2-cp312-cp312-manylinux_2_34_x86_64.whl
Algorithm Hash digest
SHA256 b417594f8c71c5e1fe7083680d310e53db186bf6bcc01ab5e7dcbc269dfa123e
MD5 28af1b0373f58a4446d45872b6c9a1f4
BLAKE2b-256 80be44149bb78338267d5c0d50cd9359f9d9533d9bd4a283591b75fb4262bfc9

See more details on using hashes here.

File details

Details for the file npdatetime-0.2.2-cp312-cp312-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for npdatetime-0.2.2-cp312-cp312-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 203ad74fbbca9d1131fbad2ae91efa989577a84a726176f8ab1cf1dd7c870800
MD5 777aa4f3f31e4ddaf6a98f0a708193d2
BLAKE2b-256 17e0b0a8769bb1892e01589bdcee18093f3e7fa0e5fb41e67e9e1b2dd57e9847

See more details on using hashes here.

File details

Details for the file npdatetime-0.2.2-cp311-cp311-win_amd64.whl.

File metadata

  • Download URL: npdatetime-0.2.2-cp311-cp311-win_amd64.whl
  • Upload date:
  • Size: 148.5 kB
  • Tags: CPython 3.11, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for npdatetime-0.2.2-cp311-cp311-win_amd64.whl
Algorithm Hash digest
SHA256 6f3b7983f704808196f4807ea177ac22462e419f55f29c7aae39692a06f51d97
MD5 559142db50323c534743baf1dabfdf1b
BLAKE2b-256 1d32a109834246fb8272a34142e17c663fc96092cadb646392680c40a7cba77c

See more details on using hashes here.

File details

Details for the file npdatetime-0.2.2-cp311-cp311-manylinux_2_34_x86_64.whl.

File metadata

File hashes

Hashes for npdatetime-0.2.2-cp311-cp311-manylinux_2_34_x86_64.whl
Algorithm Hash digest
SHA256 2487620db6aa7b0fce743ec17bf00dfde3a497e6d9cbe5034231cfdbd77fbf96
MD5 9b2f2318f1bf7ac6b9dcf491a2a34e12
BLAKE2b-256 529874a42f3f5e55ce0050acab59907b23d411bccb50ee1aa60bb432863101c0

See more details on using hashes here.

File details

Details for the file npdatetime-0.2.2-cp311-cp311-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for npdatetime-0.2.2-cp311-cp311-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 0913534d60f733c534f49c3cea8a7e3d89640e91d2a6d77c4e1d510ff0f41de9
MD5 eca64b2a907198db15d4c8ac19d3bf90
BLAKE2b-256 73315e1937c1777737e27dd8f5b4fec70d1ca126c7a4b59eb434a7da19d4d13e

See more details on using hashes here.

File details

Details for the file npdatetime-0.2.2-cp310-cp310-win_amd64.whl.

File metadata

  • Download URL: npdatetime-0.2.2-cp310-cp310-win_amd64.whl
  • Upload date:
  • Size: 150.7 kB
  • Tags: CPython 3.10, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for npdatetime-0.2.2-cp310-cp310-win_amd64.whl
Algorithm Hash digest
SHA256 a0ea94cc453cc70a13288c90ff182bcfbc77c7ef1d7a3995b04b65453394ec2c
MD5 e4f6b5b8c7d1931e4fb071f5979e0ace
BLAKE2b-256 92a19b3e4062d859c29be2314f4b187f702605ba324d66af539275d657649dd2

See more details on using hashes here.

File details

Details for the file npdatetime-0.2.2-cp310-cp310-manylinux_2_34_x86_64.whl.

File metadata

File hashes

Hashes for npdatetime-0.2.2-cp310-cp310-manylinux_2_34_x86_64.whl
Algorithm Hash digest
SHA256 ae9f2214a3947f1f9c0dda6344258c15fbeb13abd65ae8fa69db77b754b976cc
MD5 505d837e9e901e7b127b8c31c8537cb1
BLAKE2b-256 53e5af6c8c01ca4b3a15177531edd0ee835e7f56abd5b97ceedf90d2915f35c3

See more details on using hashes here.

File details

Details for the file npdatetime-0.2.2-cp310-cp310-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for npdatetime-0.2.2-cp310-cp310-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 c67ba9eba8eb02c3282cd2e6dcbd5e7834aca0525e957c0a7143adc417d373b9
MD5 cfd4ed0c97bd507ea041d4f1015bace0
BLAKE2b-256 51b2e40754692e7d389a5c895427b4d416e062af3cfac62308b34ba4b05bf147

See more details on using hashes here.

File details

Details for the file npdatetime-0.2.2-cp39-cp39-win_amd64.whl.

File metadata

  • Download URL: npdatetime-0.2.2-cp39-cp39-win_amd64.whl
  • Upload date:
  • Size: 152.1 kB
  • Tags: CPython 3.9, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for npdatetime-0.2.2-cp39-cp39-win_amd64.whl
Algorithm Hash digest
SHA256 7cc9070ea5fc86d496d65408a3b310911720fae3f5a9f561789748f39e8d26d7
MD5 15198a7b7580c4cd06d2b916e9cb0e86
BLAKE2b-256 459d2f05467c9e42346e2ce9c18b2bec08be3678605441ee99794ae6affeb444

See more details on using hashes here.

File details

Details for the file npdatetime-0.2.2-cp39-cp39-manylinux_2_34_x86_64.whl.

File metadata

File hashes

Hashes for npdatetime-0.2.2-cp39-cp39-manylinux_2_34_x86_64.whl
Algorithm Hash digest
SHA256 784621c9b24711db3dfb5e1f7c2e97407e61024008eae1234400f27f2a2f0c89
MD5 db3c9895c74d77aee6432f9670fd1e5b
BLAKE2b-256 15d0f82b9f60893a952aaf1d55a634a3e550044120fef1b8f466b5461e4ed32e

See more details on using hashes here.

File details

Details for the file npdatetime-0.2.2-cp39-cp39-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for npdatetime-0.2.2-cp39-cp39-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 029d09c2a13b446da31e67976e5d3b2b31622c84b63cc85fe040dc52c8e836c4
MD5 5a808b78f5171f81930f40c06d952aa5
BLAKE2b-256 5be8e4fad82c84b08015e19f3dc2b6a5f28e2444e11606d6dec0260e59eaa91a

See more details on using hashes here.

File details

Details for the file npdatetime-0.2.2-cp38-cp38-win_amd64.whl.

File metadata

  • Download URL: npdatetime-0.2.2-cp38-cp38-win_amd64.whl
  • Upload date:
  • Size: 151.7 kB
  • Tags: CPython 3.8, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for npdatetime-0.2.2-cp38-cp38-win_amd64.whl
Algorithm Hash digest
SHA256 8393e3e4595dfde3c7b8f5c8517b34528f4d1d4c160c92e7fd07da238421792a
MD5 47c581a4cb7d45e2433d2c6e3bc9447b
BLAKE2b-256 77dd1c9b65897fc8362925047842f65cb2413af44b7622cda93ef2f4cc13dc51

See more details on using hashes here.

File details

Details for the file npdatetime-0.2.2-cp38-cp38-manylinux_2_34_x86_64.whl.

File metadata

File hashes

Hashes for npdatetime-0.2.2-cp38-cp38-manylinux_2_34_x86_64.whl
Algorithm Hash digest
SHA256 2c88e0f4d0addca0f2bb63e2dee140a04767e24cd776e641af4b52c776c15f98
MD5 e39325c8281477d42b95855fc6798432
BLAKE2b-256 c1fa7e98e0fb0df85ae4b7839e19a1d25d806d020a6bf715f8569a65368f3542

See more details on using hashes here.

File details

Details for the file npdatetime-0.2.2-cp38-cp38-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for npdatetime-0.2.2-cp38-cp38-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 47e3f1c5c51e6b1be9f27c8b2ae2676af851549ef055c1ac59d1d147a7c82437
MD5 d8a489e833b15ec8f4daf8a1ab3365eb
BLAKE2b-256 93bda0ae4bc193b144dcc37073efc1057b5dcc1f043c527f595b76c5d44c1ec5

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