Skip to content

Refactoring graphql members query for import

What does this MR do and why?

Currently, some direct imports are broken because the source Gitlab.com is too old. SHARED_INTO_ANCESTORS was added in %16.0 !96543 (merged). Hence imports from a source before 16.0 are failing with

Argument 'relations' on Field 'members' has an invalid value ([DIRECT, INHERITED, INVITED_GROUPS, SHARED_INTO_ANCESTORS]). Expected type '[ProjectMemberRelation!]'.

In this MR, the query will determine which source_version it's running on and dynamically construct the appropriate query

Screenshots or screen recordings

n/a

Before After

How to set up and validate locally

Have to set-up a local gdk from a pre 16.0 version

MR acceptance checklist

This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.

Related to #410162 (closed)

Edited by Max Fan

Merge request reports