Skip to content

Conversation

Jay-ju
Copy link
Contributor

@Jay-ju Jay-ju commented Jul 24, 2025

Changes Made

When I develop the connectors for daft and lance simultaneously, I debug the code in the same venv environment. At this time, it seems that when formatting, lance is regarded as daft's own implementation. So, I've clarified the isort rules for formatting here.

This PR Before:
image

This PR After:
image

Related Issues

Checklist

  • Documented in API Docs (if applicable)
  • Documented in User Guide (if applicable)
  • If adding a new documentation page, doc is added to docs/mkdocs.yml navigation
  • Documentation builds and is formatted properly (tag @/ccmao1130 for docs review)

@github-actions github-actions bot added the chore label Jul 24, 2025
Copy link
Contributor

@greptile-apps greptile-apps bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Greptile Summary

This PR adds explicit import sorting configuration to the .ruff.toml file to resolve formatting inconsistencies when developing Daft and Lance packages simultaneously. The change adds two new lines to the [tool.ruff.lint.isort] section: known-first-party = ["daft"] and known-third-party = ["lance"].

The issue arises because when both Daft and Lance are installed in the same development environment, the isort tool (used by Ruff for import formatting) can become confused about whether Lance imports should be treated as first-party (internal to the project) or third-party (external dependencies). Without explicit configuration, isort may incorrectly group Lance imports with Daft's own modules, leading to inconsistent import ordering.

This configuration change integrates well with Daft's existing code quality infrastructure. The repository already uses Ruff for linting and formatting (as evidenced by the existing .ruff.toml configuration file), and this change simply extends that configuration to handle edge cases in import sorting. The fix follows standard Python development practices for managing import organization in projects that work closely with related packages.

Confidence score: 5/5

  • This is an extremely safe change that only affects code formatting and has zero functional impact
  • The configuration follows standard isort practices and addresses a legitimate development workflow issue
  • No files need additional attention as this is a simple configuration change

1 file reviewed, no comments

Edit Code Review Bot Settings | Greptile

Copy link

codecov bot commented Jul 24, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 78.55%. Comparing base (6ef8e52) to head (f6a6e3a).
⚠️ Report is 44 commits behind head on main.

Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##             main    #4840      +/-   ##
==========================================
- Coverage   78.84%   78.55%   -0.29%     
==========================================
  Files         890      890              
  Lines      123743   123945     +202     
==========================================
- Hits        97559    97364     -195     
- Misses      26184    26581     +397     

see 23 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@Jay-ju Jay-ju force-pushed the isort_third_party branch from eb499b5 to f6a6e3a Compare July 24, 2025 08:05
@universalmind303 universalmind303 merged commit dd74257 into Eventual-Inc:main Aug 6, 2025
44 of 45 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants