Skip to content

Infra: upgrade ncbo_annotator to Ruby 3.2 and Minitest 6#47

Draft
mdorf wants to merge 18 commits intodevelopfrom
chore/ruby3.2-minitest6-compat
Draft

Infra: upgrade ncbo_annotator to Ruby 3.2 and Minitest 6#47
mdorf wants to merge 18 commits intodevelopfrom
chore/ruby3.2-minitest6-compat

Conversation

@mdorf
Copy link
Member

@mdorf mdorf commented Mar 17, 2026

Overview

This PR upgrades ncbo_annotator to Ruby 3.2 and Minitest 6, while aligning it with the updated OntoPortal dependency stack.

Unlike other repositories in this synchronization effort, ncbo_annotator has not significantly diverged from the AgroPortal implementation. The two codebases were previously synchronized in agroportal/ncbo_annotator#28, and only minimal changes have been introduced on the AgroPortal side since then.

As a result, this PR does not perform a full codebase alignment. Instead, it focuses on runtime modernization, dependency updates, and targeted compatibility fixes required to integrate with the synchronized OntoPortal stack.

The only notable AgroPortal-specific changes since the last synchronization are:

  • Introduction of lemmatizer support (NOT included in this PR)
  • A fix for compatibility with the RDF 3.x gem (included in this PR)

Prerequisites

This PR depends on the following updates:

Notable Changes

  • Ruby 3.2 upgrade

    • Updates runtime from Ruby 3.1.x to 3.2.x
    • Aligns Docker and local development environments
  • Migration to Minitest 6

    • Replaces legacy MiniTest usage with Minitest::Test
    • Updates test setup (minitest/autorun, lifecycle hooks, reporters)
    • Adjusts Rake::TestTask configuration
  • Alignment with updated OntoPortal dependency stack

    • Updates dependencies to use synchronized versions of:
      • goo
      • ontologies_linked_data
      • sparql-client
  • RDF 3.x compatibility fixes

    • Incorporates updates required for compatibility with the RDF 3.x gem
    • Includes fixes adapted from AgroPortal
  • Virtuoso graph handling fix

    • Prevents incorrect processing of graph URIs during hierarchy expansion
    • Ensures only ontology-related graphs are considered
  • Configuration initialization fix

    • Ensures runtime overrides are applied after default configuration is loaded
  • Test stability improvements

    • Fixes backend-specific inconsistencies (e.g., Virtuoso vs 4store)
    • Ensures deterministic ordering in results
    • Resolves edge-case test failures
  • OntoPortal testkit integration

    • Adds .ontoportal-testkit.yml and CI workflow
    • Standardizes test execution across environments
  • Dependency updates

    • Adds json-ld and jwt to support the updated stack

@mdorf mdorf changed the title Chore/ruby3.2 minitest6 compat Infra: upgrade ncbo_annotator to Ruby 3.2 and Minitest 6 Mar 17, 2026
@codecov-commenter
Copy link

codecov-commenter commented Mar 17, 2026

Codecov Report

❌ Patch coverage is 84.61538% with 2 lines in your changes missing coverage. Please review.
✅ Project coverage is 79.21%. Comparing base (ff42df5) to head (9da3081).
⚠️ Report is 4 commits behind head on develop.

Files with missing lines Patch % Lines
lib/ncbo_annotator.rb 81.81% 2 Missing ⚠️
Additional details and impacted files
@@             Coverage Diff             @@
##           develop      #47      +/-   ##
===========================================
+ Coverage    79.17%   79.21%   +0.03%     
===========================================
  Files            9        9              
  Lines          658      659       +1     
===========================================
+ Hits           521      522       +1     
  Misses         137      137              
Flag Coverage Δ
ag 79.21% <84.61%> (?)
fs 79.21% <84.61%> (?)
gd 79.21% <84.61%> (?)
unittests 79.21% <84.61%> (+0.03%) ⬆️
vo 79.21% <84.61%> (?)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants