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

[apex] Merge main (7.x) branch into experimental-apex-parser and fix tests #4479

Merged

Conversation

aaronhurst-google
Copy link
Contributor

@aaronhurst-google aaronhurst-google commented Apr 18, 2023

Part of #3766

Merge main (7.x) branch into experimental-apex-parser and fix tests.

Conflict resolution and fixes include:
* Create root ASTApexFile nodes
* Correct source locations
* Insert comments by offset rather than line/column, using more of the mainline code
* Removed some unused methods
* Suppress Summit logger INFO output
* Suppress some (but not all) ANTLR version mismatch output
* Replace ASTFormalComment.getToken() with getImage()
* Remove deleted APIs: getLocation, hasSuppressWarningsAnnotationsFor, getModifiers
* Remove code that was factored into BaseApexClass
* Replace all references to Jorje in rules
* Passing AbstractApexNode instead of ApexNode during tree building
* Extending and using TextFileContent to convert line+column (as is native in Summit) to offset
* Using the new visitor method and interface
* Replace ApexRootNode with BaseApexClass
* Remove AbstractApexNodeBase

@pmd-test
Copy link

pmd-test commented Apr 18, 2023

2 Messages
📖 Compared to experimental-apex-parser:
This changeset changes 51685 violations,
introduces 33757 new violations, 15 new errors and 0 new configuration errors,
removes 142077 violations, 4 errors and 0 configuration errors.
Download full report as build artifact
📖 Compared to master:
This changeset changes 12 violations,
introduces 6 new violations, 5 new errors and 0 new configuration errors,
removes 23 violations, 0 errors and 0 configuration errors.
Download full report as build artifact
Compared to experimental-apex-parser:
This changeset changes 0 violations,
introduces 669266 new violations, 30 new errors and 7 new configuration errors,
removes 0 violations, 0 errors and 0 configuration errors.
Download full report as build artifact
Compared to master:
This changeset changes 11 violations,
introduces 5 new violations, 5 new errors and 0 new configuration errors,
removes 22 violations, 0 errors and 0 configuration errors.
Download full report as build artifact
Compared to experimental-apex-parser:
This changeset changes 0 violations,
introduces 669145 new violations, 33 new errors and 7 new configuration errors,
removes 0 violations, 0 errors and 0 configuration errors.
Download full report as build artifact
Compared to master:
This changeset changes 10 violations,
introduces 5 new violations, 8 new errors and 0 new configuration errors,
removes 143 violations, 0 errors and 0 configuration errors.
Download full report as build artifact
Compared to experimental-apex-parser:
This changeset changes 51616 violations,
introduces 34688 new violations, 12 new errors and 0 new configuration errors,
removes 142030 violations, 4 errors and 7 configuration errors.
Full report
Compared to master:
This changeset changes 17 violations,
introduces 6 new violations, 2 new errors and 0 new configuration errors,
removes 18 violations, 0 errors and 0 configuration errors.
Full report

Generated by 🚫 Danger

@adangel adangel self-assigned this Apr 25, 2023
adangel and others added 28 commits May 5, 2023 15:46
This avoids having spaces in the possible values. E.g. MEDIUM_HIGH instead of Medium High.
- Update bootstrap, jquery, datatables
- Optimize styling
- Add param lines for cpdhtml.xslt
[cpd] New XML to HTML XLST report format for PMD CPD pmd#4426
[coco] CPD: Coco support for code duplication detection pmd#4431
@adangel
Copy link
Member

adangel commented Sep 11, 2023

A bit more useful is this view: master...aaronhurst-google:pmd:experimental-apex-parser - which doesn't contain the changes of pmd/7.0.x.

Or here are the single commits to be reviewed:

Copy link
Member

@adangel adangel left a comment

Choose a reason for hiding this comment

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

Sorry that it took so long...

I'm continuing later this week and see, whether it still builds...

@adangel
Copy link
Member

adangel commented Sep 22, 2023

I'm going to merge this now into the exeperimental-apex-parser branch.

There are still some things to look at, as the regression tester shows some new errors and differences:

Errors:

