Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merge compound fix to 1247 #628

Merged
merged 13 commits into from
Aug 1, 2024
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

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
fix: remove version field from ComputedMolecule
Field was added in error, explicit version tracking is not necessary
  • Loading branch information
kaliif committed Jul 10, 2024
commit 9b4a9595a7be7a845cf2128745b721c03eebacd7
2 changes: 0 additions & 2 deletions viewer/cset_upload.py
Original file line number Diff line number Diff line change
@@ -339,7 +339,6 @@ def set_mol(
smiles = Chem.MolToSmiles(mol)
inchi = Chem.inchi.MolToInchi(mol)
molecule_name = mol.GetProp('_Name')
version = mol.GetProp('version')

compound: Compound = self.create_mol(
inchi, compound_set.target, name=molecule_name
@@ -485,7 +484,6 @@ def set_mol(
computed_molecule.pdb = lhs_so
# TODO: this is wrong
computed_molecule.pdb_info = pdb_info
computed_molecule.version = version
# Extract possible reference URL and Rationale
# URLs have to be valid URLs and rationals must contain more than one word
ref_url: Optional[str] = (
1 change: 0 additions & 1 deletion viewer/models.py
Original file line number Diff line number Diff line change
@@ -1027,7 +1027,6 @@ class ComputedMolecule(models.Model):
max_length=255,
help_text="Link to pdb file; user-uploaded pdb or pdb.experiment.pdb_info",
)
version = models.PositiveSmallIntegerField(null=False, default=1)

def __str__(self) -> str:
return f"{self.smiles}"