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

ValueError: Invalid isoformat string error when running piperider compare-reports against a metric #676

Open
waligob opened this issue May 1, 2023 · 2 comments

Comments

@waligob
Copy link

waligob commented May 1, 2023

Describe the bug
Running piperider compare-reports --last against a dbt metric results in an error like ValueError: Invalid isoformat string: '2023-04-01 00:00:00'

To Reproduce
Steps to reproduce the behavior:

  1. Setup new virtual environment and run pip install "piperider[bigquery]==0.23.3"
  2. Initialize Piperider with piperider init
  3. Add the piperider tag to a metric configuration file
  4. Run piperider run twice to generate two reports
  5. Run piperider compare-reports --last --debug
  6. See an error like ValueError: Invalid isoformat string: '2023-04-01 00:00:00'

Expected behavior
The compare-reports command should create an HTML report and a Markdown report in the .piperider/comparisons/ directory

Desktop (please complete the following information):

  • OS: Debian GNU/Linux
  • Python Version 3.9.16
  • Version: dbt 1.4.5, dbt metrics 1.4.0, piperider[bigquery]==0.23.3

Additional context
Add any other context about the problem here.

The offending metric configuration can be found below:

version: 2
metrics:
  - name: total_seconds_engaged
    label: Total Seconds Engaged
    model: ref('fct_hits')
    description: "The number of seconds readers spent viewing a page"
    calculation_method: sum
    expression: seconds_engaged
    timestamp: date
    time_grains: [day, week, month, quarter, year, all_time]
    dimensions:
      - article_arc_id
    tags:
      - piperider

The full output of piperider compare-reports --last --debug is attached:

piperider_debug.txt

@popcornylu
Copy link
Contributor

Thank you for raising the issue, we will try to rerpoduce this problem

sc-31241

@wcchang1115
Copy link
Contributor

Hi waligob,

We have fixed the bug for this issue in PipeRider v0.25.0.
Could you please try using the latest version to see if it resolves your issue?

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

No branches or pull requests

3 participants