You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@superset.apache.org by GitBox <gi...@apache.org> on 2021/08/26 10:18:32 UTC

[GitHub] [superset] villebro opened a new pull request #16463: chore(ci): bump pylint to 2.10.2

villebro opened a new pull request #16463:
URL: https://github.com/apache/superset/pull/16463


   ### SUMMARY
   While working on an unrelated PR, I started getting weird linting errors from `pylint` that flip-flopped between
   
   ```
   pylint run-test: commands[0] | pylint superset
   ************* Module superset.models.slice
   superset/models/slice.py:56:0: R0902: Too many instance attributes (10/8) (too-many-instance-attributes)
   ************* Module superset.models.dashboard
   superset/models/dashboard.py:132:0: R0902: Too many instance attributes (9/8) (too-many-instance-attributes)
   ```
   
   and later when those were disabled
   
   ```
   pylint run-test: commands[0] | pylint superset
   ************* Module superset.models.slice
   superset/models/slice.py:56:0: I0021: Useless suppression of 'too-many-instance-attributes' (useless-suppression)
   ************* Module superset.models.dashboard
   superset/models/dashboard.py:132:0: I0021: Useless suppression of 'too-many-instance-attributes' (useless-suppression)
   ```
   
   I figured this might have been fixed in the most recent 2.10.2 release of `pylint`, but sadly that wasn't the case (same flip-flop). However, since I already did the necessary corrections for 2.10, I figure we might just as well bump anyway.
   
   ### BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF
   <!--- Skip this if not applicable -->
   
   ### TESTING INSTRUCTIONS
   <!--- Required! What steps can be taken to manually verify the changes? -->
   
   ### ADDITIONAL INFORMATION
   <!--- Check any relevant boxes with "x" -->
   <!--- HINT: Include "Fixes #nnn" if you are fixing an existing issue -->
   - [ ] Has associated issue:
   - [ ] Required feature flags:
   - [ ] Changes UI
   - [ ] Includes DB Migration (follow approval process in [SIP-59](https://github.com/apache/superset/issues/13351))
     - [ ] Migration is atomic, supports rollback & is backwards-compatible
     - [ ] Confirm DB migration upgrade and downgrade tested
     - [ ] Runtime estimates and downtime expectations provided
   - [ ] Introduces new feature or API
   - [ ] Removes existing feature or API
   


-- 
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.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [superset] villebro commented on a change in pull request #16463: chore(ci): bump pylint to 2.10.2

Posted by GitBox <gi...@apache.org>.
villebro commented on a change in pull request #16463:
URL: https://github.com/apache/superset/pull/16463#discussion_r696495797



##########
File path: .pylintrc
##########
@@ -86,6 +86,8 @@ disable=
     missing-docstring,
     too-many-lines,
     duplicate-code,
+    unspecified-encoding,

Review comment:
       I don't necessarily agree with this rule. While we could add `encoding="utf-8"` to all text file opens, this would likely break compatibility with Windows which defaults to `cp-1252`. Also, adding `encoding=locale.getpreferredencoding()` feels pointless. So I recommend we disable this rule for now.




-- 
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.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [superset] villebro commented on a change in pull request #16463: chore(ci): bump pylint to 2.10.2

Posted by GitBox <gi...@apache.org>.
villebro commented on a change in pull request #16463:
URL: https://github.com/apache/superset/pull/16463#discussion_r696501257



##########
File path: superset/annotation_layers/annotations/commands/create.py
##########
@@ -52,7 +52,7 @@ def run(self) -> Model:
         return annotation
 
     def validate(self) -> None:
-        exceptions: List[ValidationError] = list()
+        exceptions: List[ValidationError] = []

Review comment:
       Ok, this made me chuckle. I don't remember which linter and when, but didn't some linter up until fairly recently complain about using `[]` and recommend using `list()` instead? 😆  See `use-list-literal (R1734)` and `use-dict-literal (R1735)` in http://pylint.pycqa.org/en/latest/technical_reference/features.html




-- 
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.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [superset] villebro commented on a change in pull request #16463: chore(ci): bump pylint to 2.10.2

Posted by GitBox <gi...@apache.org>.
villebro commented on a change in pull request #16463:
URL: https://github.com/apache/superset/pull/16463#discussion_r696838933



##########
File path: superset/annotation_layers/annotations/api.py
##########
@@ -381,7 +381,7 @@ def put(  # pylint: disable=arguments-differ
         try:
             new_model = UpdateAnnotationCommand(g.user, annotation_id, item).run()
             return self.response(200, id=new_model.id, result=item)
-        except (AnnotationNotFoundError, AnnotationLayerNotFoundError) as ex:
+        except (AnnotationNotFoundError, AnnotationLayerNotFoundError):

Review comment:
       I was actually really surprised this wasn't caught by older versions




-- 
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.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [superset] villebro commented on a change in pull request #16463: chore(ci): bump pylint to 2.10.2

Posted by GitBox <gi...@apache.org>.
villebro commented on a change in pull request #16463:
URL: https://github.com/apache/superset/pull/16463#discussion_r696495797



##########
File path: .pylintrc
##########
@@ -86,6 +86,8 @@ disable=
     missing-docstring,
     too-many-lines,
     duplicate-code,
+    unspecified-encoding,

Review comment:
       I don't necessarily agree with this rule. While we could add `encoding="utf-8"` to all text file opens, this would likely break compatibility with Windows which defaults to `cp-1252` (not officially supported, but I know some parties in the community are running Superset on Windows). Also, adding `encoding=locale.getpreferredencoding()` feels pointless. So I recommend we disable this rule for now.




-- 
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.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [superset] villebro commented on a change in pull request #16463: chore(ci): bump pylint to 2.10.2

Posted by GitBox <gi...@apache.org>.
villebro commented on a change in pull request #16463:
URL: https://github.com/apache/superset/pull/16463#discussion_r696501257



##########
File path: superset/annotation_layers/annotations/commands/create.py
##########
@@ -52,7 +52,7 @@ def run(self) -> Model:
         return annotation
 
     def validate(self) -> None:
-        exceptions: List[ValidationError] = list()
+        exceptions: List[ValidationError] = []

Review comment:
       Ok, this made me chuckle. I don't remember which linter and when, but didn't some linter up until fairly recently complained about using `[]` and recommended using `list()` instead? 😆  See `use-list-literal (R1734)` and `use-dict-literal (R1735)` in http://pylint.pycqa.org/en/latest/technical_reference/features.html

##########
File path: superset/annotation_layers/annotations/commands/create.py
##########
@@ -52,7 +52,7 @@ def run(self) -> Model:
         return annotation
 
     def validate(self) -> None:
-        exceptions: List[ValidationError] = list()
+        exceptions: List[ValidationError] = []

Review comment:
       Ok, this made me chuckle. I don't remember which linter and when, but didn't some linter up until fairly recently complain about using `[]` and recommend using `list()` instead? 😆  See `use-list-literal (R1734)` and `use-dict-literal (R1735)` in http://pylint.pycqa.org/en/latest/technical_reference/features.html




-- 
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.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [superset] villebro merged pull request #16463: chore(ci): bump pylint to 2.10.2

Posted by GitBox <gi...@apache.org>.
villebro merged pull request #16463:
URL: https://github.com/apache/superset/pull/16463


   


-- 
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.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [superset] codecov[bot] commented on pull request #16463: chore(ci): bump pylint to 2.10.2

Posted by GitBox <gi...@apache.org>.
codecov[bot] commented on pull request #16463:
URL: https://github.com/apache/superset/pull/16463#issuecomment-906291846


   # [Codecov](https://codecov.io/gh/apache/superset/pull/16463?src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) Report
   > Merging [#16463](https://codecov.io/gh/apache/superset/pull/16463?src=pr&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) (bfcea63) into [master](https://codecov.io/gh/apache/superset/commit/18be181946a3e5b7e651dde7a3e5fec46504dd08?el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) (18be181) will **decrease** coverage by `0.24%`.
   > The diff coverage is `77.77%`.
   
   > :exclamation: Current head bfcea63 differs from pull request most recent head 0563634. Consider uploading reports for the commit 0563634 to get more accurate results
   [![Impacted file tree graph](https://codecov.io/gh/apache/superset/pull/16463/graphs/tree.svg?width=650&height=150&src=pr&token=KsB0fHcx6l&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)](https://codecov.io/gh/apache/superset/pull/16463?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
   
   ```diff
   @@            Coverage Diff             @@
   ##           master   #16463      +/-   ##
   ==========================================
   - Coverage   76.63%   76.38%   -0.25%     
   ==========================================
     Files        1002     1002              
     Lines       53637    53639       +2     
     Branches     6853     6854       +1     
   ==========================================
   - Hits        41104    40972     -132     
   - Misses      12294    12428     +134     
     Partials      239      239              
   ```
   
   | Flag | Coverage Δ | |
   |---|---|---|
   | hive | `?` | |
   | mysql | `?` | |
   | postgres | `81.55% <86.20%> (-0.04%)` | :arrow_down: |
   | presto | `?` | |
   | python | `81.59% <86.20%> (-0.52%)` | :arrow_down: |
   | sqlite | `81.19% <82.14%> (ø)` | |
   
   Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#carryforward-flags-in-the-pull-request-comment) to find out more.
   
   | [Impacted Files](https://codecov.io/gh/apache/superset/pull/16463?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) | Coverage Δ | |
   |---|---|---|
   | [...perset-frontend/src/explore/components/Control.tsx](https://codecov.io/gh/apache/superset/pull/16463/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2V4cGxvcmUvY29tcG9uZW50cy9Db250cm9sLnRzeA==) | `76.47% <ø> (ø)` | |
   | [...-frontend/src/explore/components/ControlHeader.jsx](https://codecov.io/gh/apache/superset/pull/16463/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2V4cGxvcmUvY29tcG9uZW50cy9Db250cm9sSGVhZGVyLmpzeA==) | `86.20% <ø> (ø)` | |
   | [superset-frontend/src/views/CRUD/types.ts](https://codecov.io/gh/apache/superset/pull/16463/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL3ZpZXdzL0NSVUQvdHlwZXMudHM=) | `100.00% <ø> (ø)` | |
   | [superset/views/base\_schemas.py](https://codecov.io/gh/apache/superset/pull/16463/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c3VwZXJzZXQvdmlld3MvYmFzZV9zY2hlbWFzLnB5) | `0.00% <0.00%> (ø)` | |
   | [...ontrols/DndColumnSelectControl/DndMetricSelect.tsx](https://codecov.io/gh/apache/superset/pull/16463/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2V4cGxvcmUvY29tcG9uZW50cy9jb250cm9scy9EbmRDb2x1bW5TZWxlY3RDb250cm9sL0RuZE1ldHJpY1NlbGVjdC50c3g=) | `40.88% <20.00%> (-0.53%)` | :arrow_down: |
   | [superset/annotation\_layers/annotations/api.py](https://codecov.io/gh/apache/superset/pull/16463/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c3VwZXJzZXQvYW5ub3RhdGlvbl9sYXllcnMvYW5ub3RhdGlvbnMvYXBpLnB5) | `84.96% <50.00%> (ø)` | |
   | [superset/utils/dict\_import\_export.py](https://codecov.io/gh/apache/superset/pull/16463/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c3VwZXJzZXQvdXRpbHMvZGljdF9pbXBvcnRfZXhwb3J0LnB5) | `75.00% <50.00%> (ø)` | |
   | [superset/tasks/async\_queries.py](https://codecov.io/gh/apache/superset/pull/16463/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c3VwZXJzZXQvdGFza3MvYXN5bmNfcXVlcmllcy5weQ==) | `96.77% <66.66%> (ø)` | |
   | [...d/src/explore/components/DatasourcePanel/index.tsx](https://codecov.io/gh/apache/superset/pull/16463/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2V4cGxvcmUvY29tcG9uZW50cy9EYXRhc291cmNlUGFuZWwvaW5kZXgudHN4) | `73.95% <69.23%> (ø)` | |
   | [...ontrols/DndColumnSelectControl/DndColumnSelect.tsx](https://codecov.io/gh/apache/superset/pull/16463/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2V4cGxvcmUvY29tcG9uZW50cy9jb250cm9scy9EbmRDb2x1bW5TZWxlY3RDb250cm9sL0RuZENvbHVtblNlbGVjdC50c3g=) | `47.56% <100.00%> (ø)` | |
   | ... and [35 more](https://codecov.io/gh/apache/superset/pull/16463/diff?src=pr&el=tree-more&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) | |
   
   ------
   
   [Continue to review full report at Codecov](https://codecov.io/gh/apache/superset/pull/16463?src=pr&el=continue&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation).
   > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
   > `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
   > Powered by [Codecov](https://codecov.io/gh/apache/superset/pull/16463?src=pr&el=footer&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation). Last update [18be181...0563634](https://codecov.io/gh/apache/superset/pull/16463?src=pr&el=lastupdated&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation).
   


-- 
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.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [superset] villebro commented on a change in pull request #16463: chore(ci): bump pylint to 2.10.2

Posted by GitBox <gi...@apache.org>.
villebro commented on a change in pull request #16463:
URL: https://github.com/apache/superset/pull/16463#discussion_r696497216



##########
File path: requirements/testing.in
##########
@@ -28,7 +28,7 @@ openpyxl
 parameterized
 pyfakefs
 pyhive[presto]>=0.6.3
-pylint==2.6.0
+pylint==2.10.2

Review comment:
       it appears this hadn't been bumped to `pylint==2.9.6` when the bump was to made in `testing.txt` in the previous bump PR




-- 
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.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [superset] villebro commented on a change in pull request #16463: chore(ci): bump pylint to 2.10.2

Posted by GitBox <gi...@apache.org>.
villebro commented on a change in pull request #16463:
URL: https://github.com/apache/superset/pull/16463#discussion_r696495797



##########
File path: .pylintrc
##########
@@ -86,6 +86,8 @@ disable=
     missing-docstring,
     too-many-lines,
     duplicate-code,
+    unspecified-encoding,

Review comment:
       I don't necessarily agree with this. While we could add `encoding="utf-8"` to all text file opens, this would likely break compatibility with Windows which defaults to `cp-1252`. Also, adding `encoding=locale.getpreferredencoding()` feels pointless. So I recommend we disable this rule for now.




-- 
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.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [superset] villebro commented on a change in pull request #16463: chore(ci): bump pylint to 2.10.2

Posted by GitBox <gi...@apache.org>.
villebro commented on a change in pull request #16463:
URL: https://github.com/apache/superset/pull/16463#discussion_r696495797



##########
File path: .pylintrc
##########
@@ -86,6 +86,8 @@ disable=
     missing-docstring,
     too-many-lines,
     duplicate-code,
+    unspecified-encoding,

Review comment:
       I don't necessarily agree with this. While we could add `encoding="utf-8"` to all text file opens, this would likely break compatibility with Windows which defaults to `cp-1252`. So I recommend we disable this rule for now.




-- 
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.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [superset] john-bodley commented on a change in pull request #16463: chore(ci): bump pylint to 2.10.2

Posted by GitBox <gi...@apache.org>.
john-bodley commented on a change in pull request #16463:
URL: https://github.com/apache/superset/pull/16463#discussion_r696834834



##########
File path: superset/annotation_layers/annotations/api.py
##########
@@ -381,7 +381,7 @@ def put(  # pylint: disable=arguments-differ
         try:
             new_model = UpdateAnnotationCommand(g.user, annotation_id, item).run()
             return self.response(200, id=new_model.id, result=item)
-        except (AnnotationNotFoundError, AnnotationLayerNotFoundError) as ex:
+        except (AnnotationNotFoundError, AnnotationLayerNotFoundError):

Review comment:
       I'm always happy to see Pylint is continuing to evolve it's logic.

##########
File path: superset/tasks/async_queries.py
##########
@@ -68,7 +68,7 @@ def load_chart_data_into_cache(
         raise exc
     except Exception as exc:
         # TODO: QueryContext should support SIP-40 style errors
-        error = exc.message if hasattr(exc, "message") else str(exc)  # type: ignore # pylint: disable=no-member
+        error = exc.message if hasattr(exc, "message") else str(exc)  # type: ignore

Review comment:
       @villebro as a side note I might do a pass to remain `exc` to `ex` for consistency throughout the code.




-- 
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.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [superset] villebro commented on a change in pull request #16463: chore(ci): bump pylint to 2.10.2

Posted by GitBox <gi...@apache.org>.
villebro commented on a change in pull request #16463:
URL: https://github.com/apache/superset/pull/16463#discussion_r696501257



##########
File path: superset/annotation_layers/annotations/commands/create.py
##########
@@ -52,7 +52,7 @@ def run(self) -> Model:
         return annotation
 
     def validate(self) -> None:
-        exceptions: List[ValidationError] = list()
+        exceptions: List[ValidationError] = []

Review comment:
       Ok, this made me chuckle. I don't remember which linter and when, but didn't some linter up until fairly recently complain about using `[]` and recommend using `list()` instead? 😆  See `use-list-literal (R1734)` and `use-dict-literal (R1735)` in http://pylint.pycqa.org/en/latest/technical_reference/features.html
   (FYI: I much prefer `[]` and `{}` over `list()` and `dict()` respectively, so I'm really happy about this change)




-- 
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.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [superset] villebro commented on a change in pull request #16463: chore(ci): bump pylint to 2.10.2

Posted by GitBox <gi...@apache.org>.
villebro commented on a change in pull request #16463:
URL: https://github.com/apache/superset/pull/16463#discussion_r696497216



##########
File path: requirements/testing.in
##########
@@ -28,7 +28,7 @@ openpyxl
 parameterized
 pyfakefs
 pyhive[presto]>=0.6.3
-pylint==2.6.0
+pylint==2.10.2

Review comment:
       it appears this hadn't been bumped to `pylint==2.9.6` when the bump was to made in `testing.txt` in the previous bump PR




-- 
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.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [superset] villebro commented on a change in pull request #16463: chore(ci): bump pylint to 2.10.2

Posted by GitBox <gi...@apache.org>.
villebro commented on a change in pull request #16463:
URL: https://github.com/apache/superset/pull/16463#discussion_r696497216



##########
File path: requirements/testing.in
##########
@@ -28,7 +28,7 @@ openpyxl
 parameterized
 pyfakefs
 pyhive[presto]>=0.6.3
-pylint==2.6.0
+pylint==2.10.2

Review comment:
       it appears this hadn't been bumped to `pylint==2.9.6` when the bump was made in `testing.txt`




-- 
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.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org