molstar / VSCoding-Sequence

VSCode Extension for interactively visualising protein structure data in the editor
MIT License
101 stars 9 forks source link

The wrong PDB is opened #37

Closed FlorisLoffler closed 1 week ago

FlorisLoffler commented 1 week ago

When I try to open the file https://www.rcsb.org/structure/3nty , so 3NTY, it instead opens 1TQN. I can't change this anywhere, and the fact that protein viewer also doesn't have any adjustable settings makes this harder to solve.

a-r-j commented 1 week ago

Hi @FlorisLoffler I'm struggling to reproduce this behaviour. How are you launching the viewer? Are you using the command palette or right-clicking on the PDB file?

FlorisLoffler commented 1 week ago

I first download the PDB file for 3NTY. I then open Visual Studio Code, and open the folder in which I have downloaded the file, using the explorer. I then hover over the file and click "Launch protein viewer from Files". The protein viewer then opens, but instead of showing 3NTY, I see 1tqn (Which is the protein itself, without any ligands or other groups). If I click on the home button, I actually see that it says "PDB Id(s) 1tqn", which is weird as I have not downloaded 1tqn nor anything named 1tqn.

a-r-j commented 1 week ago

I see! Thanks for flagging.

So, I don't think it's actually loading 1tqn -- I think it is in fact loading 3nty. If you load both structures in the same session you can see they are different (e.g. the sequences are different & look at the span of missing residues between S260 -> S265 in 1tqn). The pdb code in the home panel is just a 'suggestion' to load a related structure I believe.

What is strange though is that it isn't loading the heteroatoms when loading 3nty. I tried it with a newer Mol* version and it behaves as expected. I'll push an update this week. Thanks again for catching this -- very strange!

FlorisLoffler commented 1 week ago

Thank you for your fast responses.