Skip to content

BETYdb 4.20 Upgrade to Rails 4.2

Compare
Choose a tag to compare
@gsrohde gsrohde released this 15 Mar 20:47
· 369 commits to master since this release
a763a49

Upgrade to Rails 4.2; several bug fixes.

Summary of Changes

This release upgrades the version of Rails used from 3.2 to 4.2.

New features

  • Added Rake tasks for dumping and updating SQL comments using YAML files (issue #542 and pull request #543).

  • On the Advanced Search page, traits and yields are now searchable by method name (pull request #506)

  • When creating or editing Managements, possible management types now include "thining" and "other" (pull request #546).

Bug fixes

  • Issue #533 ("Trait/entity notes don't get populated through Bulk Upload Wizard")

    If a Bulk Upload file has a "notes" column, those notes now show up in the newly-created traits or yields.

  • Issue #552 ("Travis fails trying to create postgis extension.")

    Travis now runs RSpec successfully so builds no longer always fail.

Other Changes

  • Updated DBMS named in the README file from MySQL to PostgreSQL (long overdue).

  • Docker cleanup (pull requests #537 and #550).

Steps Needed for Upgrade

  1. Log in to the server.
  2. cd to the Rails root directory.
  3. Run git pull to get the lastest version of the master branch.
  4. Run bundle to upgrade several Gems (including Rails itself) and to add new Gems that are no longer part of Rails proper are that are needed to support legacy Rails behaviors until code is updated to no longer need this legacy support.
  5. The file config/secrets.yml expects a variable called SECRET_KEY_BASE to be in the environment. To generate a suitable value for this variable, run rake secret.
  6. Ensure this variable is in the environment seen by the HTTP server. If you run your BETYdb app under Apache HTTP server, one way to do this is to put a directive of the form
SetEnv SECRET_KEY_BASE some_secret_key

in the <Directory> section of the configuration file corresponding to the BETYdb instance you have deployed.
7. Restart the HTTP server, e.g. sudo apachectl restart.

[In lieu of steps 6 and 7, you could also edit config/secrets.yml directly, replacing

<%= ENV["SECRET_KEY_BASE"] %>

with the value you generated in step 5; then restart PhusionPassenger by running touch tmp/restart.txt. This is not the preferred way of doing things, however, since Git will then always show this file as modified.]

Status of RSpec Tests

All non-pending tests pass when run in the default environment. (There is one pending test having to do with site-group editing permissions.)

Complete details for running the RSpec tests are at https://pecan.gitbooks.io/betydb-documentation/content/automated_tests.html.