Skip to content

Deprecated classes JavalangImproved and Lines remain in the codebase#841

Merged
yegor256 merged 2 commits into
cqfn:masterfrom
KachanovYev:issue_834
Jul 3, 2025
Merged

Deprecated classes JavalangImproved and Lines remain in the codebase#841
yegor256 merged 2 commits into
cqfn:masterfrom
KachanovYev:issue_834

Conversation

@KachanovYev

@KachanovYev KachanovYev commented Jun 30, 2025

Copy link
Copy Markdown
Contributor

#834

remove Deprecated classes JavalangImproved and Lines

Summary by CodeRabbit

  • Refactor
    • Removed legacy Java AST parsing and line handling utilities, including related classes and methods.
  • Chores
    • Deleted deprecated utility files and associated test files.

@coderabbitai

coderabbitai Bot commented Jun 30, 2025

Copy link
Copy Markdown

Walkthrough

This change removes the deprecated JavalangImproved and Lines classes, their associated helper methods, and all related test files. The update eliminates AST traversal and Java source file reading utilities from the codebase, leaving only static structures and the ASTNode class in the parser module.

Changes

File(s) Change Summary
aibolit/utils/java_parser.py Removed JavalangImproved class, related imports, and all AST traversal and filtering logic.
aibolit/utils/lines.py Deleted file; removed the deprecated Lines class and its file reading and AST parsing logic.
test/utils/Lines/SimpleLinesTest.java Deleted Java test file for the Lines utility.
test/utils/Lines/test_lines.py Deleted Python unit test for the Lines class.
test/utils/Lines/init.py Deleted empty __init__ file with only license headers.

Possibly related issues

Poem

A hop, a skip, a tidy sweep,
Old classes gone, no need to weep.
The parser’s lighter, tests have flown,
Deprecated seeds are overgrown.
With every prune, our code can gleam—
A cleaner warren for the team!
🥕✨


📜 Recent review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 70d86b2 and 733682b.

📒 Files selected for processing (5)
  • aibolit/utils/java_parser.py (0 hunks)
  • aibolit/utils/lines.py (0 hunks)
  • test/utils/Lines/SimpleLinesTest.java (0 hunks)
  • test/utils/Lines/__init__.py (0 hunks)
  • test/utils/Lines/test_lines.py (0 hunks)
💤 Files with no reviewable changes (5)
  • test/utils/Lines/init.py
  • test/utils/Lines/SimpleLinesTest.java
  • test/utils/Lines/test_lines.py
  • aibolit/utils/lines.py
  • aibolit/utils/java_parser.py
⏰ Context from checks skipped due to timeout of 90000ms (4)
  • GitHub Check: pylint
  • GitHub Check: latexmk
  • GitHub Check: make
  • GitHub Check: e2e-test
✨ Finishing Touches
  • 📝 Generate Docstrings

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share
🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Explain this complex logic.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai explain this code block.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read src/utils.ts and explain its main purpose.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

Support

Need help? Create a ticket on our support page for assistance with any issues or questions.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (Invoked using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai generate docstrings to generate docstrings for this PR.
  • @coderabbitai generate sequence diagram to generate a sequence diagram of the changes in this PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

@ivanovmg ivanovmg left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Approved from my side

self.scope = scope # ID of scope this node belongs


class JavalangImproved:

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

@KachanovYev thank you for the PR!
@yegor256 this PR removes unused classes JavalangImproved and Lines, which are closely related.

@ivanovmg

ivanovmg commented Jul 3, 2025

Copy link
Copy Markdown
Contributor

@KachanovYev can you please resolve conflicts here?

# Conflicts:
#	aibolit/utils/java_parser.py
#	aibolit/utils/lines.py
@KachanovYev

Copy link
Copy Markdown
Contributor Author

@ivanovmg
please check

@ivanovmg

ivanovmg commented Jul 3, 2025

Copy link
Copy Markdown
Contributor

@yegor256 please have a look. This PR removes unused classes JavalangImproved and Lines, which are closely related.

@yegor256
yegor256 merged commit f65d15d into cqfn:master Jul 3, 2025
19 checks passed
@yegor256

yegor256 commented Jul 3, 2025

Copy link
Copy Markdown
Member

@KachanovYev thanks!

@0crat

0crat commented Jul 3, 2025

Copy link
Copy Markdown
Collaborator

@ivanovmg Hey there! 👋 Nice job on the review! You've snagged +4 points for this one. Here's the breakdown: +12 for being the author, -10 because there was only 1 comment (we love chatty reviews!), and +2 to keep you above the minimum. Your balance is now sitting pretty at +115. Keep up the great work, and remember, more comments could boost your points next time! 💪

@0crat

0crat commented Jul 3, 2025

Copy link
Copy Markdown
Collaborator

@KachanovYev Hey there, awesome job on your contribution! 🎉 You've snagged +16 points, which is pretty sweet. Remember, we award points for each review and hit-of-code, with some cool bonuses and deductions based on code size and review comments. Your current balance is +4 - keep the momentum going! Quality and speed are key, so keep those contributions rolling in. Looking forward to seeing more of your great work!

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.

4 participants