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

feat(dependencies): unified dependencies… #362

Conversation

kopekC
Copy link
Contributor

@kopekC kopekC commented Feb 7, 2025

Merge dependency-related methods to provide a unified interface:

  • Make dependencies a proxy property with optional depth parameter
  • Default to all dependencies (depth=None)
  • Support direct dependencies via depth=1
  • Maintain backward compatibility
  • Update move_symbol_to_file to use direct dependencies

Additional fixes:

  • Replace complex ternary with clear condition in _get_all_dependencies for better readability
  • Fix type annotations in Symbol class to remove invalid use of ...
  • All changes maintain backward compatibility

Link to Devin run: https://app.devin.ai/sessions/907c0762112047ffb4ff05f529f7195f
Requested by: [email protected]

@kopekC kopekC requested review from codegen-team and a team as code owners February 7, 2025 18:48
@kopekC kopekC requested review from rushilpatel0 and removed request for a team February 7, 2025 18:48
Copy link

codecov bot commented Feb 7, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

✅ All tests successful. No failed tests found.

Additional details and impacted files

@kopekC kopekC force-pushed the pujol-cg-10711-imlpement-codebaseget_symbol_dependenciessymbol-max_depth2 branch from 9f60333 to 41ef6b6 Compare February 7, 2025 23:14
@kopekC kopekC changed the title feat(codebase): Add get_symbol_dependencies method for traversing dep… feat(codebase): unified usages… Feb 10, 2025
@kopekC kopekC changed the title feat(codebase): unified usages… feat(dependencies): unified dependencies… Feb 10, 2025
src/codegen/sdk/core/interfaces/importable.py Outdated Show resolved Hide resolved
src/codegen/sdk/core/interfaces/importable.py Outdated Show resolved Hide resolved
src/codegen/sdk/core/interfaces/importable.py Outdated Show resolved Hide resolved
src/codegen/sdk/core/interfaces/importable.py Outdated Show resolved Hide resolved
Copy link
Contributor

@bagel897 bagel897 left a comment

Choose a reason for hiding this comment

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

Minor nit, otherwise looks pretty good!

src/codegen/sdk/core/interfaces/importable.py Outdated Show resolved Hide resolved
@kopekC kopekC merged commit 1a5d9ed into develop Feb 11, 2025
26 of 27 checks passed
@kopekC kopekC deleted the pujol-cg-10711-imlpement-codebaseget_symbol_dependenciessymbol-max_depth2 branch February 11, 2025 00:36
Copy link

🎉 This PR is included in version 0.7.0 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

Copy link

🎉 This PR is included in version 0.7.0 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

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