You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flink.apache.org by omaralvarez <gi...@git.apache.org> on 2016/05/31 11:29:25 UTC

[GitHub] flink pull request: [FLINK-3993] [py] Add generateSequence() support to Pyth...

GitHub user omaralvarez opened a pull request:

    https://github.com/apache/flink/pull/2055

    [FLINK-3993] [py] Add generateSequence() support to Python API

    Addition of generate_sequence to python API:
    
    `data = env.generate_sequence(1,20)`
    
    If a parallel number source was needed, there was no option to create it, since from_elements() is not parallel.

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/omaralvarez/flink python_sequence

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/flink/pull/2055.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #2055
    
----
commit 8cb742bcbf8dde0d910360a18e9509117363c41d
Author: omaralvarez <om...@udc.es>
Date:   2016-05-31T11:23:38Z

    [FLINK-3993] [py] Add generateSequence() support to Python API

----


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] flink pull request: [FLINK-3993] [py] Add generateSequence() support to Pyth...

Posted by omaralvarez <gi...@git.apache.org>.
Github user omaralvarez commented on the pull request:

    https://github.com/apache/flink/pull/2055
  
    Perfect. I'll open a new issue and try to fix that and document the test scripts.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] flink pull request: [FLINK-3993] [py] Add generateSequence() support to Pyth...

Posted by omaralvarez <gi...@git.apache.org>.
Github user omaralvarez commented on the pull request:

    https://github.com/apache/flink/pull/2055
  
    I think, everything should be ready now. Although while performing testing, I have found something that I think is not ideal.
    
    If we use this code:
    
    ```python
    env.generate_sequence(1, 5)\
             .map(Id()).map_partition(Verify([1,2,3,4], "Sequence")).output()
    ``` 
    
    The Verify() function will error out with `IndexError: list index out of range`, this is not ideal, since it should raise a Flink testing exception. I could also try to fix this if needed.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] flink pull request: [FLINK-3993] [py] Add generateSequence() support to Pyth...

Posted by zentol <gi...@git.apache.org>.
Github user zentol commented on the pull request:

    https://github.com/apache/flink/pull/2055
  
    Thank you for your contribution. Overall the code is correct, but i would prefer if you would the various "frm" fields to "from".
    
    Also, a small update to the documentation, and a simple test would be appreciated.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] flink pull request: [FLINK-3993] [py] Add generateSequence() support to Pyth...

Posted by asfgit <gi...@git.apache.org>.
Github user asfgit closed the pull request at:

    https://github.com/apache/flink/pull/2055


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] flink pull request: [FLINK-3993] [py] Add generateSequence() support to Pyth...

Posted by zentol <gi...@git.apache.org>.
Github user zentol commented on the pull request:

    https://github.com/apache/flink/pull/2055
  
    please add them as a separate commit, they will be squashed when merging.
    
    Good point regarding frm.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] flink pull request: [FLINK-3993] [py] Add generateSequence() support to Pyth...

Posted by zentol <gi...@git.apache.org>.
Github user zentol commented on the pull request:

    https://github.com/apache/flink/pull/2055
  
    Changing the test infrastructure should be done as a separate issue. There are a few things that could be improved, especially a bit of documentation (like what is the difference between Verify and Verify2).
    
    Your changes look good, I'll merge them later today.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] flink pull request: [FLINK-3993] [py] Add generateSequence() support to Pyth...

Posted by omaralvarez <gi...@git.apache.org>.
Github user omaralvarez commented on the pull request:

    https://github.com/apache/flink/pull/2055
  
    About the "frm", in Python when using from, there is a syntax error since from is a system reserved word. In the Java side of things there is no problem with renaming and using from, but I chose to use also frm to maintain consistency.
    
    I will get right on the documentation and test. Should I add commits or squash them in the one commit.  


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---