Skip to content

[ZEPPELIN-1069]Ignore implicit interpreter when user enter wrong interpreter name - #1248

Closed
mwkang wants to merge 10 commits into
apache:masterfrom
mwkang:ZEPPELIN-1069
Closed

[ZEPPELIN-1069]Ignore implicit interpreter when user enter wrong interpreter name#1248
mwkang wants to merge 10 commits into
apache:masterfrom
mwkang:ZEPPELIN-1069

Conversation

@mwkang

Copy link
Copy Markdown
Contributor

What is this PR for?

Ignore implicit interpreter when user enter wrong interpreter name
linked to #806 (comment)

This PR is related to #1113
ZEPPELIN-1069 branch was force push, so couldn't reopen that PR.

What type of PR is it?

Improvement

What is the Jira issue?

https://issues.apache.org/jira/browse/ZEPPELIN-1069

How should this be tested?

Unit test
Run-time checking

Screenshots (if appropriate)

zeppelin-1069-gif

Questions:

  • Does the licenses files need update? no
  • Is there breaking changes for older versions? no
  • Does this needs documentation? no

@mwkang

Copy link
Copy Markdown
ContributorAuthor

@jongyoul Can you review this PR?

}


public boolean isBinding(String noteId, String replName) {

@bzzbzzAug 2, 2016

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Would isBinded() make more sense as a name for a method that checks weather a particular note is binded (bound) to a particular interpreter?

Copy link
Copy Markdown
ContributorAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, I agree with you. Thanks for comments.
I will change method name.

@mwkangmwkangAug 3, 2016

Copy link
Copy Markdown
ContributorAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@bzzI want to ask your opinion. If I make Note#isBinding method, I remove InterpreterFactory#isBinded method. Do you agree with me?
Um.. Sorry I thinks that Keeping both methods is better.

@bzz

bzz commented Aug 2, 2016

Copy link
Copy Markdown
Member

👍 for having a test!

Looks good to me, modulo the issue raised above. @mwkang can you take a look please?

@astroshim

Copy link
Copy Markdown
Contributor

tested. LGTM

@mwkang

Copy link
Copy Markdown
ContributorAuthor

I refactor method name.

@bzz

bzz commented Aug 3, 2016

Copy link
Copy Markdown
Member

@bzzThanks for comment, But could you explain more why it doesn't make sense?
Ah.. Your meaning is that org.apache.zeppelin.interpreter.InterpreterFactory#isBinded move to Note.java. Is it right?

Yes, that is exactly what I meant @mwkang !
And while doing so, readability of the piece of the code you are changing could also be improved with static import.

What do you think?

@mwkang

Copy link
Copy Markdown
ContributorAuthor

@bzz I'm worried about that static import confused.

@mwkang

Copy link
Copy Markdown
ContributorAuthor

@bzz I changed StringUtils is static import. Can you check the code?

package org.apache.zeppelin.notebook;

import static org.apache.commons.lang.StringUtils.*;

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

static import statement is located at the end of all imports statements. Could you please move it?

Copy link
Copy Markdown
ContributorAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@jongyoul Oh sorry, I move static import position.
Thanks for review.

@jongyoul

Copy link
Copy Markdown
Member

Do you check the error of CI?

Failed tests: NoteTest.insertParagraphWithLastReplName:159 expected:<%spark > but was:<null>
NoteTest.addParagraphWithLastReplName:144 expected:<%spark > but was:<null>

I think it's meaningful error and it needs to be fixed.

@mwkang

Copy link
Copy Markdown
ContributorAuthor

@jongyoul Sorry, I missed it. I will check. I appreciate your review.

@mwkang

Copy link
Copy Markdown
ContributorAuthor

re-trigger CI

@mwkangmwkang closed this Aug 9, 2016
@mwkangmwkang reopened this Aug 9, 2016
@mwkang

Copy link
Copy Markdown
ContributorAuthor

I am not sure this error is related with this issue.

Failed tests: ZeppelinSparkClusterTest.zRunTest:204 expected:<FINISHED> but was:<ERROR>

@bzz

bzz commented Aug 9, 2016

Copy link
Copy Markdown
Member

@mwkang thank you for prompt addressing reviews!

If you re-trigger CI more (close&re-open this PR) - does the same issue persists every time?

}


