Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
flexible insertion into neo4j
  • Loading branch information
007vasy committed Apr 6, 2020
commit 4e6c3ec5cf3eb7c023119ba99d79d26081d1363d
46 changes: 10 additions & 36 deletions modules/TempNB/IngestDrugSynonyms.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -627,18 +627,9 @@
},
{
"cell_type": "code",
"execution_count": 92,
"execution_count": 94,
"metadata": {},
"outputs": [
{
"ename": "IndentationError",
"evalue": "expected an indented block (<ipython-input-92-e0c906e8b534>, line 14)",
"output_type": "error",
"traceback": [
"\u001b[0;36m File \u001b[0;32m\"<ipython-input-92-e0c906e8b534>\"\u001b[0;36m, line \u001b[0;32m14\u001b[0m\n\u001b[0;31m resp = session.write_transaction(self._merge_node, message)\u001b[0m\n\u001b[0m ^\u001b[0m\n\u001b[0;31mIndentationError\u001b[0m\u001b[0;31m:\u001b[0m expected an indented block\n"
]
}
],
"outputs": [],
"source": [
"class DrugSynonymDataToNeo4j(object):\n",
"\n",
Expand Down Expand Up @@ -669,7 +660,7 @@
" @staticmethod\n",
" def _merge_node(tx, node_type, properties=None):\n",
" data:dict = {\n",
" \"node_type\":node_type\n",
" \"node_type\":node_type,\n",
" \"properties\":self._dict_to_property_str(properties)\n",
" }\n",
" # '{first} {last}'.format(**data)\n",
Expand Down Expand Up @@ -718,41 +709,24 @@
},
{
"cell_type": "code",
"execution_count": 88,
"execution_count": 95,
"metadata": {},
"outputs": [],
"source": [
"test:dict = {\n",
" \"a\":\"B\",\n",
" \"c\":\"D\",\n",
"}"
]
"source": []
},
{
"cell_type": "code",
"execution_count": 90,
"execution_count": 96,
"metadata": {},
"outputs": [],
"source": [
"asd = \"asd,\""
]
"source": []
},
{
"cell_type": "code",
"execution_count": 91,
"execution_count": null,
"metadata": {},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"asd}\n"
]
}
],
"source": [
"print(asd[:-1]+\"}\")"
]
"outputs": [],
"source": []
},
{
"cell_type": "code",
Expand Down