datahub icon indicating copy to clipboard operation
datahub copied to clipboard

Could not use specified custom data roles inside transformer

Open YuriyGavrilov opened this issue 1 year ago • 4 comments

Describe the bug

We create few type or roles like

image

so we can't use it inside transformer like:

transformers:
  - type: "pattern_add_dataset_ownership"
    config:
      owner_pattern:
        rules:
          ".*example1.*": ["urn:li:corpuser:username1"]
          ".*example2.*": ["urn:li:corpuser:username2"]
      ownership_type: "Space_Admin"

To Reproduce Steps to reproduce the behavior:

  1. Go to 'admin'
  2. Click on 'create custom role'
  3. Create transformer with this new role
  4. See error:
           'validate_ownership_type\n'
           '    raise ValueError(f"Unexpected ownership type: {ownership_type}")\n'
           'ValueError: Unexpected ownership type: Space_Admin\n'
           '\n'
           'The above exception was the direct cause of the following exception:\n'
           '\n' "

Expected behavior

Simply add any custom roles

Screenshots image

Desktop (please complete the following information):

  • OS: [e.g. Linux]
  • Browser [e.g. chrome]
  • Version [e.g. 0.12]

Additional context There no info how to create new role and use it in transformer

YuriyGavrilov avatar Feb 14 '24 12:02 YuriyGavrilov

Tried to use this one in transformer:

ownership_type: "urn:li:ownershipType:Space_Admin"

but

'    raise ValueError(f"Unexpected ownership type: {ownership_type}")\n'
       'ValueError: Unexpected ownership type: urn:li:ownershipType:Space_Admin\n'
       '\n'
       'The above exception was the direct cause of the following exception:\n'
       '\n'
       'Traceback (most recent call last):\n'
       '  File "/tmp/datahub/ingest/venv-trino-v0.12.0/lib/python3.10/site-packages/datahub/entrypoints.py", line 188, in main\n'

YuriyGavrilov avatar Feb 16 '24 11:02 YuriyGavrilov

This issue is stale because it has been open for 30 days with no activity. If you believe this is still an issue on the latest DataHub release please leave a comment with the version that you tested it with. If this is a question/discussion please head to https://slack.datahubproject.io. For feature requests please use https://feature-requests.datahubproject.io

github-actions[bot] avatar Mar 18 '24 01:03 github-actions[bot]

It is actual

YuriyGavrilov avatar Mar 18 '24 07:03 YuriyGavrilov

This issue is stale because it has been open for 30 days with no activity. If you believe this is still an issue on the latest DataHub release please leave a comment with the version that you tested it with. If this is a question/discussion please head to https://slack.datahubproject.io. For feature requests please use https://feature-requests.datahubproject.io

github-actions[bot] avatar Apr 18 '24 01:04 github-actions[bot]

This issue was closed because it has been inactive for 30 days since being marked as stale.

github-actions[bot] avatar May 18 '24 01:05 github-actions[bot]