[jira] [Work logged] (BEAM-9579) ApproximateQuantilesCombineFn uses deprecated '-' operator
[ https://issues.apache.org/jira/browse/BEAM-9579?focusedWorklogId=409804&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-409804 ] ASF GitHub Bot logged work on BEAM-9579: Author: ASF GitHub Bot Created on: 25/Mar/20 20:36 Start Date: 25/Mar/20 20:36 Worklog Time Spent: 10m Work Description: amaliujia commented on pull request #11204: [BEAM-9579] Fix numpy logic operators URL: https://github.com/apache/beam/pull/11204#discussion_r398151570 ## File path: CHANGES.md ## @@ -116,6 +116,7 @@ ## Bugfixes +* Fixed numpy operators in ApproximateQuantiles (Python) ([BEAM-9579](https://issues.apache.org/jira/browse/BEAM-9579)). Review comment: Yep. Release branch cut is a good cut point. Later when if there is blocker JIRA that adds changes to release branch, release manager can ask to add something to `changes.md`. 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: us...@infra.apache.org Issue Time Tracking --- Worklog Id: (was: 409804) Time Spent: 1.5h (was: 1h 20m) > ApproximateQuantilesCombineFn uses deprecated '-' operator > -- > > Key: BEAM-9579 > URL: https://issues.apache.org/jira/browse/BEAM-9579 > Project: Beam > Issue Type: Bug > Components: sdk-py-core >Reporter: Chris Gorgolewski >Priority: Minor > Time Spent: 1.5h > Remaining Estimate: 0h > > This causes a TypeError with numpy 1.16.4 > > {{apache_beam/transforms/stats.py", line 437, in }} > {{ else (a > b) - (a < b)}} > {{TypeError: numpy boolean subtract, the `-` operator, is deprecated, use the > bitwise_xor, the `^` operator, or the logical_xor function instead.}} -- This message was sent by Atlassian Jira (v8.3.4#803005)
[jira] [Work logged] (BEAM-9579) ApproximateQuantilesCombineFn uses deprecated '-' operator
[ https://issues.apache.org/jira/browse/BEAM-9579?focusedWorklogId=409805&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-409805 ] ASF GitHub Bot logged work on BEAM-9579: Author: ASF GitHub Bot Created on: 25/Mar/20 20:36 Start Date: 25/Mar/20 20:36 Worklog Time Spent: 10m Work Description: amaliujia commented on pull request #11204: [BEAM-9579] Fix numpy logic operators URL: https://github.com/apache/beam/pull/11204#discussion_r398151570 ## File path: CHANGES.md ## @@ -116,6 +116,7 @@ ## Bugfixes +* Fixed numpy operators in ApproximateQuantiles (Python) ([BEAM-9579](https://issues.apache.org/jira/browse/BEAM-9579)). Review comment: Yep. Release branch cut is a good cut point. Later when there is blocker JIRA that adds changes to release branch, release manager can ask to add something to `changes.md`. 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: us...@infra.apache.org Issue Time Tracking --- Worklog Id: (was: 409805) Time Spent: 1h 40m (was: 1.5h) > ApproximateQuantilesCombineFn uses deprecated '-' operator > -- > > Key: BEAM-9579 > URL: https://issues.apache.org/jira/browse/BEAM-9579 > Project: Beam > Issue Type: Bug > Components: sdk-py-core >Reporter: Chris Gorgolewski >Priority: Minor > Time Spent: 1h 40m > Remaining Estimate: 0h > > This causes a TypeError with numpy 1.16.4 > > {{apache_beam/transforms/stats.py", line 437, in }} > {{ else (a > b) - (a < b)}} > {{TypeError: numpy boolean subtract, the `-` operator, is deprecated, use the > bitwise_xor, the `^` operator, or the logical_xor function instead.}} -- This message was sent by Atlassian Jira (v8.3.4#803005)
[jira] [Work logged] (BEAM-9579) ApproximateQuantilesCombineFn uses deprecated '-' operator
[ https://issues.apache.org/jira/browse/BEAM-9579?focusedWorklogId=409803&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-409803 ] ASF GitHub Bot logged work on BEAM-9579: Author: ASF GitHub Bot Created on: 25/Mar/20 20:34 Start Date: 25/Mar/20 20:34 Worklog Time Spent: 10m Work Description: amaliujia commented on pull request #11204: [BEAM-9579] Fix numpy logic operators URL: https://github.com/apache/beam/pull/11204#discussion_r398151570 ## File path: CHANGES.md ## @@ -116,6 +116,7 @@ ## Bugfixes +* Fixed numpy operators in ApproximateQuantiles (Python) ([BEAM-9579](https://issues.apache.org/jira/browse/BEAM-9579)). Review comment: Yep. Release branch is cut is a good cut point. Later when if there is blocker JIRA that adds changes to release branch, release manager can ask to add something to `changes.md`. 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: us...@infra.apache.org Issue Time Tracking --- Worklog Id: (was: 409803) Time Spent: 1h 20m (was: 1h 10m) > ApproximateQuantilesCombineFn uses deprecated '-' operator > -- > > Key: BEAM-9579 > URL: https://issues.apache.org/jira/browse/BEAM-9579 > Project: Beam > Issue Type: Bug > Components: sdk-py-core >Reporter: Chris Gorgolewski >Priority: Minor > Time Spent: 1h 20m > Remaining Estimate: 0h > > This causes a TypeError with numpy 1.16.4 > > {{apache_beam/transforms/stats.py", line 437, in }} > {{ else (a > b) - (a < b)}} > {{TypeError: numpy boolean subtract, the `-` operator, is deprecated, use the > bitwise_xor, the `^` operator, or the logical_xor function instead.}} -- This message was sent by Atlassian Jira (v8.3.4#803005)
[jira] [Work logged] (BEAM-9579) ApproximateQuantilesCombineFn uses deprecated '-' operator
[ https://issues.apache.org/jira/browse/BEAM-9579?focusedWorklogId=409069&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-409069 ] ASF GitHub Bot logged work on BEAM-9579: Author: ASF GitHub Bot Created on: 24/Mar/20 20:19 Start Date: 24/Mar/20 20:19 Worklog Time Spent: 10m Work Description: aaltay commented on pull request #11204: [BEAM-9579] Fix numpy logic operators URL: https://github.com/apache/beam/pull/11204 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: us...@infra.apache.org Issue Time Tracking --- Worklog Id: (was: 409069) Time Spent: 1h 10m (was: 1h) > ApproximateQuantilesCombineFn uses deprecated '-' operator > -- > > Key: BEAM-9579 > URL: https://issues.apache.org/jira/browse/BEAM-9579 > Project: Beam > Issue Type: Bug > Components: sdk-py-core >Reporter: Chris Gorgolewski >Priority: Minor > Time Spent: 1h 10m > Remaining Estimate: 0h > > This causes a TypeError with numpy 1.16.4 > > {{apache_beam/transforms/stats.py", line 437, in }} > {{ else (a > b) - (a < b)}} > {{TypeError: numpy boolean subtract, the `-` operator, is deprecated, use the > bitwise_xor, the `^` operator, or the logical_xor function instead.}} -- This message was sent by Atlassian Jira (v8.3.4#803005)
[jira] [Work logged] (BEAM-9579) ApproximateQuantilesCombineFn uses deprecated '-' operator
[ https://issues.apache.org/jira/browse/BEAM-9579?focusedWorklogId=409020&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-409020 ] ASF GitHub Bot logged work on BEAM-9579: Author: ASF GitHub Bot Created on: 24/Mar/20 18:49 Start Date: 24/Mar/20 18:49 Worklog Time Spent: 10m Work Description: aaltay commented on issue #11204: [BEAM-9579] Fix numpy logic operators URL: https://github.com/apache/beam/pull/11204#issuecomment-603441452 LGTM, I can merge after tests pass. 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: us...@infra.apache.org Issue Time Tracking --- Worklog Id: (was: 409020) Time Spent: 1h (was: 50m) > ApproximateQuantilesCombineFn uses deprecated '-' operator > -- > > Key: BEAM-9579 > URL: https://issues.apache.org/jira/browse/BEAM-9579 > Project: Beam > Issue Type: Bug > Components: sdk-py-core >Reporter: Chris Gorgolewski >Priority: Minor > Time Spent: 1h > Remaining Estimate: 0h > > This causes a TypeError with numpy 1.16.4 > > {{apache_beam/transforms/stats.py", line 437, in }} > {{ else (a > b) - (a < b)}} > {{TypeError: numpy boolean subtract, the `-` operator, is deprecated, use the > bitwise_xor, the `^` operator, or the logical_xor function instead.}} -- This message was sent by Atlassian Jira (v8.3.4#803005)
[jira] [Work logged] (BEAM-9579) ApproximateQuantilesCombineFn uses deprecated '-' operator
[ https://issues.apache.org/jira/browse/BEAM-9579?focusedWorklogId=409007&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-409007 ] ASF GitHub Bot logged work on BEAM-9579: Author: ASF GitHub Bot Created on: 24/Mar/20 18:36 Start Date: 24/Mar/20 18:36 Worklog Time Spent: 10m Work Description: chrisgorgo commented on pull request #11204: [BEAM-9579] Fix numpy logic operators URL: https://github.com/apache/beam/pull/11204#discussion_r397377585 ## File path: sdks/python/apache_beam/transforms/stats.py ## @@ -430,11 +430,11 @@ class ApproximateQuantilesCombineFn(CombineFn): def __init__( self, num_quantiles, buffer_size, num_buffers, key=None, reverse=False): if key: - self._comparator = lambda a, b: (key(a) < key(b)) - (key(a) > key(b)) \ -if reverse else (key(a) > key(b)) - (key(a) < key(b)) + self._comparator = lambda a, b: (key(a) < key(b)) ^ (key(a) > key(b)) \ Review comment: good catch! fixed. 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: us...@infra.apache.org Issue Time Tracking --- Worklog Id: (was: 409007) Time Spent: 50m (was: 40m) > ApproximateQuantilesCombineFn uses deprecated '-' operator > -- > > Key: BEAM-9579 > URL: https://issues.apache.org/jira/browse/BEAM-9579 > Project: Beam > Issue Type: Bug > Components: sdk-py-core >Reporter: Chris Gorgolewski >Priority: Minor > Time Spent: 50m > Remaining Estimate: 0h > > This causes a TypeError with numpy 1.16.4 > > {{apache_beam/transforms/stats.py", line 437, in }} > {{ else (a > b) - (a < b)}} > {{TypeError: numpy boolean subtract, the `-` operator, is deprecated, use the > bitwise_xor, the `^` operator, or the logical_xor function instead.}} -- This message was sent by Atlassian Jira (v8.3.4#803005)
[jira] [Work logged] (BEAM-9579) ApproximateQuantilesCombineFn uses deprecated '-' operator
[ https://issues.apache.org/jira/browse/BEAM-9579?focusedWorklogId=408917&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-408917 ] ASF GitHub Bot logged work on BEAM-9579: Author: ASF GitHub Bot Created on: 24/Mar/20 16:55 Start Date: 24/Mar/20 16:55 Worklog Time Spent: 10m Work Description: aaltay commented on pull request #11204: [BEAM-9579] Fix numpy logic operators URL: https://github.com/apache/beam/pull/11204#discussion_r397305147 ## File path: sdks/python/apache_beam/transforms/stats.py ## @@ -430,11 +430,11 @@ class ApproximateQuantilesCombineFn(CombineFn): def __init__( self, num_quantiles, buffer_size, num_buffers, key=None, reverse=False): if key: - self._comparator = lambda a, b: (key(a) < key(b)) - (key(a) > key(b)) \ -if reverse else (key(a) > key(b)) - (key(a) < key(b)) + self._comparator = lambda a, b: (key(a) < key(b)) ^ (key(a) > key(b)) \ Review comment: Maybe I am missing something here, but I think here we use - to get +1, 0 or -1 and ^ operator would not give us. 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: us...@infra.apache.org Issue Time Tracking --- Worklog Id: (was: 408917) Time Spent: 40m (was: 0.5h) > ApproximateQuantilesCombineFn uses deprecated '-' operator > -- > > Key: BEAM-9579 > URL: https://issues.apache.org/jira/browse/BEAM-9579 > Project: Beam > Issue Type: Bug > Components: sdk-py-core >Reporter: Chris Gorgolewski >Priority: Minor > Time Spent: 40m > Remaining Estimate: 0h > > This causes a TypeError with numpy 1.16.4 > > {{apache_beam/transforms/stats.py", line 437, in }} > {{ else (a > b) - (a < b)}} > {{TypeError: numpy boolean subtract, the `-` operator, is deprecated, use the > bitwise_xor, the `^` operator, or the logical_xor function instead.}} -- This message was sent by Atlassian Jira (v8.3.4#803005)
[jira] [Work logged] (BEAM-9579) ApproximateQuantilesCombineFn uses deprecated '-' operator
[ https://issues.apache.org/jira/browse/BEAM-9579?focusedWorklogId=408916&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-408916 ] ASF GitHub Bot logged work on BEAM-9579: Author: ASF GitHub Bot Created on: 24/Mar/20 16:55 Start Date: 24/Mar/20 16:55 Worklog Time Spent: 10m Work Description: aaltay commented on pull request #11204: [BEAM-9579] Fix numpy logic operators URL: https://github.com/apache/beam/pull/11204#discussion_r397304795 ## File path: CHANGES.md ## @@ -116,6 +116,7 @@ ## Bugfixes +* Fixed numpy operators in ApproximateQuantiles (Python) ([BEAM-9579](https://issues.apache.org/jira/browse/BEAM-9579)). Review comment: @amaliujia - Should we wrap up the 2.20 release section and start a new section. This is the first release we are trying out changes.md, so we may need to figure out a good point where we need to update this file. Maybe we can do it after release branch cut. What do you think? 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: us...@infra.apache.org Issue Time Tracking --- Worklog Id: (was: 408916) Time Spent: 0.5h (was: 20m) > ApproximateQuantilesCombineFn uses deprecated '-' operator > -- > > Key: BEAM-9579 > URL: https://issues.apache.org/jira/browse/BEAM-9579 > Project: Beam > Issue Type: Bug > Components: sdk-py-core >Reporter: Chris Gorgolewski >Priority: Minor > Time Spent: 0.5h > Remaining Estimate: 0h > > This causes a TypeError with numpy 1.16.4 > > {{apache_beam/transforms/stats.py", line 437, in }} > {{ else (a > b) - (a < b)}} > {{TypeError: numpy boolean subtract, the `-` operator, is deprecated, use the > bitwise_xor, the `^` operator, or the logical_xor function instead.}} -- This message was sent by Atlassian Jira (v8.3.4#803005)
[jira] [Work logged] (BEAM-9579) ApproximateQuantilesCombineFn uses deprecated '-' operator
[ https://issues.apache.org/jira/browse/BEAM-9579?focusedWorklogId=408528&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-408528 ] ASF GitHub Bot logged work on BEAM-9579: Author: ASF GitHub Bot Created on: 24/Mar/20 04:07 Start Date: 24/Mar/20 04:07 Worklog Time Spent: 10m Work Description: chrisgorgo commented on issue #11204: [BEAM-9579] Fix numpy logic operators URL: https://github.com/apache/beam/pull/11204#issuecomment-603002452 R: @aaltay @charlesccychen 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: us...@infra.apache.org Issue Time Tracking --- Worklog Id: (was: 408528) Time Spent: 20m (was: 10m) > ApproximateQuantilesCombineFn uses deprecated '-' operator > -- > > Key: BEAM-9579 > URL: https://issues.apache.org/jira/browse/BEAM-9579 > Project: Beam > Issue Type: Bug > Components: sdk-py-core >Reporter: Chris Gorgolewski >Priority: Minor > Time Spent: 20m > Remaining Estimate: 0h > > This causes a TypeError with numpy 1.16.4 > > {{apache_beam/transforms/stats.py", line 437, in }} > {{ else (a > b) - (a < b)}} > {{TypeError: numpy boolean subtract, the `-` operator, is deprecated, use the > bitwise_xor, the `^` operator, or the logical_xor function instead.}} -- This message was sent by Atlassian Jira (v8.3.4#803005)
[jira] [Work logged] (BEAM-9579) ApproximateQuantilesCombineFn uses deprecated '-' operator
[ https://issues.apache.org/jira/browse/BEAM-9579?focusedWorklogId=408526&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-408526 ] ASF GitHub Bot logged work on BEAM-9579: Author: ASF GitHub Bot Created on: 24/Mar/20 04:02 Start Date: 24/Mar/20 04:02 Worklog Time Spent: 10m Work Description: chrisgorgo commented on pull request #11204: [BEAM-9579] Fix numpy logic operators URL: https://github.com/apache/beam/pull/11204 Replacing deprecated '-' logical operators. Thank you for your contribution! Follow this checklist to help us incorporate your contribution quickly and easily: - [ ] [**Choose reviewer(s)**](https://beam.apache.org/contribute/#make-your-change) and mention them in a comment (`R: @username`). - [ ] Format the pull request title like `[BEAM-XXX] Fixes bug in ApproximateQuantiles`, where you replace `BEAM-XXX` with the appropriate JIRA issue, if applicable. This will automatically link the pull request to the issue. - [ ] Update `CHANGES.md` with noteworthy changes. - [ ] If this contribution is large, please file an Apache [Individual Contributor License Agreement](https://www.apache.org/licenses/icla.pdf). See the [Contributor Guide](https://beam.apache.org/contribute) for more tips on [how to make review process smoother](https://beam.apache.org/contribute/#make-reviewers-job-easier). Post-Commit Tests Status (on master branch) Lang | SDK | Apex | Dataflow | Flink | Gearpump | Samza | Spark --- | --- | --- | --- | --- | --- | --- | --- Go | [![Build Status](https://builds.apache.org/job/beam_PostCommit_Go/lastCompletedBuild/badge/icon)](https://builds.apache.org/job/beam_PostCommit_Go/lastCompletedBuild/) | --- | --- | [![Build Status](https://builds.apache.org/job/beam_PostCommit_Go_VR_Flink/lastCompletedBuild/badge/icon)](https://builds.apache.org/job/beam_PostCommit_Go_VR_Flink/lastCompletedBuild/) | --- | --- | [![Build Status](https://builds.apache.org/job/beam_PostCommit_Go_VR_Spark/lastCompletedBuild/badge/icon)](https://builds.apache.org/job/beam_PostCommit_Go_VR_Spark/lastCompletedBuild/) Java | [![Build Status](https://builds.apache.org/job/beam_PostCommit_Java/lastCompletedBuild/badge/icon)](https://builds.apache.org/job/beam_PostCommit_Java/lastCompletedBuild/) | [![Build Status](https://builds.apache.org/job/beam_PostCommit_Java_ValidatesRunner_Apex/lastCompletedBuild/badge/icon)](https://builds.apache.org/job/beam_PostCommit_Java_ValidatesRunner_Apex/lastCompletedBuild/) | [![Build Status](https://builds.apache.org/job/beam_PostCommit_Java_ValidatesRunner_Dataflow/lastCompletedBuild/badge/icon)](https://builds.apache.org/job/beam_PostCommit_Java_ValidatesRunner_Dataflow/lastCompletedBuild/)[![Build Status](https://builds.apache.org/job/beam_PostCommit_Java_ValidatesRunner_Dataflow_Java11/lastCompletedBuild/badge/icon)](https://builds.apache.org/job/beam_PostCommit_Java_ValidatesRunner_Dataflow_Java11/lastCompletedBuild/) | [![Build Status](https://builds.apache.org/job/beam_PostCommit_Java_ValidatesRunner_Flink/lastCompletedBuild/badge/icon)](https://builds.apache.org/job/beam_PostCommit_Java_ValidatesRunner_Flink/lastCompletedBuild/)[![Build Status](https://builds.apache.org/job/beam_PostCommit_Java_PVR_Flink_Batch/lastCompletedBuild/badge/icon)](https://builds.apache.org/job/beam_PostCommit_Java_PVR_Flink_Batch/lastCompletedBuild/)[![Build Status](https://builds.apache.org/job/beam_PostCommit_Java_PVR_Flink_Streaming/lastCompletedBuild/badge/icon)](https://builds.apache.org/job/beam_PostCommit_Java_PVR_Flink_Streaming/lastCompletedBuild/) | [![Build Status](https://builds.apache.org/job/beam_PostCommit_Java_ValidatesRunner_Gearpump/lastCompletedBuild/badge/icon)](https://builds.apache.org/job/beam_PostCommit_Java_ValidatesRunner_Gearpump/lastCompletedBuild/) | [![Build Status](https://builds.apache.org/job/beam_PostCommit_Java_ValidatesRunner_Samza/lastCompletedBuild/badge/icon)](https://builds.apache.org/job/beam_PostCommit_Java_ValidatesRunner_Samza/lastCompletedBuild/) | [![Build Status](https://builds.apache.org/job/beam_PostCommit_Java_ValidatesRunner_Spark/lastCompletedBuild/badge/icon)](https://builds.apache.org/job/beam_PostCommit_Java_ValidatesRunner_Spark/lastCompletedBuild/)[![Build Status](https://builds.apache.org/job/beam_PostCommit_Java_PVR_Spark_Batch/lastCompletedBuild/badge/icon)](https://builds.apache.org/job/beam_PostCommit_Java_PVR_Spark_Batch/lastCompletedBuild/)[![Build Status](https://builds.apache.org/job/beam_PostCommit_Java_ValidatesRunner_SparkStructuredStreaming/lastCompletedBuild/badge/icon)](https://builds.apache.org/job/beam_PostCommit_Java_ValidatesRunner_SparkStructuredStreaming/la