[BUG][code-analyzer] Potential PMD Issue: exclude-pattern in Referenced Ruleset Not Respected
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 4/5
- Thời gian dự kiến
- 3-5 ngày
- Mức phù hợp với người mới
- 35/100
- Loại issue
- Lỗi
- Độ rõ ràng
- Khá rõ ràng
- Mức độ hoạt động
- Đình trệ
- Lĩnh vực
- tooling
Hướng nghiên cứu
Bắt đầu bằng cách tái hiện quá trình quét với custom-ruleset.xml được cung cấp và công cụ PMD, kiểm tra xem ba mục exclude-pattern có được áp dụng khi các quy tắc được tham chiếu hay không. Được xem là hoàn tất khi các tệp có tiền tố fflib_ và TM không được xử lý, trong khi các quy tắc Apex được liệt kê vẫn chạy.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
I'm encountering an issue with configuring code-analyzer to exclude files with specific prefixes. This is for a Salesforce org repository, and I'm using the PMD engine with a custom custom-ruleset.xml file. Despite specifying the prefixes to be ignored, the scanner still seems to process those files. For example I want to exclude Apex classes that have a prefix of fflib_ or TM. This is what the custom-ruleset.xml file looks like:
<?xml version="1.0" encoding="UTF-8"?>
<ruleset name="Custom Apex Rules"
xmlns="http://pmd.sourceforge.net/ruleset/2.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://pmd.sourceforge.net/ruleset/2.0.0
https://pmd.sourceforge.io/ruleset_2_0_0.xsd">
<description>
PMD ruleset that excludes fflib-related and TM-prefixed classes and their metadata files.
</description>
<!-- Exclude patterns -->
<exclude-pattern>.*/fflib_.*\.(cls|trigger|cls-meta\.xml|trigger-meta\.xml)$</exclude-pattern>
<exclude-pattern>.*/fflib-.*/.*\.(cls|trigger|cls-meta\.xml|trigger-meta\.xml)$</exclude-pattern>
<exclude-pattern>.*/TM[^/]*\.(cls|trigger|cls-meta\.xml|trigger-meta\.xml)$</exclude-pattern>
<!-- Apex rules -->
<rule ref="category/apex/design.xml/CognitiveComplexity"/>
<rule ref="category/apex/bestpractices.xml/ApexUnitTestClassShouldHaveAsserts"/>
</ruleset>
Do you have any suggestions on what I might be missing? Thanks in advance for your help!
- Ngôn ngữ chính
- TypeScript
- Star
- 241
- Fork
- 51
- Chỉ số merge pull request
- Không có pull request nào được merge trong 30 ngày
Chuẩn bị môi trường
- Không có Dockerfile hay tệp Docker Compose
- Không có mẫu pull request
- Đọc hướng dẫn đóng góp
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của forcedotcom/code-analyzer
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
forcedotcom/code-analyzer#2094 ·
-
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 88/100
forcedotcom/code-analyzer#2093 ·
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 82/100
forcedotcom/code-analyzer#2091 ·
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 76/100
forcedotcom/code-analyzer#2090 ·
-
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 72/100
forcedotcom/code-analyzer#2104 ·
Tất cả issue của forcedotcom/code-analyzer
Issue tương tự
-
clawsweeper:fix-shape-clear clawsweeper:queueable-fix clawsweeper:source-repro impact:other issue-rating: 🦞 diamond lobster no-stale P2
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 72/100
openclaw/openclaw#168089 · 2 bình luận · 1 reaction ·
Maintainer thường phản hồi trong vòng 1 ngày
-
✨ enhancement needs-discussion
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 85/100
-
[Bug]: [MCP/CLI] Bare loopback IP addresses (127.0.0.1:port) and hosts with ports fail to navigate due to erroneous scheme inferenceCó thể đã có người làm @alok-108 đã nhận hôm nay. Đang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
microsoft/playwright#43263 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
area:studio type:security
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
Maintainer thường phản hồi trong vòng 1 ngày
-
enhancement good first issue Stellar Wave trivial
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 85/100
StellarCanary/ProtocolCanary-Action#331 ·
Maintainer thường phản hồi trong vòng 1 ngày