Skip to content

Commit

Permalink
Merge branch 'main' into group-pick
Browse files Browse the repository at this point in the history
  • Loading branch information
BradyAJohnston committed Aug 31, 2024
2 parents cbc88d2 + e80defd commit b4c04ec
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions molecularnodes/entities/molecule/ui.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
import io

from ...download import FileDownloadPDBError, download, CACHE_DIR
from ...blender import path_resolve
from ..ensemble.cif import OldCIF
from .molecule import Molecule
from .pdb import PDB
Expand All @@ -14,9 +15,13 @@


def parse(filepath) -> Molecule:
# TODO: I don't like that we might be dealing with bytes or a filepath here,
# I need to work out a nicer way to have it be cleanly one or the other

if isinstance(filepath, io.BytesIO):
suffix = ".bcif"
else:
filepath = path_resolve(filepath)
suffix = Path(filepath).suffix

parser = {
Expand Down

0 comments on commit b4c04ec

Please sign in to comment.