You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@zeppelin.apache.org by rhymoid <gi...@git.apache.org> on 2016/11/29 23:25:41 UTC

[GitHub] zeppelin pull request #1705: [ZEPPELIN-1729] With CRLF line endings, Livy ge...

GitHub user rhymoid opened a pull request:

    https://github.com/apache/zeppelin/pull/1705

    [ZEPPELIN-1729] With CRLF line endings, Livy gets HTTP 500 errors

    ### What is this PR for?
    When you paste text on Windows, you may inadvertedly add some Carriage Return control characters along with it. When this happens in a Livy paragraph in Zeppelin 0.6.0, execution of that paragraph will fail with a "500 Internal Server Error" message. This is because `LivyHelper` does not properly sanitise its input when generating a JSON payload for the Livy server. This PR takes the subset for the resolution of [ZEPPELIN-1430](https://issues.apache.org/jira/browse/ZEPPELIN-1430/) that should resolve this issue.
    
    ### What type of PR is it?
    Bug Fix
    
    ### What is the Jira issue?
    <https://issues.apache.org/jira/browse/ZEPPELIN-1729/>
    
    ### How should this be tested?
    
    Paste the following code in a new paragraph, ensuring that lines are ended by CRLF rather than LF:
    
        %livy.pyspark
        import datetime
        import json
    
    This can be easily realised on Windows, by copy-pasting this code from Notepad. Then, try to execute the paragraph. Without the fix, a "500 Internal Server Error" message should appear. With the fix, the paragraph will successfully execute (and do nothing interesting).
    
    ### Questions:
    * Does the licenses files need update? No.
    * Is there breaking changes for older versions? No.
    * Does this needs documentation? No.

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

    $ git pull https://github.com/rhymoid/zeppelin ZEPPELIN-1729

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

    https://github.com/apache/zeppelin/pull/1705.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 #1705
    
----
commit b702cc87917c7ff855e7a57eefdd6295bf09215e
Author: Stijn van Drongelen <rh...@gmail.com>
Date:   2016-11-29T23:21:50Z

    [ZEPPELIN-1729] With CRLF line endings, Livy gets HTTP 500 errors
    
    ### What is this PR for?
    When you paste text on Windows, you may inadvertedly add some Carriage Return
    control characters along with it. When this happens in a Livy paragraph
    in Zeppelin 0.6.0, execution of that paragraph will fail with a "500 Internal
    Server Error" message. This is because `LivyHelper` does not properly sanitise
    its input when generating a JSON payload for the Livy server. This PR takes
    the subset for the resolution of [ZEPPELIN-1430](https://issues.apache.org/jira/browse/ZEPPELIN-1430/)
    that should resolve this issue.
    
    ### What type of PR is it?
    Bug Fix
    
    ### What is the Jira issue?
    <https://issues.apache.org/jira/browse/ZEPPELIN-1729/>
    
    ### How should this be tested?
    
    Paste the following code in a new paragraph, ensuring that lines are ended by
    CRLF rather than LF:
    
        %livy.pyspark
        import datetime
        import json
    
    This can be easily realised on Windows, by copy-pasting this code from Notepad.
    Then, try to execute the paragraph. Without the fix, a "500 Internal Server Error"
    message should appear. With the fix, the paragraph will successfully execute
    (and do nothing interesting).
    
    ### Questions:
    * Does the licenses files need update? No.
    * Is there breaking changes for older versions? No.
    * Does this needs documentation? No.

----


---
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] zeppelin issue #1705: [ZEPPELIN-1729] With CRLF line endings, Livy gets HTTP...

Posted by rhymoid <gi...@git.apache.org>.
Github user rhymoid commented on the issue:

    https://github.com/apache/zeppelin/pull/1705
  
    Looks like the builds for branch-0.6 are failing because some Spark binaries were removed from all mirrors. I think this was fixed in master with #1599 + #1709, but not for branch-0.6.


---
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] zeppelin issue #1705: [ZEPPELIN-1729] With CRLF line endings, Livy gets HTTP...

Posted by zjffdu <gi...@git.apache.org>.
Github user zjffdu commented on the issue:

    https://github.com/apache/zeppelin/pull/1705
  
    Thanks @rhymoid, I am refactoring LivyInterpreter now in #1612 , refactoring LivyHelp is my next step. 


---
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] zeppelin issue #1705: [ZEPPELIN-1729] With CRLF line endings, Livy gets HTTP...

Posted by rhymoid <gi...@git.apache.org>.
Github user rhymoid commented on the issue:

    https://github.com/apache/zeppelin/pull/1705
  
    I'm closing this PR, as I now understand that 0.6.3 will not happen. The only thing this PR contributes is some tests for `LivyHelper`, but that class needs a complete rewrite anyway.


---
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] zeppelin pull request #1705: [ZEPPELIN-1729] With CRLF line endings, Livy ge...

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

    https://github.com/apache/zeppelin/pull/1705


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