[ 
https://issues.apache.org/jira/browse/HADOOP-17513?focusedWorklogId=548153&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-548153
 ]

ASF GitHub Bot logged work on HADOOP-17513:
-------------------------------------------

                Author: ASF GitHub Bot
            Created on: 05/Feb/21 09:50
            Start Date: 05/Feb/21 09:50
    Worklog Time Spent: 10m 
      Work Description: aajisaka commented on a change in pull request #2678:
URL: https://github.com/apache/hadoop/pull/2678#discussion_r569975825



##########
File path: hadoop-build-tools/src/main/resources/checkstyle/checkstyle.xml
##########
@@ -121,7 +121,7 @@
         <!-- See http://checkstyle.sf.net/config_import.html -->
         <module name="IllegalImport">
           <property name="regexp" value="true"/>
-          <property name="illegalPkgs" value="^sun\.[^.]+, 
^com\.google\.common\.[^.]+"/>
+          <property name="illegalPkgs" value="sun, ^com\.google\.common"/>

Review comment:
       The `^` before com.google.common can be removed as well?
   ```suggestion
             <property name="illegalPkgs" value="sun, com\.google\.common"/>
   ```




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
[email protected]


Issue Time Tracking
-------------------

    Worklog Id:     (was: 548153)
    Time Spent: 1h 10m  (was: 1h)

> Checkstyle IllegalImport does not catch guava imports
> -----------------------------------------------------
>
>                 Key: HADOOP-17513
>                 URL: https://issues.apache.org/jira/browse/HADOOP-17513
>             Project: Hadoop Common
>          Issue Type: Bug
>            Reporter: Ahmed Hussein
>            Assignee: Ahmed Hussein
>            Priority: Major
>              Labels: pull-request-available
>             Fix For: 3.4.0
>
>          Time Spent: 1h 10m
>  Remaining Estimate: 0h
>
> Although YARN-10352 introduces {{guava iterator import}}, it was committed to 
> trunk without checkstyle errors.
> According to [IllegalImportCheck#setIllegalPkgs 
> |https://github.com/checkstyle/checkstyle/blob/master/src/main/java/com/puppycrawl/tools/checkstyle/checks/imports/IllegalImportCheck.java],
>  the packages regex should be the prefix of the package. The code 
> automatically append {{\.*}} to the regex.
> CC: [~aajisaka]
>  



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to