Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merge seek 1.15.1 into LDH #56

Merged
merged 148 commits into from
Jul 9, 2024
Merged

Merge seek 1.15.1 into LDH #56

merged 148 commits into from
Jul 9, 2024

Conversation

ReneHaensel
Copy link
Collaborator

@ReneHaensel ReneHaensel commented Jul 9, 2024

Description

  • merge Seek-1.15.1 into LDH 'main'
  • contains the new functionality to publish data resources to GCHSH with RestClient error handling and MDS conformity check

Changes

Features / major changes

  • add publish button to Project action menu
  • add transformation functionality of extended metadata to a verified MDS conform schema
  • add GCHSH Token Purchasing
  • add publish functionality to GCHSH
  • add error handling routine for the RESTCient communication processes
  • add feature to the admin panel to enable/disable it and organise credentials for Validator, GCHSH Token access and GCHSH publish portal

kdp-cloud and others added 30 commits May 8, 2024 12:31
needs tests, but see what tests are affected first
…eam_permissions

Issue 1868 fix assay stream permissions
show progress for decouple_extracted_samples_policies and decouple_extracted_samples_projects, after every batch of 250
also update the query for decouple_extracted_samples_projects to select those without projects, making reruns quicker
…tions

internationalize the names in the search types. Closes #1879
@ReneHaensel ReneHaensel requested a review from whomingbird July 9, 2024 15:17
@ReneHaensel ReneHaensel requested review from MasoudAbedi and removed request for whomingbird and MasoudAbedi July 9, 2024 15:39
@ReneHaensel ReneHaensel merged commit f3bcd95 into main Jul 9, 2024
21 checks passed
@whomingbird
Copy link
Collaborator

could you please describe the new features of the PR?

project_attributes_json = ProjectSerializer.new(@project).to_json

@user_current = current_person
special_characters = {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can this move to a function ?

@@ -543,77 +543,206 @@ def order_investigations

def publish_to_csh
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i think the most of code of the "publish_to_csh" should be move to a module in lib/nfdi4health, the code for preparing and parsing json could be reused by other resource to publish to CSH.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

transforming_api_data = data_project.transforming_api(Project.find(params[:id]), ProjectSerializer, 'Projects')

transforming_api_data = data_investigation.transforming_api(Investigation.find(params[:id]), InvestigationSerializer, 'investigation')

transforming_api_data = data_study.transforming_api(Study.find(params[:id]), StudySerializer, 'studies')

Comment on lines +66 to +69
<% if Seek::Config.n4h_enabled && item.extended_metadata != nil %>
<li><%= image_tag_for_key('publish', publish_to_csh_project_path(item), "Publish to NFDI4Health GCHSH", nil, "Publish to NFDI4Health GCHSH") -%></li>
<% else %>
<% explanation = "The 'Publish to NFDI4Health GCHSH' item for #{text_for_resource(item).pluralize.downcase} in Server admin panel was deactivated by the admin." %>
<% explanation = "Your project does not include metadata, or The 'Publish to NFDI4Health GCHSH' item for #{text_for_resource(item).pluralize.downcase} in Server admin panel was deactivated by the admin." %>
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this should be moved to the ProjectsHelper

Seek::Config.n4h_enabled && item.extended_metadata != nil, this code looks weird

Copy link
Collaborator

@whomingbird whomingbird left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Main Concerns:

  1. Modularization:
    Move the publish_to_csh functionality to a module within lib/nfdi4health. This will enhance modularity and allow the code for preparing and parsing JSON to be reused by other resources needing to publish to CSH.
  2. Testing:
    Add tests to ensure the reliability and correctness of the publish_to_csh functionality. In the SEEK main branch, writing tests is a crucial part of SEEK development. Any feature cannot be merged into the main branch without proper tests.

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.

7 participants