[
https://issues.apache.org/jira/browse/BEAM-5485?focusedWorklogId=148371&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-148371
]
ASF GitHub Bot logged work on BEAM-5485:
----------------------------------------
Author: ASF GitHub Bot
Created on: 26/Sep/18 20:52
Start Date: 26/Sep/18 20:52
Worklog Time Spent: 10m
Work Description: jasonkuster closed pull request #6476: [BEAM-5485] Fix
time unit discrepancies in windowing documentation
URL: https://github.com/apache/beam/pull/6476
This is a PR merged from a forked repository.
As GitHub hides the original diff on merge, it is displayed below for
the sake of provenance:
As this is a foreign pull request (from a fork), the diff is supplied
below (as it won't show otherwise due to GitHub magic):
diff --git a/sdks/python/apache_beam/examples/snippets/snippets_test.py
b/sdks/python/apache_beam/examples/snippets/snippets_test.py
index b219609c037..4588ef4b99f 100644
--- a/sdks/python/apache_beam/examples/snippets/snippets_test.py
+++ b/sdks/python/apache_beam/examples/snippets/snippets_test.py
@@ -1177,18 +1177,17 @@ def test_setting_session_windows(self):
unkeyed_items = p | beam.Create([2, 11, 16, 27])
items = (unkeyed_items
| 'key' >> beam.Map(
- lambda x: beam.window.TimestampedValue(('k', x), x)))
+ lambda x: beam.window.TimestampedValue(('k', x), x * 60)))
# [START setting_session_windows]
from apache_beam import window
session_windowed_items = (
- items | 'window' >> beam.WindowInto(window.Sessions(10)))
+ items | 'window' >> beam.WindowInto(window.Sessions(10 * 60)))
# [END setting_session_windows]
summed = (session_windowed_items
| 'group' >> beam.GroupByKey()
| 'combine' >> beam.CombineValues(sum))
unkeyed = summed | 'unkey' >> beam.Map(lambda x: x[1])
- assert_that(unkeyed,
- equal_to([29, 27]))
+ assert_that(unkeyed, equal_to([29, 27]))
def test_setting_global_window(self):
with TestPipeline() as p:
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on 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: 148371)
Time Spent: 2h 20m (was: 2h 10m)
> Fix time unit discrepancies in windowing documentation
> ------------------------------------------------------
>
> Key: BEAM-5485
> URL: https://issues.apache.org/jira/browse/BEAM-5485
> Project: Beam
> Issue Type: Bug
> Components: testing, website
> Reporter: Deepyaman Datta
> Assignee: Jason Kuster
> Priority: Minor
> Time Spent: 2h 20m
> Remaining Estimate: 0h
>
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)