Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Release/1.13.0 #283

Merged
merged 52 commits into from
Jan 6, 2025
Merged

Release/1.13.0 #283

merged 52 commits into from
Jan 6, 2025

Conversation

danielfromearth
Copy link
Collaborator

@danielfromearth danielfromearth commented Jan 6, 2025

Release Checklist:

ncompare bot and others added 30 commits December 13, 2024 19:57
The Path() constructor already handles both str and Path types effectively.
Added a check to ensure the provided suffix starts with a dot (.), which is standard for file extensions.
This prevents the creation of invalid file paths with malformed suffixes (e.g., .txt vs txt).

Path(should_be_path).with_suffix(suffix) is directly applied, reducing the number of steps.
Combined checks for str, int, and tuple into a single isinstance call using a tuple of types.
This reduces redundancy, improves clarity and performance . The TypeError is preserved to handle unsupported types.

Added the correct return type (str).
This function is no longer needed.
The intersection() method can deal with arbitrary objects but it is not needed here since we coerce everything into a string.

The & operator works at a lower level and is faster and sufficient for strings
Improvements:

Avoid unnecessary double conversions to sets:
Previously, set(a_sorted) and set(b_sorted) were resorted. The optimized code directly converts sequence_a and sequence_b into sets for fast lookups, creates a union using the low level "|" operator and then creates a sorted set. Sorting is performed only once on the union of the sets (a_set | b_set), rather than sorting a_sorted, b_sorted, and their combined union separately.

Simplified membership checking:
The if conditions now directly check the presence of an item in the sets instead of redundant checks.

Removed unreachable error check:
The raise ValueError condition is unnecessary since all items in all_items are guaranteed to come from either a_set or b_set.

The input-output behavior remains consistent while achieving faster execution.
Readability and branching Improvements
Bumps the pip-dependencies group with 3 updates: [ruff](https://github.com/astral-sh/ruff), [mypy](https://github.com/python/mypy) and [mkdocs-material](https://github.com/squidfunk/mkdocs-material).


Updates `ruff` from 0.8.1 to 0.8.4
- [Release notes](https://github.com/astral-sh/ruff/releases)
- [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md)
- [Commits](astral-sh/ruff@0.8.1...0.8.4)

Updates `mypy` from 1.13.0 to 1.14.1
- [Changelog](https://github.com/python/mypy/blob/master/CHANGELOG.md)
- [Commits](python/mypy@v1.13.0...v1.14.1)

Updates `mkdocs-material` from 9.5.47 to 9.5.49
- [Release notes](https://github.com/squidfunk/mkdocs-material/releases)
- [Changelog](https://github.com/squidfunk/mkdocs-material/blob/master/CHANGELOG)
- [Commits](squidfunk/mkdocs-material@9.5.47...9.5.49)

---
updated-dependencies:
- dependency-name: ruff
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: pip-dependencies
- dependency-name: mypy
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: pip-dependencies
- dependency-name: mkdocs-material
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: pip-dependencies
...

Signed-off-by: dependabot[bot] <[email protected]>
…cies-afa35abde5

Bump the pip-dependencies group with 3 updates
@danielfromearth danielfromearth marked this pull request as ready for review January 6, 2025 15:53
@danielfromearth danielfromearth merged commit 9d301ca into main Jan 6, 2025
5 checks passed
@danielfromearth danielfromearth deleted the release/1.13.0 branch January 8, 2025 18:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

request to expand compatibility to general HDF files and compare with nc
2 participants