Stacktrace
Caused by: java.lang.NullPointerException
	at net.sourceforge.pmd.lang.apex.rule.errorprone.AvoidNonExistentAnnotationsRule.checkForNonExistentAnnotation(AvoidNonExistentAnnotationsRule.java:62)
	at net.sourceforge.pmd.lang.apex.rule.errorprone.AvoidNonExistentAnnotationsRule.visit(AvoidNonExistentAnnotationsRule.java:58)
	at net.sourceforge.pmd.lang.apex.ast.ASTField.acceptApexVisitor(ASTField.java:42)
	at net.sourceforge.pmd.lang.apex.ast.AbstractApexNode.acceptVisitor(AbstractApexNode.java:127)
	at net.sourceforge.pmd.lang.apex.ast.ApexParserVisitor.visitNode(ApexParserVisitor.java:17)
	at net.sourceforge.pmd.lang.apex.ast.ApexParserVisitor.visit(ApexParserVisitor.java:24)
	at net.sourceforge.pmd.lang.apex.ast.ApexParserVisitor.visitApexNode(ApexParserVisitor.java:29)
	at net.sourceforge.pmd.lang.apex.ast.ApexVisitor.visit(ApexVisitor.java:352)
	at net.sourceforge.pmd.lang.apex.rule.errorprone.AvoidNonExistentAnnotationsRule.visit(AvoidNonExistentAnnotationsRule.java:42)
	at net.sourceforge.pmd.lang.apex.ast.ASTUserEnum.acceptApexVisitor(ASTUserEnum.java:18)
	at net.sourceforge.pmd.lang.apex.ast.AbstractApexNode.acceptVisitor(AbstractApexNode.java:127)
	at net.sourceforge.pmd.lang.apex.ast.ApexParserVisitor.visitNode(ApexParserVisitor.java:17)
	at net.sourceforge.pmd.lang.apex.ast.ApexParserVisitor.visit(ApexParserVisitor.java:24)
	at net.sourceforge.pmd.lang.apex.ast.ApexParserVisitor.visitApexNode(ApexParserVisitor.java:29)
	at net.sourceforge.pmd.lang.apex.ast.ApexVisitor.visit(ApexVisitor.java:344)
	at net.sourceforge.pmd.lang.apex.rule.errorprone.AvoidNonExistentAnnotationsRule.visit(AvoidNonExistentAnnotationsRule.java:30)
	at net.sourceforge.pmd.lang.apex.ast.ASTUserClass.acceptApexVisitor(ASTUserClass.java:21)
	at net.sourceforge.pmd.lang.apex.ast.AbstractApexNode.acceptVisitor(AbstractApexNode.java:127)
	at net.sourceforge.pmd.lang.apex.ast.ApexParserVisitor.visitNode(ApexParserVisitor.java:17)
	at net.sourceforge.pmd.lang.apex.ast.ApexVisitor.visit(ApexVisitor.java:20)
	at net.sourceforge.pmd.lang.apex.ast.ASTApexFile.acceptApexVisitor(ASTApexFile.java:61)
	at net.sourceforge.pmd.lang.apex.ast.AbstractApexNode.acceptVisitor(AbstractApexNode.java:127)
	at net.sourceforge.pmd.lang.apex.rule.AbstractApexRule.apply(AbstractApexRule.java:17)
	at net.sourceforge.pmd.lang.rule.AbstractDelegateRule.apply(AbstractDelegateRule.java:232)
	at net.sourceforge.pmd.lang.rule.internal.RuleApplicator.applyOnIndex(RuleApplicator.java:75)
	... 9 more

Rule changes:

Otherwise it looks pretty promising to replace Jorje soon...

@adangel adangel merged commit 93d3d73 into pmd:experimental-apex-parser Sep 22, 2023
3 checks passed
@adangel adangel mentioned this pull request Sep 22, 2023
4 tasks
@adangel adangel changed the title Merge main (7.x) branch into experimental-apex-parser and fix tests [apex] Merge main (7.x) branch into experimental-apex-parser and fix tests Feb 13, 2024
@adangel adangel added this to the 7.0.0 milestone Feb 13, 2024
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.

None yet

10 participants