8000 Merge pull request #3495 from DMPRoadmap/development · DMPRoadmap/roadmap@6ec8ba0 · GitHub
[go: up one dir, main page]

Skip to content

Commit 6ec8ba0

Browse files
authored
Merge pull request #3495 from DMPRoadmap/development
Merge `development` Into `main` For Upcoming Release
2 parents fc047ac + 3506e05 commit 6ec8ba0
  • plans
  • questions
  • templates
  • research_outputs
  • super_admin/api_clients
  • bin
  • config
  • db
  • lib/tasks
  • spec
  • Some content is hidden

    Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

    78 files changed

    +3092
    -2268
    lines changed

    .github/workflows/brakeman.yml

    Lines changed: 1 addition & 1 deletion
    Original file line numberDiff line numberDiff line change
    @@ -8,7 +8,7 @@ on:
    88
    jobs:
    99
    brakeman:
    1010

    11-
    runs-on: ubuntu-20.04
    11+
    runs-on: ubuntu-24.04
    1212

    1313
    steps:
    1414
    - uses: actions/checkout@v2

    .github/workflows/danger.yml

    Lines changed: 4 additions & 4 deletions
    Original file line numberDiff line numberDiff line change
    @@ -4,19 +4,19 @@ on: [push, pull_request]
    44

    55
    jobs:
    66
    danger:
    7-
    runs-on: ubuntu-20.04
    7+
    runs-on: ubuntu-24.04
    88

    99
    steps:
    1010
    - uses: actions/checkout@v3
    1111

    1212
    - name: 'Determine Ruby and Bundler Versions from Gemfile.lock'
    1313
    run: |
    14-
    echo "RUBY_VERSION=`cat ./Gemfile.lock | grep -A 1 'RUBY VERSION' | grep 'ruby' | grep -oE '[0-9]\.[0-9]'`" >> $GITHUB_ENV
    15-
    echo "BUNDLER_VERSION=`cat ./Gemfile.lock | grep -A 1 'BUNDLED WITH' | grep -oE '[0-9]\.[0-9]'`" >> $GITHUB_ENV
    14+
    echo "RUBY_VERSION=`cat ./Gemfile.lock | grep -A 1 'RUBY VERSION' | grep 'ruby' | grep -oE '[0-9]+\.[0-9]+\.[0-9]+'`" >> $GITHUB_ENV
    15+
    echo "BUNDLER_VERSION=`cat ./Gemfile.lock | grep -A 1 'BUNDLED WITH' | grep -oE '[0-9]+\.[0-9]+\.[0-9]+'`" >> $GITHUB_ENV
    1616
    1717
    # Install Ruby - using the version found in the Gemfile.lock
    1818
    - name: 'Install Ruby'
    19-
    uses: actions/setup-ruby@v1
    19+
    uses: ruby/setup-ruby@v1
    2020
    with:
    2121
    ruby-version: ${{ env.RUBY_VERSION }}
    2222

    .github/workflows/eslint.yml

    Lines changed: 1 addition & 1 deletion
    Original file line numberDiff line numberDiff line change
    @@ -5,7 +5,7 @@ on: [push, pull_request]
    55
    jobs:
    66
    eslint:
    77

    8-
    runs-on: ubuntu-20.04
    8+
    runs-on: ubuntu-24.04
    99

    1010
    steps:
    1111
    # Checkout the repo

    .github/workflows/mysql.yml

    Lines changed: 4 additions & 4 deletions
    Original file line numberDiff line numberDiff line change
    @@ -4,7 +4,7 @@ on: [pull_request]
    44

    55
    jobs:
    66
    mysql:
    7-
    runs-on: ubuntu-20.04
    7+
    runs-on: ubuntu-24.04
    88

    99
    # Define environment variables for MySQL and Rails
    1010
    env:
    @@ -38,7 +38,7 @@ jobs:
    3838
    3939
    # Stub out the Rails credentials file so that we can start the Rails app
    4040
    - name: 'Setup Credentials'
    41-
    run: EDITOR='echo "$(cat config/credentials.yml.mysql2)" >' bundle exec rails credentials:edit
    41+
    run: EDITOR="sh -c 'echo \"$(cat config/credentials.yml.mysql2)\" > \$1' --" bundle exec rails credentials:edit
    4242

    4343
    # Set the path to the wkhtmltopdf executable
    4444
    - name: 'Determine wkhtmltopdf location'
    @@ -54,8 +54,8 @@ jobs:
    5454

    5555
    - name: 'Build out the test database'
    5656
    run: |
    57-
    bundle exec rails db:create RAILS_ENV=test
    58-
    bundle exec rails db:schema:load RAILS_ENV=test
    57+
    DISABLE_SPRING=1 bundle exec rails db:create RAILS_ENV=test
    58+
    DISABLE_SPRING=1 bundle exec rails db:schema:load RAILS_ENV=test
    5959
    6060
    - name: 'Run any pending database migrations'
    6161
    run: bin/rails db:migrate RAILS_ENV=test

    .github/workflows/postgres.yml

    Lines changed: 22 additions & 4 deletions
    Original file line numberDiff line numberDiff line change
    @@ -4,7 +4,7 @@ on: [pull_request]
    44

    55
    jobs:
    66
    postgresql:
    7-
    runs-on: ubuntu-20.04
    7+
    runs-on: ubuntu-24.04
    88

    99
    services:
    1010
    # Postgres installation
    @@ -27,6 +27,7 @@ jobs:
    2727
    env:
    2828
    RAILS_ENV: test
    2929
    DATABASE_URL: postgres://postgres:@localhost:5432/roadmap_test
    30+
    DISABLE_SPRING: 1
    3031

    3132
    steps:
    3233
    # Checkout the repo
    @@ -52,6 +53,11 @@ jobs:
    5253
    run: |
    5354
    sudo apt-get update
    5455
    sudo apt-get install libpq-dev
    56+
    57+
    # Install ImageMagick (for `identify` command)
    58+
    - name: 'Install ImageMagick'
    59+
    run: |
    60+
    sudo apt-get install -y imagemagick
    5561
    5662
    # Copy all of the example configs over
    5763
    - name: 'Setup Default Configuration'
    @@ -65,7 +71,7 @@ jobs:
    6571
    - name: 'Setup Credentials'
    6672
    run: |
    6773
    # generate a default credential file and key
    68-
    EDITOR='echo "$(cat config/credentials.yml.postgresql)" >' bundle exec rails credentials:edit
    74+
    EDITOR="sh -c 'echo \"$(cat config/credentials.yml.postgresql)\" > \$1' --" bundle exec rails credentials:edit
    6975
    7076
    # Set the path to the wkhtmltopdf executable
    7177
    - name: 'Determine wkhtmltopdf location'
    @@ -75,12 +81,24 @@ jobs:
    7581
    - name: 'Yarn Install'
    7682
    run: |
    7783
    yarn install
    84+
    85+
    # TEMPORARY WORKAROUND FOR THE FOLLOWING ISSUE: https://github.com/DMPRoadmap/roadmap/issues/3485
    86+
    # Remove this once our tests are compatible with the new version of Chrome
    87+
    # Source: https://github.com/teamcapybara/capybara/issues/2800#issuecomment-2731100953
    88+
    - name: Remove image-bundled Chrome
    89+
    run: sudo apt-get purge google-chrome-stable
    90+
    - name: Setup stable Chrome
    91+
    uses: browser-actions/setup-chrome@v1
    92+
    with:
    93+
    chrome-version: 128
    94+
    install-chromedriver: true
    95+
    install-dependencies: true
    7896

    7997
    # Initialize the DB
    8098
    - name: 'Setup Test DB'
    8199
    run: |
    82-
    bundle exec rails db:setup RAILS_ENV=test
    83-
    bundle exec rails db:migrate RAILS_ENV=test
    100+
    bundle exec rails db:setup
    101+
    bundle exec rails db:migrate
    84102
    85103
    # Prebuild the CSS, JS and image assets
    86104
    - name: 'Compile Assets'

    .github/workflows/rubocop.yml

    Lines changed: 1 addition & 1 deletion
    Original file line numberDiff line numberDiff line change
    @@ -4,7 +4,7 @@ on: [push, pull_request]
    44

    55
    jobs:
    66
    rubocop:
    7-
    runs-on: ubuntu-20.04
    7+
    runs-on: ubuntu-24.04
    88

    99
    steps:
    1010
    # Checkout the repo

    .rubocop.yml

    Lines changed: 1 addition & 1 deletion
    Original file line numberDiff line numberDiff line change
    @@ -23,7 +23,7 @@
    2323
    #
    2424
    # Try to place any new Cops under their relevant section and in alphabetical order
    2525

    26-
    require:
    26+
    plugins:
    2727
    # - rubocop-rails
    2828
    # - rubocop-rspec
    2929
    - rubocop-performance

    CHANGELOG.md

    Lines changed: 16 additions & 0 deletions
    Original file line numberDiff line numberDiff line change
    @@ -1,5 +1,21 @@
    11
    # Changelog
    22

    3+
    - Updated app to Rails 7 [#3426](https://github.com/DMPRoadmap/roadmap/pull/3426), [#3496](https://github.com/DMPRoadmap/roadmap/pull/3496)
    4+
    - Address Some Bullet Warnings / Optimise Mean Request Times [#3440](https://github.com/DMPRoadmap/roadmap/pull/3440)
    5+
    - Fix Flaky Tests / Optimize Checking of `plan.title` Within `spec/features/plans/exports_spec.rb` [#3451](https://github.com/DMPRoadmap/roadmap/pull/3451)
    6+
    - Refactor Plan.deep_copy(plan) [#3469](https://github.com/DMPRoadmap/roadmap/pull/3469)
    7+
    - Fixed a bug in the deep copy of plans where the old identifier was being copied into the new plan. We now copy the generated id of the new plan to the identifier field.
    8+
    - Fixed bar chart click function in the Usage dashboard (GitHub issue #3443)
    9+
    - Fixed broken link for the V1 API documentation.
    10+
    - Fix `hidden_field_tag` Nested Attributes Format For Rails 7 Upgrade and Add Test Coverage [#3479](https://github.com/DMPRoadmap/roadmap/pull/3479)
    11+
    - Update all workflows to `runs-on: ubuntu-24.04` and Consolidate Capybara Config [#3487](https://github.com/DMPRoadmap/roadmap/pull/3487)
    12+
    - Add pdf handling in `render_respond_to_format_with_error_message` [#3482](https://github.com/DMPRoadmap/roadmap/pull/3482)
    13+
    - Lower PostgreSQL GitHub Action Chrome Version to Address Breaking Changes Between Latest Chrome Version (134) and `/features` Tests [#3491](https://github.com/DMPRoadmap/roadmap/pull/3491)
    14+
    - Bumped dependencies via `bundle update && yarn upgrade` [#3483](https://github.com/DMPRoadmap/roadmap/pull/3483)
    15+
    - Fixed issues with Conditional Question serialization offered by @briri from PR https://github.com/CDLUC3/dmptool/pull/667 for DMPTool. There is a migration file with code for MySQL and Postgres to update the Conditions table to convert JSON Arrays in string format records in the conditions table so that they are JSON Arrays.
    16+
    - Refactor `org_admin/conditions/_form.html.erb` [#3502](https://github.com/DMPRoadmap/roadmap/pull/3502)
    17+
    - Refactor `Question.save_condition` [#3501](https://github.com/DMPRoadmap/roadmap/pull/3501)
    18+
    319
    ## v4.2.0
    420

    521
    **Note this upgrade is mainly a migration from Bootstrap 3 to Bootstrap 5.**

    Gemfile

    Lines changed: 9 additions & 1 deletion
    Original file line numberDiff line numberDiff line change
    @@ -9,7 +9,7 @@ ruby '>= 3.0'
    99
    # ===========#
    1010

    1111
    # Full-stack web application framework. (http://rubyonrails.org)
    12-
    gem 'rails', '~> 6.1'
    12+
    gem 'rails', '~> 7.1'
    1313

    1414
    # TODO: Remove this once Rails addresses the issue with its dependency on mimemagic. Mimemagic had
    1515
    # an MIT license but was using some incompatible GPL license code.
    @@ -47,6 +47,14 @@ gem 'jbuilder'
    4747
    # Reduces boot times 7DE5 through caching; required in config/boot.rb
    4848
    gem 'bootsnap', require: false
    4949

    50+
    # The ultimate text progress bar library for Ruby!
    51+
    # (https://github.com/jfelchner/ruby-progressbar)
    52+
    gem 'ruby-progressbar'
    53+
    54+
    # Provides Sprockets implementation for Rails 4.x (and beyond) Asset Pipeline.
    55+
    # https://github.com/rails/sprockets-rails
    56+
    gem 'sprockets-rails'
    57+
    5058
    # ============== #
    5159
    # ERROR HANDLING #
    5260
    # ============== #

    0 commit comments

    Comments
     (0)
    0