Opened 7 years ago

Closed 7 years ago

Last modified 6 years ago

#17490 closed defect (fixed)

Fix tar issue in sagenb

Reported by: kcrisman Owned by:
Priority: blocker Milestone: sage-duplicate/invalid/wontfix
Component: notebook Keywords:
Cc: dimpase Merged in:
Authors: Reviewers: Jeroen Demeyer
Report Upstream: N/A Work issues:
Branch: Commit:
Dependencies: Stopgaps:

Status badges

Description

If someone uses BSD tar (the default on Mac) to tar up an spkg, it can cause problems on some Linux setups. See e.g. https://groups.google.com/forum/#!topic/sage-support/IZHC1QeFqBI but also many in the past.

Change History (15)

comment:1 Changed 7 years ago by kcrisman

  • Cc dimpase added

comment:2 follow-up: Changed 7 years ago by jdemeyer

What about using https://docs.python.org/2/library/tarfile.html#module-tarfile to create the tar file?

comment:3 in reply to: ↑ 2 Changed 7 years ago by dimpase

Replying to jdemeyer:

What about using https://docs.python.org/2/library/tarfile.html#module-tarfile to create the tar file?

Should be doable - and actually should be put into the spk-src script, as the creation of the spkg for sagenb is not trivial...

comment:4 follow-up: Changed 7 years ago by kcrisman

Currently upstream says

mv dist sagenb-<version>
tar cf sagenb-<version>.tar sagenb-<version>
mv sagenb-<version>.tar SAGE_ROOT/upstream

but if that were put into an spkg-src script that would be fine. Or maybe the gz file that comes out of dist.sh is enough?

Ideally this would go in #10057.

comment:5 in reply to: ↑ 4 Changed 7 years ago by dimpase

Replying to kcrisman:

Currently upstream says

mv dist sagenb-<version>
tar cf sagenb-<version>.tar sagenb-<version>
mv sagenb-<version>.tar SAGE_ROOT/upstream

but if that were put into an spkg-src script that would be fine. Or maybe the gz file that comes out of dist.sh is enough?

this looks good (I presume that https://docs.python.org/2/distutils/sourcedist.html does call python's tar rather than the system tar). You might also want to add option to make tar file rather than tar.gz file.

So, why did you do the tarball creation manually rather than using this script?

comment:6 follow-up: Changed 7 years ago by kcrisman

?? That is not a script! It is just instructions. I am just following instructions from kini and ppurka I know "work", for some value of work. I didn't have time to test all these other issues. I will be happy to look at a pull request to change those instructions, especially as I think you have access to a Mac and can test the difference.

comment:7 in reply to: ↑ 6 Changed 7 years ago by dimpase

Replying to kcrisman:

?? That is not a script! It is just instructions.

I meant dist.sh as linked above.

comment:8 follow-up: Changed 7 years ago by kcrisman

I did use dist.sh, but then the instructions said to do this too ... so I did, because I didn't want to miss something. I believe that the tar.gz in the dist is only the sagenb code proper, and the various dependencies are separately in dist. So then the whole thing needs to be tarred up. I didn't come up with this distribution scheme, for the record! See #17306 for a first step in possibly going back to making this part of Sage...

comment:9 in reply to: ↑ 8 ; follow-up: Changed 7 years ago by dimpase

Replying to kcrisman:

I did use dist.sh, but then the instructions said to do this too ... so I did, because I didn't want to miss something. I believe that the tar.gz in the dist is only the sagenb code proper, and the various dependencies are separately in dist. So then the whole thing needs to be tarred up.

Yeah, that's right. Why don't we write the spkg-src (python, or your other favourite language that has its own GNU-compatible tar?) script based on these?

I didn't come up with this distribution scheme, for the record! See #17306 for a first step in possibly going back to making this part of Sage...

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

I did use dist.sh, but then the instructions said to do this too ... so I did, because I didn't want to miss something. I believe that the tar.gz in the dist is only the sagenb code proper, and the various dependencies are separately in dist. So then the whole thing needs to be tarred up.

Yeah, that's right. Why don't we write the spkg-src (python, or your other favourite language that has its own GNU-compatible tar?) script based on these?

Go ahead! I will review if you do.

comment:11 Changed 7 years ago by kcrisman

In the meantime, as a partial (?) fix, I have committed this release instructions update, however, it will not be "officially in" #10057 (though I used its advice).

comment:12 Changed 7 years ago by jdemeyer

  • Milestone changed from sage-6.5 to sage-duplicate/invalid/wontfix
  • Reviewers set to Jeroen Demeyer
  • Status changed from new to needs_review

Fixed by #10057.

comment:13 Changed 7 years ago by jdemeyer

  • Status changed from needs_review to positive_review

comment:14 Changed 7 years ago by vbraun

  • Resolution set to fixed
  • Status changed from positive_review to closed

comment:15 Changed 6 years ago by kcrisman

Yet another report so I guess this was quite a problem...

Note: See TracTickets for help on using tickets.