Skip to content
Snippets Groups Projects

Multiple Relations #113

Open Pascal Ehlers requested to merge multipleRelations into development
5 unresolved threads

Co-authored-by: Gabriel Preuß gabriel.preuss@helmholtz-berlin.de

Merge request reports

Merge request pipeline #494567 failed

Merge request pipeline failed for 0c323c24

Approval is optional
Merge blocked: 1 check failed
Merge conflicts must be resolved.

Merge details

  • The source branch is 107 commits behind the target branch.
  • 21 commits and 1 merge commit will be added to development.
  • Source branch will be deleted.

Activity

Filter activity
  • Approvals
  • Assignees & reviewers
  • Comments (from bots)
  • Comments (from users)
  • Commits & branches
  • Edits
  • Labels
  • Lock status
  • Mentions
  • Merge request status
  • Tracking
262 oai_identifier,
263 research_fields,
264 )
254 research_fields = get_mapped_research_fields(self._get_specs(xml)) or []
265 255
266 256 # we don't want to pick "other" or "unknown" if it exists here
267 257 research_fields = [
268 258 rf for rf in research_fields if rf not in ["Other", "Unknown"]
269 259 ]
270 260
271 return research_fields[0] if research_fields else None
261 return research_fields
272 262
273 263 if center == "GFZ" and pub_year and int(pub_year) >= 2021:
274 return "Earth and Environment"
264 return ["Earth and Environment"]
  • 108 169 name=center,
    109 170 cursor=cursor,
    110 171 )
    111
    112 172 cursor.execute(
    113 173 """
    114 INSERT INTO center_has_publication
    174 INSERT IGNORE INTO center_has_publication
  • 66 Function for update class so that _has_ tables get updates even if the publication is already inserted
    67 into database
    68 """
    69
    70 if lit_pub.LitHelmholtzCenter:
    71 _insert_helmholtz_center(cursor, pid, lit_pub.LitHelmholtzCenter)
    72
    73 if lit_pub.HelmholtzResearchField:
    74 _insert_research_field(cursor, pid, lit_pub.HelmholtzResearchField)
    75
    76 if lit_pub.HelmholtzResearchSubField:
    77 _insert_research_sub_field(cursor, pid, lit_pub.HelmholtzResearchSubField)
    78
    79 if lit_pub.LitPublisher:
    80 _insert_publication_has_publisher(cursor, pid, lit_pub.LitPublisher)
    81
  • 16 16 LitInternalID: Optional[str] = None
    17 17 LitInternalIDType: Optional[str] = None
    18 18 LitHelmholtzCenter: Optional[str] = None
    19 HelmholtzResearchField: Optional[str] = None
    20 HelmholtzResearchSubField: Optional[str] = None
    19 HelmholtzResearchField: list[str] = []
    20 HelmholtzResearchSubField: list[str] = []
    21 21 HelmholtzLargeScaleFacilities: list[str] = []
    22 22 HelmholtzInstruments: list[str] = []
  • Pascal Ehlers added 1 commit

    added 1 commit

    • 9eb6829b - Apply 1 suggestion(s) to 1 file(s)

    Compare with previous version

  • Pascal Ehlers added 1 commit

    added 1 commit

    • 7bdcda42 - Apply 1 suggestion(s) to 1 file(s)

    Compare with previous version

  • Pascal Ehlers added 1 commit

    added 1 commit

    • cebf2886 - Apply 1 suggestion(s) to 1 file(s)

    Compare with previous version

  • Pascal Ehlers added 1 commit

    added 1 commit

    Compare with previous version

    • I just checked out the branch and did a test run, what I realized:

      1. when a known publication is found on another center it's still ignored completely. But in that case the center should be added to the center list.
      2. HelmholtzResearchField is still flagged as a property that may not change and so additional research fields found here are not merged.

      Next time please do a test run before you open a merge request.

      Edited by Gabriel Preuß
  • Please register or sign in to reply
    Loading