public boolean isBinded(String noteId, String replName) {

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this can be removed now, in favor of Note.isBinded(), no?

Copy link
Copy Markdown
ContributorAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, I will remove it.

@mwkang

mwkang commented Aug 9, 2016

Copy link
Copy Markdown
ContributorAuthor

If you re-trigger CI more (close&re-open this PR) - does the same issue persists every time?

I'm not sure if it persists. I will re-tigger after fix the issue.

@mwkang

Copy link
Copy Markdown
ContributorAuthor

@bzz No, It does not persists every time.

@bzz

bzz commented Aug 11, 2016

Copy link
Copy Markdown
Member

Ok, good to know, let me look into that

@bzz

bzz commented Aug 11, 2016

Copy link
Copy Markdown
Member

This looks like an issue fixed in master 10h ago:

�[31m- should provide onclick method *** FAILED ***�[0m
�[31m The code passed to eventually never returned normally. Attempted 1 times over 231.694296 milliseconds. Last failure message: 0 was not equal to 1. (AbstractAngularElemTest.scala:72)�[0m

Could you please try rebasing on latest master git pull ; git rebase master; git push -f ?

@mwkang

Copy link
Copy Markdown
ContributorAuthor

@bzz Thanks for your review. I rebase on to master and force push.

@bzz

bzz commented Aug 12, 2016

Copy link
Copy Markdown
Member

Thank you! BTW in my experience, if in case of CI failure PR author posts the failure result from logs - that speeds us review a lot!

CI fails now on Spark 1.6 Scala 2.10 and Scala 2.11 profiles with

[INFO] Zeppelin: web Application .......................... FAILURE [01:31 min]
[INFO] make: Leaving directory `/home/travis/build/apache/zeppelin/zeppelin-web/node_modules/karma/node_modules/socket.io/node_modules/socket.io-client/node_modules/ws/build'
[ERROR] npm ERR! Linux 3.13.0-40-generic
[ERROR] npm ERR! argv "/home/travis/build/apache/zeppelin/zeppelin-web/node/node" "/home/travis/build/apache/zeppelin/zeppelin-web/node/node_modules/npm/bin/npm-cli.js" "install" "--color=false"
[ERROR] npm ERR! node v0.12.13
[ERROR] npm ERR! npm v2.15.0
[ERROR] npm ERR! code ECONNRESET
[ERROR] npm ERR! errno ECONNRESET
[ERROR] npm ERR! syscall read
[ERROR] [ERROR] npm ERR! network read ECONNRESET
[ERROR] npm ERR! network This is most likely not a problem with npm itself
[ERROR] npm ERR! network and is related to network connectivity.
[ERROR] npm ERR! network In most cases you are behind a proxy or have bad network settings.
[ERROR] npm ERR! network [ERROR] npm ERR! network If you are behind a proxy, please make sure that the
[ERROR] npm ERR! network 'proxy' config is set properly. See: 'npm help config'

Which seems to be networking issue on Travis side 😒

Thank you @mwkang for contribution, looks great to me, merging to master if there is no further discussion.

@mwkang

Copy link
Copy Markdown
ContributorAuthor

@bzz I think This PR have some trouble merging to master.
Because When bzz leave comment, I also leave comment immediately.
So bot did not recognize this PR.
Could you mind if you check again? (I'm worried about this PR open forever.)

@bzz

bzz commented Aug 16, 2016

Copy link
Copy Markdown
Member

@mwkang thank you for friendly ping!

import org.apache.zeppelin.user.AuthenticationInfo;
import org.apache.zeppelin.user.Credentials;

import static org.apache.commons.lang.StringUtils.*;

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As per project styleguide#s3.3.1-wildcard-imports - could you please replace whiledcard imports?

@mwkangmwkangAug 17, 2016

Copy link
Copy Markdown
ContributorAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@bzz I'm sorry. I removed wild card import.

@bzz

bzz commented Aug 16, 2016

Copy link
Copy Markdown
Member

Thank you for your patience @mwkang !
Sorry for the late notice, but could you please take a look and make sure that code conforms the project styleguilde?

Will merge to master asap, right after that, if there is no further discussion!

@mwkang

Copy link
Copy Markdown
ContributorAuthor

ping @bzz

@bzz

bzz commented Sep 2, 2016

Copy link
Copy Markdown
Member

I'm sorry for delay, @mwkang - my plate was full last week.
Thank you for contributing and addressing feedback promptly, merging it in, as there is no further discussion.

Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants

@mwkang@bzz@astroshim@jongyoul