Skip to content

Commit

Permalink
maint: Upgrade to higlass-python v1.0 (#89)
Browse files Browse the repository at this point in the history
* maint: Upgrade to higlass-python v1.0

* chore: Update changelog

* maint: fix dep syntax for install_requires
  • Loading branch information
nvictus authored Jul 6, 2023
1 parent 5d8176b commit 237aff2
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 20 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
v0.8.2

- Use new higlass-python v1.0 API

v0.8.0

- Ran black on the entire code base
Expand Down
26 changes: 8 additions & 18 deletions higlass_manage/view.py
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,7 @@ def view(
# couldn't ingest the file
return

from higlass.client import Track, View, ViewConf
import higlass as hg

if datatype is None:
datatype = inferred_datatype
Expand All @@ -166,25 +166,15 @@ def view(
print("ERROR: Unknown track type for the given datatype:", datatype)
return

view = View(
[
Track(
track_type=tracktype,
position=position,
tileset_uuid=uuid,
server="http://localhost:{}/api/v1/".format(port),
height=200,
),
]
tileset = hg.remote(
uid=uuid,
server="http://localhost:{}/api/v1/".format(port),
)
track = tileset.track(tracktype, position=position, height=200)
view = hg.view(track)
conf = view.viewconf().dict()

viewconf = ViewConf([view])

conf = viewconf.to_dict()

conf["trackSourceServers"] = []
conf["trackSourceServers"] += ["http://localhost:{}/api/v1/".format(port)]

conf["trackSourceServers"] = ["http://localhost:{}/api/v1/".format(port)]
if public_data:
conf["trackSourceServers"] += ["http://higlass.io/api/v1/"]

Expand Down
2 changes: 1 addition & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
clodius==0.10.13
higlass-python==0.1.13
higlass-python==1.0.0
docker==4.0.2
ipywidgets==7.5.1
slugid==2.0.0
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
"clodius>=0.10.3",
"cooler>=0.8.1",
"pandas>=0.19",
"higlass-python==0.4.4",
"higlass-python>=1.0.0",
"docker",
"requests",
],
Expand Down

0 comments on commit 237aff2

Please sign in to comment.