Git Product home page Git Product logo

Comments (10)

lboxell avatar lboxell commented on August 17, 2024

Note that our current release protocol has an issue when objects have the same name, but different paths. See below code for what should fix it:

    if DriveReleaseFiles != '':
        env.Alias('drive', local_release)
        DrivePath = DriveReleaseFiles
        for i in range(len(DriveReleaseFiles)):
            env.Install(os.path.join(local_release, os.path.dirname(DriveReleaseFiles[i])), DriveReleaseFiles[i])
            path         = DriveReleaseFiles[i]
            DrivePath[i] = 'release/%s/%s/%s' % (dir_name, vers, path)
        with open('gdrive_assets.txt', 'w') as f:
            f.write('\n'.join(['Google Drive:'] + DrivePath))
        upload_asset(token, org, repo, release_id, 'gdrive_assets.txt')
        os.system('rm gdrive_assets.txt')

from gslab_python.

lboxell avatar lboxell commented on August 17, 2024

From gslab-econ/template#19 (comment), we also want a tool that checks the size of files that will be versioned in release.

I do think we should impose a cap as a default, though we can decide to break it in special cases. Maybe 2 MB? That should give us room to store PDFs but not let us store anything that's going to impose a significant cost. We may also want to impose a separate cap on the total size of the /release/ directory that can be versioned. Maybe 500 MB?

If we impose a cap, we should think about if there's a way to enforce it with code. One possibility is to write a little python script that walks the release directory skipping things in .gitignore, then outputs a warning if you're over the cap. A second is to use some kind of commit hook in Git. I think I like the warning version better since it's less likely to be a source of bugs and it will be easy to override if we want to.

from gslab_python.

M-R-Sullivan avatar M-R-Sullivan commented on August 17, 2024

I am going to start working on this.

from gslab_python.

lboxell avatar lboxell commented on August 17, 2024

Per conversation today at noodles, we probably want some functionality that allows for zipping files in the release.

from gslab_python.

M-R-Sullivan avatar M-R-Sullivan commented on August 17, 2024

Update: this task is under peer review at #36.

from gslab_python.

M-R-Sullivan avatar M-R-Sullivan commented on August 17, 2024

Update: this task is under peer review at #36.

from gslab_python.

qlquanle avatar qlquanle commented on August 17, 2024

With #36 pulled in, is this issue completed?

from gslab_python.

M-R-Sullivan avatar M-R-Sullivan commented on August 17, 2024

@stanfordquan - No, as I still need to look into an error that @arosenbe encountered in this issue's /template/ pull request. If the completion of this issue is a prerequisite for a priority of yours, I can focus on resolving this error in coming work hours.

from gslab_python.

qlquanle avatar qlquanle commented on August 17, 2024

Not at all, don't worry. I looked over the commit history and looks like unit tests are done and dusted, so I don't need to work on that! Thanks.

from gslab_python.

M-R-Sullivan avatar M-R-Sullivan commented on August 17, 2024

This issue has passed peer review at #36 and gslab-econ/template#21. So I am closing it now.

Summary

  • I released GSLab Tools 3.0.0, which adds functionality for making releases from SCons/GitHub repositories to GitHub and to Google Drive to gslab_scons. This functionality is described in gslab_scons/README.md.
  • The release.py script gslab_scons checks that versioned files are not overly large and that the repository from which the user is making a release is up-to-date (i.e. that SCons has built all of the repository's targets and that changes have been committed with git).
  • I revised code in the large template to be compatible with gslab_scons's new release functionality.

from gslab_python.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.