From ac4c1e2b2e49a87f8b84aab907c529d3fba56dfd Mon Sep 17 00:00:00 2001 From: Tao He Date: Wed, 13 Jan 2021 16:22:17 +0800 Subject: [PATCH] Upgrade vineyard to v0.1.5. (#73) --- .github/workflows/ci.yml | 34 +++++++++----- analytical_engine/CMakeLists.txt | 2 +- .../core/object/fragment_wrapper.h | 2 +- analytical_engine/frame/project_frame.cc | 3 +- .../executor/runtime/native/CMakeLists.txt | 2 +- .../runtime/native/graph_builder_ffi.cc | 6 +-- .../executor/runtime/native/graph_schema.cc | 36 +++++++-------- .../executor/runtime/native/graph_schema.h | 11 +++-- .../executor/runtime/native/htap_ds_impl.cc | 2 +- .../runtime/native/property_graph_stream.cc | 20 +++++---- .../runtime/native/property_graph_stream.h | 45 +++++++++++-------- k8s/graphscope.Dockerfile | 4 +- python/graphscope/client/session.py | 17 ++++++- .../experimental/nx/tests/test_nx.py | 1 + python/requirements.txt | 2 +- 15 files changed, 111 insertions(+), 76 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 586de8b64b56..9d14aec31d78 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -28,7 +28,7 @@ jobs: run: shell: scl enable devtoolset-7 -- bash --noprofile --norc -eo pipefail {0} container: - image: registry.cn-hongkong.aliyuncs.com/graphscope/graphscope-vineyard:latest + image: registry.cn-hongkong.aliyuncs.com/graphscope/graphscope-vineyard:v0.1.5 options: --shm-size 4096m strategy: @@ -133,7 +133,7 @@ jobs: defaults: run: shell: scl enable devtoolset-7 -- bash --noprofile --norc -eo pipefail {0} - container: registry.cn-hongkong.aliyuncs.com/graphscope/graphscope-vineyard:latest + container: registry.cn-hongkong.aliyuncs.com/graphscope/graphscope-vineyard:v0.1.5 steps: - name: Install Dependencies run: | @@ -173,7 +173,7 @@ jobs: defaults: run: shell: scl enable devtoolset-7 -- bash --noprofile --norc -eo pipefail {0} - container: registry.cn-hongkong.aliyuncs.com/graphscope/graphscope-vineyard:latest + container: registry.cn-hongkong.aliyuncs.com/graphscope/graphscope-vineyard:v0.1.5 steps: - name: Install Dependencies run: | @@ -284,10 +284,14 @@ jobs: - uses: actions/checkout@v2.3.2 - uses: actions/download-artifact@v2 - - name: Prepare environment + + - name: Prepare environment for dataset run: | export GS_TEST_DIR='/root/gstest' git clone -b master --single-branch --depth=1 https://github.com/7br/gstest.git ${GS_TEST_DIR} + + - name: Prepare environment for deps + run: | python3 -m pip install pytest-cov tar -xf ./gae-${{ github.sha }}/gae.tar tar -xf ./gle-${{ github.sha }}/gle.tar @@ -302,11 +306,16 @@ jobs: - name: App Test with Expr Off if: matrix.experimental == 'OFF' run: | + # prelaunch the etcd + /usr/local/bin/etcd --data-dir=/dev/shm/default.etcd & + export GS_TEST_DIR='/root/gstest' cd python python3 -m pytest --cov=graphscope --cov-config=.coveragerc --cov-report=xml \ --cov-report=term --exitfirst -s -v tests + pkill -TERM etcd || true + - name: Upload Coverage if: matrix.experimental == 'OFF' uses: codecov/codecov-action@v1 @@ -317,12 +326,17 @@ jobs: - name: App Test with Expr On if: matrix.experimental == 'ON' run: | + # prelaunch the etcd + /usr/local/bin/etcd --data-dir=/dev/shm/default.etcd & + export GS_TEST_DIR='/root/gstest' python3 -m pytest --exitfirst -s -v python/graphscope/experimental/nx/tests/classes python3 -m pytest --exitfirst -s -v python/graphscope/experimental/nx/tests/test_nx.py python3 -m pytest --exitfirst -s -v python/graphscope/experimental/nx/tests/algorithms/builtin \ python/graphscope/experimental/nx/tests/test_utils.py + pkill -TERM etcd || true + k8s-test: runs-on: self-hosted needs: [build-gae, build-gie, build-gle, build-manager] @@ -368,9 +382,9 @@ jobs: --network=host \ -f ./manager.Dockerfile . popd - sudo python3 -m pip install -r python/requirements.txt - sudo python3 -m pip install -r python/requirements-dev.txt - sudo python3 -m pip install pytest-cov + python3 -m pip install -r python/requirements.txt --user + python3 -m pip install -r python/requirements-dev.txt --user + python3 -m pip install pytest-cov --user pushd python && sudo -E python3 setup.py develop && popd - name: Kubernetes test @@ -446,9 +460,9 @@ jobs: --network=host \ -f ./manager.Dockerfile . popd - sudo python3 -m pip install -r python/requirements.txt - sudo python3 -m pip install -r python/requirements-dev.txt - sudo python3 -m pip install pytest-cov + python3 -m pip install -r python/requirements.txt + python3 -m pip install -r python/requirements-dev.txt + python3 -m pip install pytest-cov pushd python && sudo -E python3 setup.py develop && popd - name: Run function test diff --git a/analytical_engine/CMakeLists.txt b/analytical_engine/CMakeLists.txt index 1be92f5de8b8..4ba928043b62 100644 --- a/analytical_engine/CMakeLists.txt +++ b/analytical_engine/CMakeLists.txt @@ -105,7 +105,7 @@ endif () find_package(libgrapelite REQUIRED) include_directories(${LIBGRAPELITE_INCLUDE_DIRS}) -find_package(vineyard 0.1.3 REQUIRED) +find_package(vineyard 0.1.5 REQUIRED) include_directories(${VINEYARD_INCLUDE_DIRS}) add_compile_options(-DENABLE_SELECTOR) diff --git a/analytical_engine/core/object/fragment_wrapper.h b/analytical_engine/core/object/fragment_wrapper.h index b7316cc37a59..8e1262f4baa9 100644 --- a/analytical_engine/core/object/fragment_wrapper.h +++ b/analytical_engine/core/object/fragment_wrapper.h @@ -43,7 +43,7 @@ inline void set_graph_def( rpc::GraphDef& graph_def) { auto& meta = fragment->meta(); graph_def.set_graph_type(rpc::ARROW_PROPERTY); - graph_def.set_directed(meta.GetKeyValue("directed")); + graph_def.set_directed(static_cast(meta.GetKeyValue("directed"))); auto* schema_def = graph_def.mutable_schema_def(); schema_def->set_oid_type( diff --git a/analytical_engine/frame/project_frame.cc b/analytical_engine/frame/project_frame.cc index 6bebeac9b477..0eba304bd30c 100644 --- a/analytical_engine/frame/project_frame.cc +++ b/analytical_engine/frame/project_frame.cc @@ -93,7 +93,8 @@ class ProjectFrame> { auto oid_type = parent_meta.GetKeyValue("oid_type"); auto vid_type = parent_meta.GetKeyValue("vid_type"); - graph_def.set_directed(parent_meta.template GetKeyValue("directed")); + graph_def.set_directed( + static_cast(parent_meta.template GetKeyValue("directed"))); auto* schema_def = graph_def.mutable_schema_def(); schema_def->set_oid_type(oid_type); schema_def->set_vid_type(vid_type); diff --git a/interactive_engine/src/executor/runtime/native/CMakeLists.txt b/interactive_engine/src/executor/runtime/native/CMakeLists.txt index 0a599051377b..cdc3534be999 100644 --- a/interactive_engine/src/executor/runtime/native/CMakeLists.txt +++ b/interactive_engine/src/executor/runtime/native/CMakeLists.txt @@ -44,7 +44,7 @@ find_package(Threads REQUIRED) # we need edge src/dst ids in etable. add_definitions(-DENDPOINT_LISTS) -find_package(vineyard 0.1.3 REQUIRED) +find_package(vineyard 0.1.5 REQUIRED) add_library(native_store global_store_ffi.cc htap_ds_impl.cc graph_builder_ffi.cc diff --git a/interactive_engine/src/executor/runtime/native/graph_builder_ffi.cc b/interactive_engine/src/executor/runtime/native/graph_builder_ffi.cc index 184720ae6959..0ad659dafca2 100644 --- a/interactive_engine/src/executor/runtime/native/graph_builder_ffi.cc +++ b/interactive_engine/src/executor/runtime/native/graph_builder_ffi.cc @@ -57,13 +57,13 @@ void get_builder_id(GraphBuilder builder, ObjectId *object_id, void launch_property_graph_loader(vineyard::Client &client, vineyard::ObjectID global_stream_id, size_t size, InstanceId *instance_ids) { - std::map cluster; + std::map cluster; VINEYARD_CHECK_OK(client.ClusterInfo(cluster)); std::set host_list; for (size_t idx = 0; idx < size; ++idx) { auto iter = cluster.find(instance_ids[idx]); VINEYARD_ASSERT(iter != cluster.end()); - host_list.emplace(iter->second.get("hostname")); + host_list.emplace(iter->second["hostname"].get_ref()); } std::string hosts = boost::algorithm::join(host_list, ","); std::string loader_path; @@ -157,9 +157,9 @@ GraphBuilder get_graph_builder(const char *graph_name, const int index) { LOG(INFO) << "get name " << graph_name << " yields ID " << vineyard::VYObjectIDToString(id); #endif -#ifndef NDEBUG vineyard::ObjectMeta meta; VINEYARD_CHECK_OK(client.GetMetaData(id, meta, true)); +#ifndef NDEBUG meta.PrintMeta(); #endif auto gstream = diff --git a/interactive_engine/src/executor/runtime/native/graph_schema.cc b/interactive_engine/src/executor/runtime/native/graph_schema.cc index 40a5dcfdedc0..7450f5518262 100644 --- a/interactive_engine/src/executor/runtime/native/graph_schema.cc +++ b/interactive_engine/src/executor/runtime/native/graph_schema.cc @@ -36,7 +36,7 @@ limitations under the License. #include "arrow/api.h" #include "glog/logging.h" -#include "common/util/ptree.h" +#include "common/util/json.h" namespace vineyard { @@ -95,8 +95,6 @@ PropertyType PropertyTypeFromString(const std::string& type) { } // namespace detail -using boost::property_tree::ptree; - MGPropertyGraphSchema::PropertyId MGPropertyGraphSchema::GetPropertyId( const std::string& name) { PropertyId id; @@ -196,51 +194,47 @@ MGPropertyGraphSchema::Entry* MGPropertyGraphSchema::CreateEntry( } } -void MGPropertyGraphSchema::ToJSON(ptree& root) const { - root.put("partitionNum", fnum_); - ptree types; +void MGPropertyGraphSchema::ToJSON(vineyard::json& root) const { + root["partitionNum"] = fnum_; + vineyard::json types = vineyard::json::array(); for (auto const& entry : vertex_entries_) { - types.push_back(std::make_pair("", entry.ToJSON())); + types.emplace_back(entry.ToJSON()); } for (auto const& entry : edge_entries_) { - types.push_back(std::make_pair("", entry.ToJSON())); + types.emplace_back(entry.ToJSON()); } - root.add_child("types", types); + root["types"] = types; if (!unique_property_names_.empty()) { vineyard::put_container(root, "uniquePropertyNames", unique_property_names_); } } -void MGPropertyGraphSchema::FromJSON(ptree const& root) { - fnum_ = root.get("partitionNum"); - for (auto const& kv : root.get_child("types")) { +void MGPropertyGraphSchema::FromJSON(vineyard::json const& root) { + fnum_ = root["partitionNum"].get(); + for (auto const& item : root["types"]) { Entry entry; - entry.FromJSON(kv.second); + entry.FromJSON(item); if (entry.type == "VERTEX") { vertex_entries_.push_back(std::move(entry)); } else { edge_entries_.push_back(std::move(entry)); } } - if (root.get_optional("uniquePropertyNames")) { + if (root.contains("uniquePropertyNames")) { vineyard::get_container(root, "uniquePropertyNames", unique_property_names_); } } std::string MGPropertyGraphSchema::ToJSONString() const { - std::stringstream ss; - ptree root; + vineyard::json root; ToJSON(root); - boost::property_tree::write_json(ss, root, false); - return ss.str(); + return vineyard::json_to_string(root); } void MGPropertyGraphSchema::FromJSONString(std::string const& schema) { - ptree root; - std::istringstream iss(schema); - boost::property_tree::read_json(iss, root); + vineyard::json root = vineyard::json::parse(schema); FromJSON(root); } diff --git a/interactive_engine/src/executor/runtime/native/graph_schema.h b/interactive_engine/src/executor/runtime/native/graph_schema.h index a4f89b843c05..39a6aab7bbd7 100644 --- a/interactive_engine/src/executor/runtime/native/graph_schema.h +++ b/interactive_engine/src/executor/runtime/native/graph_schema.h @@ -29,11 +29,10 @@ #include "arrow/api.h" #include "boost/leaf/all.hpp" -#include "boost/property_tree/json_parser.hpp" -#include "boost/property_tree/ptree.hpp" -#include "graph/fragment/property_graph_types.h" -#include "graph/fragment/graph_schema.h" +#include "vineyard/common/util/json.h" +#include "vineyard/graph/fragment/property_graph_types.h" +#include "vineyard/graph/fragment/graph_schema.h" namespace vineyard { @@ -70,8 +69,8 @@ class MGPropertyGraphSchema { } } - void ToJSON(boost::property_tree::ptree& root) const; - void FromJSON(boost::property_tree::ptree const& root); + void ToJSON(vineyard::json& root) const; + void FromJSON(vineyard::json const& root); std::string ToJSONString() const; void FromJSONString(std::string const& schema); diff --git a/interactive_engine/src/executor/runtime/native/htap_ds_impl.cc b/interactive_engine/src/executor/runtime/native/htap_ds_impl.cc index b8b8d6007918..2b628a129b3f 100644 --- a/interactive_engine/src/executor/runtime/native/htap_ds_impl.cc +++ b/interactive_engine/src/executor/runtime/native/htap_ds_impl.cc @@ -109,7 +109,7 @@ void get_graph_handle(ObjectId id, PartitionId channel_num, if (handle->schema == NULL) { auto schema = handle->fragments[fid].schema(); vineyard::MGPropertyGraphSchema mgschema; - boost::property_tree::ptree schema_json; + vineyard::json schema_json; schema.ToJSON(schema_json); mgschema.FromJSON(schema_json); handle->schema = diff --git a/interactive_engine/src/executor/runtime/native/property_graph_stream.cc b/interactive_engine/src/executor/runtime/native/property_graph_stream.cc index b21f4e1ca85c..1eb73add7b7d 100644 --- a/interactive_engine/src/executor/runtime/native/property_graph_stream.cc +++ b/interactive_engine/src/executor/runtime/native/property_graph_stream.cc @@ -212,7 +212,7 @@ void PropertyGraphOutStream::AddVertex(VertexId id, LabelId labelid, batch_chunk->RemoveColumn(vertex_primary_key_column_[labelid])); #endif } - this->buildTableChunk(batch_chunk, vertex_writer_, 1, + this->buildTableChunk(batch_chunk, vertex_stream_, vertex_writer_, 1, vertex_property_id_mapping_[labelid]); } @@ -252,7 +252,7 @@ void PropertyGraphOutStream::AddEdge(EdgeId edge_id, VertexId src_id, appender->Apply(builder, edge_id, src_id, dst_id, src_label, dst_label, property_size, properties, edge_property_id_mapping_[label], batch_chunk); - this->buildTableChunk(batch_chunk, edge_writer_, 2, + this->buildTableChunk(batch_chunk, edge_stream_, edge_writer_, 2, edge_property_id_mapping_[label]); } @@ -404,7 +404,8 @@ void PropertyGraphOutStream::initialTables() { void PropertyGraphOutStream::buildTableChunk( std::shared_ptr batch, - std::shared_ptr& stream_writer, + std::shared_ptr &output_stream, + std::unique_ptr& stream_writer, int const property_offset, std::map const& property_id_mapping) { #ifndef NDEBUG @@ -413,6 +414,11 @@ void PropertyGraphOutStream::buildTableChunk( if (batch == nullptr) { return; } + + if (stream_writer == nullptr) { + VINEYARD_CHECK_OK(this->Open(output_stream, stream_writer)); + } + #ifndef NDEBUG LOG(INFO) << "chunk schema: batch is " << batch->schema()->ToString(); #endif @@ -444,7 +450,7 @@ void PropertyGraphOutStream::FinishAllVertices() { batch->RemoveColumn(vertex_primary_key_column_[vertices.first])); #endif } - buildTableChunk(batch, vertex_writer_, 1, + buildTableChunk(batch, vertex_stream_, vertex_writer_, 1, vertex_property_id_mapping_[vertices.first]); } VINEYARD_CHECK_OK(vertex_writer_->Finish()); @@ -465,7 +471,7 @@ void PropertyGraphOutStream::FinishAllEdges() { #ifndef NDEBUG LOG(INFO) << "finish edges: " << batch; #endif - buildTableChunk(batch, edge_writer_, 2, + buildTableChunk(batch, edge_stream_, edge_writer_, 2, edge_property_id_mapping_[edges.first]); } } @@ -496,8 +502,7 @@ std::shared_ptr GlobalPGStreamBuilder::_Seal(Client& client) { auto gstream = std::make_shared(); gstream->total_stream_chunks_ = total_stream_chunks_; gstream->meta_.SetTypeName(type_name()); - gstream->meta_.AddKeyValue("total_stream_chunks", - std::to_string(total_stream_chunks_)); + gstream->meta_.AddKeyValue("total_stream_chunks", total_stream_chunks_); for (size_t idx = 0; idx < stream_chunks_.size(); ++idx) { gstream->meta_.AddMember("stream_chunk_" + std::to_string(idx), @@ -505,7 +510,6 @@ std::shared_ptr GlobalPGStreamBuilder::_Seal(Client& client) { } VINEYARD_CHECK_OK(client.CreateMetaData(gstream->meta_, gstream->id_)); - VINEYARD_CHECK_OK(client.Persist(gstream->id_)); return std::dynamic_pointer_cast(gstream); } diff --git a/interactive_engine/src/executor/runtime/native/property_graph_stream.h b/interactive_engine/src/executor/runtime/native/property_graph_stream.h index f50c179f8cf4..dc19bf3285db 100644 --- a/interactive_engine/src/executor/runtime/native/property_graph_stream.h +++ b/interactive_engine/src/executor/runtime/native/property_graph_stream.h @@ -39,7 +39,7 @@ #include "vineyard/basic/stream/parallel_stream.h" #include "vineyard/client/client.h" #include "vineyard/client/ds/blob.h" -#include "vineyard/common/util/ptree.h" +#include "vineyard/common/util/json.h" #include "graph_schema.h" #include "htap_types.h" @@ -206,7 +206,8 @@ class PropertyGraphOutStream : public Registered { s->vertex_stream_ = std::dynamic_pointer_cast(builder.Seal(client)); client.Persist(s->vertex_stream_->id()); - s->vertex_writer_ = s->vertex_stream_->OpenWriter(client); + // Don't "OpenWriter" when creating, it will be "Get and Construct" again + // VINEYARD_CHECK_OK(s->vertex_stream_->OpenWriter(client, s->vertex_writer_)); } { vineyard::DataframeStreamBuilder builder(client); @@ -215,14 +216,15 @@ class PropertyGraphOutStream : public Registered { s->edge_stream_ = std::dynamic_pointer_cast(builder.Seal(client)); client.Persist(s->edge_stream_->id()); - s->edge_writer_ = s->edge_stream_->OpenWriter(client); + // Don't "OpenWriter" when creating, it will be "Get and Construct" again + // VINEYARD_CHECK_OK(s->edge_stream_->OpenWriter(client, s->edge_writer_)); } s->stream_index_ = index; s->meta_.SetTypeName(type_name()); s->meta_.AddKeyValue("graph_name", std::string(graph_name)); - s->meta_.AddKeyValue("stream_index", std::to_string(s->stream_index_)); + s->meta_.AddKeyValue("stream_index", s->stream_index_); s->meta_.AddKeyValue("graph_schema", s->graph_schema_->ToJSONString()); s->meta_.AddMember("vertex_stream", s->vertex_stream_->meta()); s->meta_.AddMember("edge_stream", s->edge_stream_->meta()); @@ -239,22 +241,28 @@ class PropertyGraphOutStream : public Registered { void Construct(const ObjectMeta& meta) override { meta_ = meta; - const ptree& tree = meta.MetaData(); - this->id_ = VYObjectIDFromString(tree.get("id")); - this->stream_index_ = tree.get("stream_index"); + this->id_ = VYObjectIDFromString(meta.GetKeyValue("id")); + this->stream_index_ = meta.GetKeyValue("stream_index"); this->vertex_stream_ = std::dynamic_pointer_cast(meta.GetMember("vertex_stream")); this->edge_stream_ = std::dynamic_pointer_cast(meta.GetMember("edge_stream")); - auto client = dynamic_cast(meta.GetClient()); - this->vertex_writer_ = this->vertex_stream_->OpenWriter(*client); - this->edge_writer_ = this->edge_stream_->OpenWriter(*client); this->graph_schema_ = std::make_shared(); - graph_schema_->FromJSONString(tree.get("graph_schema")); + graph_schema_->FromJSONString(meta.GetKeyValue("graph_schema")); this->initialTables(); } + Status Open(std::shared_ptr &output_stream, + std::unique_ptr &writer) { + auto client = dynamic_cast(meta_.GetClient()); + auto status = output_stream->OpenWriter(*client, writer); + if (!status.ok()) { + LOG(INFO) << "Failed to open writer for stream: " << status.ToString(); + } + return status; + } + Status GetNext(size_t const size, std::unique_ptr& buffer, std::shared_ptr& stream_writer) { @@ -287,7 +295,8 @@ class PropertyGraphOutStream : public Registered { private: void initialTables(); void buildTableChunk(std::shared_ptr batch, - std::shared_ptr& stream_writer, + std::shared_ptr &output_stream, + std::unique_ptr& stream_writer, int const property_offset, std::map const& property_id_mapping); @@ -316,8 +325,8 @@ class PropertyGraphOutStream : public Registered { int stream_index_; std::shared_ptr vertex_stream_; std::shared_ptr edge_stream_; - std::shared_ptr vertex_writer_; - std::shared_ptr edge_writer_; + std::unique_ptr vertex_writer_; + std::unique_ptr edge_writer_; friend class PropertyGraphInStream; }; @@ -328,8 +337,8 @@ class PropertyGraphInStream { : vertex_stream_(stream.vertex_stream_), edge_stream_(stream.edge_stream_), graph_schema_(stream.graph_schema_) { - vertex_reader_ = vertex_stream_->OpenReader(client); - edge_reader_ = edge_stream_->OpenReader(client); + VINEYARD_CHECK_OK(vertex_stream_->OpenReader(client, vertex_reader_)); + VINEYARD_CHECK_OK(edge_stream_->OpenReader(client, edge_reader_)); } Status GetNextVertices(Client& client, @@ -349,8 +358,8 @@ class PropertyGraphInStream { private: std::shared_ptr vertex_stream_; std::shared_ptr edge_stream_; - std::shared_ptr vertex_reader_; - std::shared_ptr edge_reader_; + std::unique_ptr vertex_reader_; + std::unique_ptr edge_reader_; std::shared_ptr graph_schema_; }; diff --git a/k8s/graphscope.Dockerfile b/k8s/graphscope.Dockerfile index ffcc568a56ef..aa2f4b7ec834 100644 --- a/k8s/graphscope.Dockerfile +++ b/k8s/graphscope.Dockerfile @@ -4,13 +4,13 @@ # the result image includes all runtime stuffs of graphscope, with analytical engine, # learning engine and interactive engine installed. -ARG BASE_VERSION=latest +ARG BASE_VERSION=v0.1.5 FROM registry.cn-hongkong.aliyuncs.com/graphscope/graphscope-vineyard:$BASE_VERSION as builder ARG CI=true ENV CI=$CI -ARG EXPERIMENTAL_ON=OFF +ARG EXPERIMENTAL_ON=ON ENV EXPERIMENTAL_ON=$EXPERIMENTAL_ON ARG profile=release diff --git a/python/graphscope/client/session.py b/python/graphscope/client/session.py index 22bb644dcc54..efcaeaa77e34 100755 --- a/python/graphscope/client/session.py +++ b/python/graphscope/client/session.py @@ -33,6 +33,7 @@ import sys import threading import time +import warnings from queue import Empty as EmptyQueue try: @@ -281,8 +282,20 @@ def __init__( self._run_on_local() # deprecated params handle - kw.pop("show_log", None) - kw.pop("log_level", None) + if "show_log" in kw: + warnings.warn( + "The `show_log` parameter has been deprecated and has no effect, " + "please use `graphscope.set_option(show_log=%s)` instead." + % kw.pop("show_log", None), + category=DeprecationWarning, + ) + if "log_level" in kw: + warnings.warn( + "The `log_level` parameter has been deprecated and has no effect, " + "please use `graphscope.set_option(log_level=%r)` instead." + % kw.pop("show_log", None), + category=DeprecationWarning, + ) # deploy minikube on virtual machine self._config_params["k8s_minikube_vm_driver"] = kw.pop( diff --git a/python/graphscope/experimental/nx/tests/test_nx.py b/python/graphscope/experimental/nx/tests/test_nx.py index de02327a379d..a0a532a65102 100644 --- a/python/graphscope/experimental/nx/tests/test_nx.py +++ b/python/graphscope/experimental/nx/tests/test_nx.py @@ -451,6 +451,7 @@ def test_project_to_simple(self): ): sg6 = empty_g.project_to_simple(v_prop="foo") + @pytest.mark.skip(reason="It use much memory, exceeds the limit of Github runner") def test_implicit_project_to_simple(self): g = self.g nx.builtin.degree_centrality(g) diff --git a/python/requirements.txt b/python/requirements.txt index 06a3e7fb2298..438bcabb9877 100644 --- a/python/requirements.txt +++ b/python/requirements.txt @@ -10,4 +10,4 @@ pandas protobuf PyYAML scipy -vineyard>=0.1.3, <0.1.5 +vineyard==0.1.5