Skip to content

Commit

Permalink
Cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
mattjala committed Jun 6, 2024
1 parent db1cdcd commit e97ade9
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 8 deletions.
8 changes: 4 additions & 4 deletions h5pyd/_hl/group.py
Original file line number Diff line number Diff line change
Expand Up @@ -679,7 +679,7 @@ def __getitem__(self, name, track_order=False):
tgt._name = name
return tgt

def objectify_link_json(self, link_json):
def _objectify_link_Json(self, link_json):
if "id" in link_json:
link_obj = HardLink(link_json["id"])
elif "h5path" in link_json and "h5domain" not in link_json:
Expand All @@ -695,7 +695,7 @@ def get(self, name, default=None, getclass=False, getlink=False, track_order=Fal
""" Retrieve an item or other information.
"name" given only:
Return the item, or "default" if it doesn't exist
Return the item with the given name, or "default" if nothing with that name exists
"getclass" is True:
Return the class of object (Group, Dataset, etc.), or "default"
Expand Down Expand Up @@ -798,13 +798,13 @@ def get(self, name, default=None, getclass=False, getlink=False, track_order=Fal
group_links = {}

for link in links[group_id]:
group_links[link["title"]] = self.objectify_link_json(link)
group_links[link["title"]] = self._objectify_link_Json(link)

links_out[group_id] = group_links

else:
for link in links:
links_out[link["title"]] = self.objectify_link_json(link)
links_out[link["title"]] = self._objectify_link_Json(link)
else:
raise ValueError("Can't parse server response to links query")

Expand Down
4 changes: 0 additions & 4 deletions test/hl/test_group.py
Original file line number Diff line number Diff line change
Expand Up @@ -275,9 +275,6 @@ def get_count(grp):
count += 1
return count
# create a file for use as a link target
if config.get("use_h5py"):
# for some reason this test is failing in Travis
return
filename = self.getFileName("test_link_removal")
print(f"filename: {filename}")

Expand Down Expand Up @@ -382,7 +379,6 @@ def test_link_multi_create(self):
for i in range(num_links, 2 * num_links):
if i % 2 == 0:
new_link = h5py.SoftLink("dummy_path_" + str(i))
# links.append({"h5path": "dummy_path_" + str(i)})
else:
# Hard link to g1
new_link = g1
Expand Down

0 comments on commit e97ade9

Please sign in to comment.