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

fix(powerbi): Make report patterns configurable for PowerBIReportServer #12435

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

pedro93
Copy link
Collaborator

@pedro93 pedro93 commented Jan 22, 2025

Checklist

  • The PR conforms to DataHub's Contributing Guideline (particularly Commit Message Format)
  • Links to related issues (if applicable)
  • Tests for the changes have been added/updated (if applicable)
  • Docs related to the changes have been added/updated (if applicable). If a new feature has been added a Usage Guide has been added for the same.
  • For any breaking change/potential downtime/deprecation/big changes an entry has been made in Updating DataHub

@sgomezvillamor sgomezvillamor changed the title fix(powerbi report server) Make report & chart patterns configurable fix(powerbi): Make report & chart patterns configurable for PowerBIReportServer Jan 22, 2025
@github-actions github-actions bot added the ingestion PR or Issue related to the ingestion of metadata label Jan 22, 2025
Comment on lines 118 to 125
report_pattern: AllowDenyPattern = pydantic.Field(
default=AllowDenyPattern.allow_all(),
description="Regex patterns to filter PowerBI Reports in ingestion.",
)
chart_pattern: AllowDenyPattern = pydantic.Field(
default=AllowDenyPattern.allow_all(),
description="Regex patterns to filter PowerBI Charts in ingestion.",
)
Copy link
Contributor

Choose a reason for hiding this comment

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

If I'm not wrong, these two patterns are not used anywhere and so the feature actually requires further work.

Whether they were added as a sort of TODO or not, I don't know 🤔

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

I suspect they were added as a form of TODO. Added a check for the report_pattern, chart_pattern and platform_urn however are not used so deleted those.

Copy link

codecov bot commented Jan 22, 2025

❌ 1 Tests Failed:

Tests completed Failed Passed Skipped
2070 1 2069 70
View the top 1 failed test(s) by shortest run time
tests.cypress.integration_test::test_run_cypress
Stack Traces | 1034s run time
auth_session = <tests.utils.TestSessionWrapper object at 0x7fe3570fd330>

    def test_run_cypress(auth_session):
        # Run with --record option only if CYPRESS_RECORD_KEY is non-empty
        record_key = os.getenv("CYPRESS_RECORD_KEY")
        tag_arg = ""
        test_strategy = os.getenv("TEST_STRATEGY", None)
        if record_key:
            record_arg = " --record "
            batch_number = os.getenv("BATCH_NUMBER")
            batch_count = os.getenv("BATCH_COUNT")
            if batch_number and batch_count:
                batch_suffix = f"-{batch_number}{batch_count}"
            else:
                batch_suffix = ""
            tag_arg = f" --tag {test_strategy}{batch_suffix}"
        else:
            record_arg = " "
    
        print(f"test strategy is {test_strategy}")
        test_spec_arg = ""
        specs_str = ",".join([f"**/{f}" for f in _get_cypress_tests_batch()])
        test_spec_arg = f" --spec '{specs_str}' "
    
        print("Running Cypress tests with command")
        command = f"NO_COLOR=1 npx cypress run {record_arg} {test_spec_arg} {tag_arg}"
        print(command)
        # Add --headed --spec '**/mutations/mutations.js' (change spec name)
        # in case you want to see the browser for debugging
        print_now()
        proc = subprocess.Popen(
            command,
            shell=True,
            stdout=subprocess.PIPE,
            stderr=subprocess.PIPE,
            cwd=f"{CYPRESS_TEST_DATA_DIR}",
        )
        assert proc.stdout is not None
        assert proc.stderr is not None
        stdout = proc.stdout.read()
        stderr = proc.stderr.read()
        return_code = proc.wait()
        print(stdout.decode("utf-8"))
        print("stderr output:")
        print(stderr.decode("utf-8"))
        print("return code", return_code)
        print_now()
>       assert return_code == 0
E       assert 1 == 0

tests/cypress/integration_test.py:243: AssertionError

To view more test analytics, go to the Test Analytics Dashboard
📋 Got 3 mins? Take this short survey to help us improve Test Analytics.

@datahub-cyborg datahub-cyborg bot added the pending-submitter-response Issue/request has been reviewed but requires a response from the submitter label Jan 22, 2025
@pedro93 pedro93 changed the title fix(powerbi): Make report & chart patterns configurable for PowerBIReportServer fix(powerbi): Make report patterns configurable for PowerBIReportServer Feb 12, 2025
@datahub-cyborg datahub-cyborg bot added needs-review Label for PRs that need review from a maintainer. and removed pending-submitter-response Issue/request has been reviewed but requires a response from the submitter labels Feb 12, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ingestion PR or Issue related to the ingestion of metadata needs-review Label for PRs that need review from a maintainer.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants