Opened 10 years ago

Closed 10 years ago

#11496 closed task (duplicate)

Add jmol script in SAGE_ROOT/local/bin to hg and update

Reported by: gutow Owned by: tbd
Priority: major Milestone: sage-duplicate/invalid/wontfix
Component: distribution Keywords: command line jmol
Cc: mhansen Merged in:
Authors: Reviewers: John Palmieri
Report Upstream: N/A Work issues:
Branch: Commit:
Dependencies: Stopgaps:

Status badges

Description (last modified by gutow)

ONLY TO BE APPLIED IF YOU USE THE FLASK NOTEBOOK WITH THE NEW JMOL .SPKG (#11503). BOTH ARE REQUIRED.

With the change to the Flask notebook jmol is moving to the directory SAGE_LOCAL/share. This requires changes to the script that launches Jmol from the command line. Attached is a trac_11496_add_jmol_script.patch that adds the updated file to the hg repository for the local/bin directory. Don't know why it wasn't tracked in the past.

NOTE: If you get errors upon trying to apply this patch.  Simply replace the jmol script file with the contents of this patch.  There seem to be issues depending upon whether your installation is tracking this file or not.  It should be added to the Hg repository in the next release.

Related & Referring tickets:

Attachments (1)

trac_11496_add_jmol_script.patch (920 bytes) - added by gutow 10 years ago.
jmol script into hg repository to go with flask changes

Download all attachments as: .zip

Change History (15)

Changed 10 years ago by gutow

jmol script into hg repository to go with flask changes

comment:1 Changed 10 years ago by gutow

  • Cc mhansen added
  • Description modified (diff)
  • Status changed from new to needs_review

comment:2 Changed 10 years ago by gutow

  • Description modified (diff)

comment:3 follow-up: Changed 10 years ago by mariah

  • Status changed from needs_review to needs_info

When I tried to apply the patch to sage-4.7.1.alpha1 with hg_scripts.apply() it failed:

sage: hg_scripts.apply("/home/mariah/trac_11496_add_jmol_script.patch")
cd "/home/mariah/sage/sage-4.7.1.alpha2-x86_64-Linux-core2-fc/local/bin" && hg status
cd "/home/mariah/sage/sage-4.7.1.alpha2-x86_64-Linux-core2-fc/local/bin" && hg status
cd "/home/mariah/sage/sage-4.7.1.alpha2-x86_64-Linux-core2-fc/local/bin" && hg import   "/home/mariah/trac_11496_add_jmol_script.patch"
applying /home/mariah/trac_11496_add_jmol_script.patch
file jmol already exists
1 out of 1 hunks FAILED -- saving rejects to file jmol.rej
abort: patch failed to apply
sage:

Am I misunderstanding something?

comment:4 in reply to: ↑ 3 Changed 10 years ago by gutow

  • Status changed from needs_info to needs_review

It appears that this change may already be in 4.7.1.alpha2...check manually that the script is there and matches what is in the patch. Replying to mariah:

When I tried to apply the patch to sage-4.7.1.alpha1 with hg_scripts.apply() it failed:

sage: hg_scripts.apply("/home/mariah/trac_11496_add_jmol_script.patch")
cd "/home/mariah/sage/sage-4.7.1.alpha2-x86_64-Linux-core2-fc/local/bin" && hg status
cd "/home/mariah/sage/sage-4.7.1.alpha2-x86_64-Linux-core2-fc/local/bin" && hg status
cd "/home/mariah/sage/sage-4.7.1.alpha2-x86_64-Linux-core2-fc/local/bin" && hg import   "/home/mariah/trac_11496_add_jmol_script.patch"
applying /home/mariah/trac_11496_add_jmol_script.patch
file jmol already exists
1 out of 1 hunks FAILED -- saving rejects to file jmol.rej
abort: patch failed to apply
sage:

Am I misunderstanding something?

comment:5 follow-up: Changed 10 years ago by mariah

  • Status changed from needs_review to needs_work

They differ slightly (myjmol is the code in the patch):

eno% pwd
/home/mariah/sage/sage-4.7.1.alpha2-x86_64-Linux-core2-fc/local/bin
eno% diff jmol ~/myjmol
3c3
< JMOL_HOME="`"$SAGE_LOCAL"/bin/sage-pypkg-location sagenb`""/sagenb/data/jmol"
---
> JMOL_HOME="$SAGE_LOCAL/share/jmol"
eno%

comment:6 in reply to: ↑ 5 Changed 10 years ago by gutow

I'm not quite sure how to respond.  As of 4.7 (the last official release) that script was not included in the mercurial repository.  Am I expected to modify my patches to keep up with test releases?  

That said, If you are setting up to use the Flask notebook and the new release of Jmol, you need to have the version in my patch not the one that points to sagenb/data/jmol as that directory no longer exists.

I suggest patching by hand.

Replying to mariah:

They differ slightly (myjmol is the code in the patch): {{{ eno% pwd /home/mariah/sage/sage-4.7.1.alpha2-x86_64-Linux-core2-fc/local/bin eno% diff jmol ~/myjmol 3c3 < JMOL_HOME=""$SAGE_LOCAL"/bin/sage-pypkg-location sagenb""/sagenb/data/jmol" ---

JMOL_HOME="$SAGE_LOCAL/share/jmol"

eno% }}}

comment:7 Changed 10 years ago by gutow

  • Description modified (diff)

comment:8 Changed 10 years ago by gutow

  • Status changed from needs_work to needs_review

comment:9 follow-up: Changed 10 years ago by jhpalmieri

  • Status changed from needs_review to needs_info

I think that this isn't implemented correctly. First, the reason that the jmol script is not tracked in the scripts repo is that it is installed there by the sagenb spkg. So I think that the jmol script should be installed either by the sagenb spkg, or, even better, by the new jmol spkg from #11503. In fact, it looks like the script is already part of that spkg; you just have to write it to the correct place in the spkg-install file.

I may be confused, though, so if you have a different opinion, please let me know.

comment:10 in reply to: ↑ 9 Changed 10 years ago by gutow

I believe this is a good idea.  As soon as I've changed the .spkg (see #11503) this ticket should be closed.

Replying to jhpalmieri:

I think that this isn't implemented correctly. First, the reason that the jmol script is not tracked in the scripts repo is that it is installed there by the sagenb spkg. So I think that the jmol script should be installed either by the sagenb spkg, or, even better, by the new jmol spkg from #11503. In fact, it looks like the script is already part of that spkg; you just have to write it to the correct place in the spkg-install file. I may be confused, though, so if you have a different opinion, please let me know.

comment:11 Changed 10 years ago by gutow

  • Status changed from needs_info to needs_review

Should be closed because this is now subsumed by #11503...

comment:12 Changed 10 years ago by jhpalmieri

  • Status changed from needs_review to positive_review

To the release manager: please close this as a duplicate of #11503.

comment:13 Changed 10 years ago by jdemeyer

  • Authors gutow deleted
  • Milestone changed from sage-4.7.1 to sage-duplicate/invalid/wontfix
  • Reviewers set to John Palmieri

comment:14 Changed 10 years ago by jdemeyer

  • Resolution set to duplicate
  • Status changed from positive_review to closed
Note: See TracTickets for help on using tickets.