-
Notifications
You must be signed in to change notification settings - Fork 382
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
jarek/5039: autotranslation [WIP] #7542
Conversation
# Conflicts: # kernel/clojure/src/main/java/com/twosigma/beakerx/clojure/kernel/Clojure.java # kernel/sql/src/main/java/com/twosigma/beakerx/sql/kernel/SQL.java
def init_env(): | ||
os.environ["BEAKERX_BASIC_AUTH_USERNAME"] = "beakerx" | ||
os.environ["BEAKERX_BASIC_AUTH_PASSWORD"] = random_string_generator() | ||
os.environ["BEAKERX_FLASK_SERVER_PORT"] = str(get_free_tcp_port()) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
no need for BEAKERX_BASIC_AUTH_USERNAME just make it constant on the other side
BEAKERX_BASIC_AUTH_PASSWORD → BEAKERX_AUTOTRANSLATION_PASSWORD
BEAKERX_FLASK_SERVER_PORT → BEAKERX_AUTOTRANSLATION_PORT
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done
return System.getenv("BEAKERX_BASIC_AUTH_PASSWORD"); | ||
} | ||
|
||
private static String flaskServerPort() { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
rename flaskServerPort to autotranslationPort
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done
@@ -0,0 +1,40 @@ | |||
/* |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
rename to BeakerXClient.java
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done
@@ -0,0 +1,31 @@ | |||
/* |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
rename BeakerxClientManager.java to BeakerXClientManager.java
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done
@@ -100,6 +108,11 @@ public ClassLoader getClassLoaderForImport() { | |||
return getClassLoader(); | |||
} | |||
|
|||
@Override | |||
public BeakerxClient getBeakerx() { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
rename to getBeakerX
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done
this is awesome!! it works! |
# Conflicts: # kernel/base/src/main/java/com/twosigma/beakerx/evaluator/EvaluatorManager.java # kernel/base/src/main/java/com/twosigma/beakerx/kernel/Kernel.java # kernel/base/src/test/java/com/twosigma/beakerx/KernelTest.java # kernel/groovy/src/test/java/com/twosigma/beakerx/groovy/evaluator/GroovyEvaluatorTest.java # kernel/sql/src/main/java/com/twosigma/beakerx/sql/BeakerParser.java # kernel/sql/src/main/java/com/twosigma/beakerx/sql/evaluator/SQLEvaluator.java # kernel/sql/src/main/java/com/twosigma/beakerx/sql/kernel/SQL.java # kernel/sql/src/test/java/com/twosigma/beakerx/sql/SQLAutocompleteTest.java # kernel/sql/src/test/java/com/twosigma/beakerx/sql/SQLBaseEvaluatorTest.java # kernel/sql/src/test/java/com/twosigma/beakerx/sql/SQLEvaluatorTest.java # kernel/sql/src/test/java/com/twosigma/beakerx/sql/SQLKernelTest.java
# Conflicts: # kernel/base/src/main/java/com/twosigma/beakerx/evaluator/EvaluatorManager.java # kernel/base/src/main/java/com/twosigma/beakerx/kernel/Kernel.java # kernel/base/src/test/java/com/twosigma/beakerx/KernelTest.java # kernel/groovy/src/test/java/com/twosigma/beakerx/groovy/evaluator/GroovyEvaluatorTest.java # kernel/sql/src/main/java/com/twosigma/beakerx/sql/BeakerParser.java # kernel/sql/src/main/java/com/twosigma/beakerx/sql/evaluator/SQLEvaluator.java # kernel/sql/src/main/java/com/twosigma/beakerx/sql/kernel/SQL.java # kernel/sql/src/test/java/com/twosigma/beakerx/sql/SQLAutocompleteTest.java # kernel/sql/src/test/java/com/twosigma/beakerx/sql/SQLBaseEvaluatorTest.java # kernel/sql/src/test/java/com/twosigma/beakerx/sql/SQLEvaluatorTest.java # kernel/sql/src/test/java/com/twosigma/beakerx/sql/SQLKernelTest.java
when in the groovy kernel we run |
|
||
set: function (obj, prop, value) { | ||
obj[prop] = value; | ||
var comm = Jupyter.notebook.kernel.comm_manager.new_comm('beaker.autotranslation', null, null, null, utils.uuid()); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
create this once and reuse it with each msg.
also, name the channel "beakerx.autotranslation".
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
are all our channels named "beakerx.*"?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nope, but I will change the names from beaker.*
to beakerx.*
No description provided.