Hi Ben,
In the current ChimeraX the only option is to use an URL that ends in “.pdb”.  If the ModBase server returned a content-type header (it doesn’t look like it does here), I could put it in the list of mime-types for PDB files, and that would then work.
I mentioned awhile back that I was working on a replacement for the Open/Save/DataFormat bundle_info tags.  In the replacement scheme, this will be possible by specifying the ‘dataFormat’ keyword, e.g. open long-ass-url data pdb.  For technical reasons related to how bundle_info.xml handles data formats, it is not easy to get that to work with the usual ‘format’ keyword.  I did try out your URL in the new scheme and (after some fixes of course!) it did work.  I should note that the retrieved file is actually in HTML with the PDB data embedded between <PRE> </PRE> tags, so the PDB reader does a lot of complaining about “Bad PDB record <HTML>” and so forth, but the structure does open.  Also, the structure has a blank chain ID, which is ugly to use in commands.
We anticipate pushing the revised Open/Save/DataFormat out into the daily build in the 5-to-10-day timeframe.  Initially, the new framework will use the commands “open2” and “save2” and the normal open/save commands will continue to use the old mechanism and work in the same way as before.  The purpose of putting the new scheme out there like that is so that developers can get their bundles to work with the new scheme so that when the changeover actually occurs, those bundles will continue to work.  Also, so that the new scheme can get wider testing.

--Eric

Eric Pettersen
UCSF Computer Graphics Lab


On Mar 24, 2020, at 1:27 PM, Elaine Meng <meng@cgl.ucsf.edu> wrote:

Hi Ben,
Sorry about that, specifying format with an URL either changed or I misunderstood when it was explained to me!  I will remove the  text saying the "format" command-line option can be used with an URL.

I personally have only used the suffix method with an URL.

In the meanwhile, Eric is looking up some things and will be responding further.
Best,
Elaine
-----
Elaine C. Meng, Ph.D.                       
UCSF Chimera(X) team
Department of Pharmaceutical Chemistry
University of California, San Francisco


On Mar 24, 2020, at 1:10 PM, Ben Webb <ben@salilab.org> wrote:

On 3/24/20 1:05 PM, Elaine Meng wrote:
You can put the word "download" in the "a href" tag to specify it is
file for download rather than to show... for example, see link to
"test.cxc" in this page, as well as its source: <http://www.cgl.ucsf.edu/home/meng/t1.html>

Maybe I wasn't clear here but I am running these commands from the
ChimeraX command line (or putting them in a .cxc file). I am not writing
a web page. That 'test.cxc' you reference opens PDB IDs, not https: URLs.

Maybe you are looking at Chimera help?

No, I'm looking at help:user/commands/open.html#url in the ChimeraX browser.

Ben


_______________________________________________
ChimeraX-users mailing list
ChimeraX-users@cgl.ucsf.edu
Manage subscription:
http://www.rbvi.ucsf.edu/mailman/listinfo/chimerax-users