This is an automated email from the ASF dual-hosted git repository.
csantanapr pushed a commit to branch master
in repository
https://gitbox.apache.org/repos/asf/incubator-openwhisk-runtime-python.git
The following commit(s) were added to refs/heads/master by this push:
new bc90b56 Fix the ansible issue by changing the variables in
environment/local (#11)
bc90b56 is described below
commit bc90b569cb20ebe33e4b2771c8b852b62915b86d
Author: Vincent <[email protected]>
AuthorDate: Fri Mar 16 16:09:26 2018 -0400
Fix the ansible issue by changing the variables in environment/local (#11)
---
ansible/environments/local/group_vars/all | 4 +-
.../PythonActionContainerTests.scala | 59 ----------------------
2 files changed, 3 insertions(+), 60 deletions(-)
diff --git a/ansible/environments/local/group_vars/all
b/ansible/environments/local/group_vars/all
index 45e9752..b83d824 100755
--- a/ansible/environments/local/group_vars/all
+++ b/ansible/environments/local/group_vars/all
@@ -4,7 +4,8 @@ config_root_dir: "{{ openwhisk_tmp_dir }}/wskconf"
whisk_logs_dir: "{{ openwhisk_tmp_dir }}/wsklogs"
docker_registry: ""
docker_dns: ""
-bypass_pull_for_local_images: true
+runtimes_bypass_pull_for_local_images: true
+invoker_use_runc: "{{ ansible_distribution != 'MacOSX' }}"
db_prefix: whisk_local_
@@ -23,6 +24,7 @@ apigw_host_v2: "http://{{ groups['apigateway']|first
}}:{{apigateway.port.api}}/
invoker_allow_multiple_instances: true
+
env_hosts_dir: "{{ playbook_dir }}/environments/local"
runtimes_manifest:
diff --git
a/tests/src/test/scala/actionContainers/PythonActionContainerTests.scala
b/tests/src/test/scala/actionContainers/PythonActionContainerTests.scala
index afabc3e..0ccce5b 100644
--- a/tests/src/test/scala/actionContainers/PythonActionContainerTests.scala
+++ b/tests/src/test/scala/actionContainers/PythonActionContainerTests.scala
@@ -380,63 +380,4 @@ class PythonActionContainerTests extends
BasicActionRunnerTests with WskActorSys
e should include("Traceback")
})
}
-
- it should "be able to import additional packages as installed in the image"
in {
- val (out, err) = withActionContainer() { c =>
- val code = """
- |from bs4 import BeautifulSoup
- |from dateutil.parser import *
- |import httplib2
- |from lxml import etree
- |import requests
- |from scrapy.item import Item, Field
- |import simplejson as json
- |from twisted.internet import protocol, reactor, endpoints
- |import socket
- |from kafka import BrokerConnection
- |
- |def main(args):
- | socket.setdefaulttimeout(120)
- | b = BeautifulSoup('<html><head><title>python action
test</title></head></html>', 'html.parser')
- | h =
httplib2.Http().request('https://openwhisk.ng.bluemix.net/api/v1')[0]
- | t = parse('2016-02-22 11:59:00 EST')
- | r =
requests.get('https://openwhisk.ng.bluemix.net/api/v1')
- | j = json.dumps({'foo':'bar'}, separators = (',', ':'))
- | kafka = BrokerConnection("it works", 9093, None)
- |
- | return {
- | "bs4": str(b.title),
- | "httplib2": h.status,
- | "dateutil": t.strftime("%A"),
- | "lxml": etree.Element("root").tag,
- | "json": j,
- | "request": r.status_code,
- | "kafka_python": kafka.host
- | }
- """.stripMargin
-
- val (initCode, _) = c.init(initPayload(code))
- initCode should be(200)
-
- val (runCode, runRes) = c.run(runPayload(JsObject()))
- runCode should be(200) // action writer returning an error is OK
-
- runRes shouldBe defined
- runRes should be(
- Some(JsObject(
- "bs4" -> "<title>python action test</title>".toJson,
- "httplib2" -> 200.toJson,
- "dateutil" -> "Monday".toJson,
- "lxml" -> "root".toJson,
- "json" -> JsObject("foo" -> "bar".toJson).compactPrint.toJson,
- "request" -> 200.toJson,
- "kafka_python" -> "it works".toJson)))
- }
-
- checkStreams(out, err, {
- case (o, e) =>
- o shouldBe empty
- e shouldBe empty
- })
- }
}
--
To stop receiving notification emails like this one, please contact
[email protected].