Python API migration

New code should use snake_case. Existing public CamelCase method and property names remain as direct aliases, so a spelling change alone does not break existing callers. These aliases share the canonical implementations and add no request routing or naming-conversion layer. New APIs only introduce snake_case names.

Naming compatibility does not undo parameter or return-value changes listed below; those changes apply to both spellings. Server JSON keys and graph IDs retain their original types and spelling.

Legacy aliasPreferred name
addEdgeadd_edge
addEdgesadd_edges
addVertexadd_vertex
addVerticesadd_vertices
appendEdgeappend_edge
appendVertexappend_vertex
asBlobas_blob
asBoolas_bool
asByteas_byte
asDateas_date
asDoubleas_double
asFloatas_float
asIntas_int
asLongas_long
asObjectas_object
asTextas_text
baseTypebase_type
baseValuebase_value
calcMaxcalc_max
calcMincalc_min
calcOldcalc_old
calcSumcalc_sum
dataTypedata_type
edgeLabeledge_label
eliminateEdgeeliminate_edge
eliminateVertexeliminate_vertex
enableLabelIndexenable_label_index
getEdgeByIdget_edge_by_id
getEdgeByPageget_edge_by_page
getEdgeLabelget_edge_label
getEdgeLabelsget_edge_labels
getEdgesByIdget_edges_by_id
getIndexLabelget_index_label
getIndexLabelsget_index_labels
getPropertyKeyget_property_key
getPropertyKeysget_property_keys
getRelationsget_relations
getSchemaget_schema
getVertexByConditionget_vertex_by_condition
getVertexByConditionWithPageget_vertex_by_condition_with_page
getVertexByIdget_vertex_by_id
getVertexByPageget_vertex_by_page
getVertexLabelget_vertex_label
getVertexLabelsget_vertex_labels
getVerticesByIdget_vertices_by_id
idStrategyid_strategy
ifNotExistif_not_exist
inVin_v
inVLabelin_v_label
indexLabelindex_label
indexLabelsindex_labels
indexTypeindex_type
multiTimesmulti_times
nullableKeysnullable_keys
onEon_e
onVon_v
outVout_v
outVLabelout_v_label
primaryKeysprimary_keys
propertyKeyproperty_key
removeEdgeByIdremove_edge_by_id
removeVertexByIdremove_vertex_by_id
singleTimesingle_time
sortKeyssort_keys
sourceLabelsource_label
targetLabeltarget_label
useAutomaticIduse_automatic_id
useCustomizeNumberIduse_customize_number_id
useCustomizeStringIduse_customize_string_id
usePrimaryKeyIduse_primary_key_id
valueListvalue_list
valueSetvalue_set
valueSinglevalue_single
vertexLabelvertex_label

weighted_shortest_path(source_id, target_id, weight, *, ...) and single_source_shortest_path(source_id, *, weight=None, ...) do not accept max_depth: these server endpoints use capacity/degree/limit controls instead. Neighbourhood and unweighted shortest-path APIs still accept the depth controls offered by their server endpoints.

The legacy client.graphs().get_all_graphs(), get_version() and get_graph_info() helpers keep returning JSON strings, so existing json.loads(...) calls keep working. For parsed dictionaries, use client.graphs().list(), client.version().version() and client.graphs().get(graph_name), respectively. The corresponding client.rest() resources also return native dictionaries. Close PyHugeClient (or use its context manager), rather than closing an individual manager. Version-probe failures raise instead of silently selecting legacy routes. Choose an explicit graphspace only when the deployment supports graphspace routes. Graphspace-only resources reject legacy profiles.

Use client.olap() for full-graph jobs, client.traverser() for immediate OLTP algorithms, and client.rest() when complete server request/response payloads are required.

Schema export uses get_schema() (also available as getSchema()) and always returns the server JSON schema. The legacy getSchema(_format=...) call still accepts its historical argument; schema output remains JSON. It does not convert schema to Groovy. The canonical get_schema() has no format argument. NeighborRankParameters no longer accepts the unsupported top-level label; edge labels belong to its steps. Only source may be positional. Pass alpha, capacity and steps by keyword so legacy NeighborRankParameters(source, label) calls fail explicitly instead of binding label to alpha. NeighborRankStep keeps top as its fourth positional argument; pass the new skip_degree by keyword. Older servers may ignore with_result=false and return the result during task polling.

LLM and ML releases now require hugegraph-python>=1.8.0,<2. LLM backups write native JSON to schema.json. When a same-day backup directory is reused, a stale schema.groovy is removed; historical files in other backup directories are untouched.

HTTP timeouts must be positive, finite values. Unlimited components such as timeout=(5, None) raise ValueError; choose a finite read timeout instead.

Graph helpers omit cursor pagination when a nonzero offset is supplied without page. Combining an explicit page (including "") with nonzero offset raises ValueError.

For JSON REST operations, omitting body sends no entity; explicitly passing body=None sends JSON null. Required request fields remain subject to server validation.