persiantools
persiantools copied to clipboard
Jalali date and datetime with other tools
second m variable override the first m variable and this is make compare incorrect
updates: - [github.com/asottile/pyupgrade: v2.32.1 → v3.1.0](https://github.com/asottile/pyupgrade/compare/v2.32.1...v3.1.0) - [github.com/pre-commit/pre-commit-hooks: v4.2.0 → v4.3.0](https://github.com/pre-commit/pre-commit-hooks/compare/v4.2.0...v4.3.0) - [github.com/psf/black: 22.3.0 → 22.10.0](https://github.com/psf/black/compare/22.3.0...22.10.0) - [github.com/PyCQA/flake8: 4.0.1 → 5.0.4](https://github.com/PyCQA/flake8/compare/4.0.1...5.0.4)
due to https://docs.python.org/3/whatsnew/3.10.html#new-features-related-to-type-hints type hints can now be written in a more succinct manner (number: int | float) -> int | float
hi thanks for publishing this package please create and update `CHANGELOG` file
updates: - [github.com/asottile/pyupgrade: v3.15.1 → v3.15.2](https://github.com/asottile/pyupgrade/compare/v3.15.1...v3.15.2) - [github.com/pre-commit/pre-commit-hooks: v4.5.0 → v4.6.0](https://github.com/pre-commit/pre-commit-hooks/compare/v4.5.0...v4.6.0)
the method .fromisoformat in JalaliDateTime ignores the time and only parses the date component: ![image](https://github.com/majiidd/persiantools/assets/141560555/823b579f-24ca-411a-aed8-96db0ed8e518)
Hey. Code: ```python from django.utils import timezone JalaliDateTime.to_jalali(self.created_at, tzinfo=timezone.tzinfo).strftime('%d %B %Y - %H:%M', locale='fa') ``` Execption: ``` tzname(dt) argument must be a datetime instance or None, not JalaliDateTime ```
**wrong conversion in JalaliDate() (Gregorian to Jalali) on version 4.0.0** Hi my friend. Converting from **Gregorian** to **Jalali Date** in a specific date which has repeated every 4 years returns...
updates: - [github.com/asottile/pyupgrade: v3.15.1 → v3.15.2](https://github.com/asottile/pyupgrade/compare/v3.15.1...v3.15.2) - [github.com/pre-commit/pre-commit-hooks: v4.5.0 → v4.6.0](https://github.com/pre-commit/pre-commit-hooks/compare/v4.5.0...v4.6.0) - [github.com/psf/black: 24.3.0 → 24.4.2](https://github.com/psf/black/compare/24.3.0...24.4.2)