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

Hotfix - fixed parquet path on job detail view #342

Merged
merged 2 commits into from
Sep 22, 2020

Conversation

ajstewart
Copy link
Contributor

Job detail page would crash because of leftover date in image path.

@ajstewart ajstewart requested a review from srggrs September 18, 2020 03:57
Copy link
Contributor

@srggrs srggrs left a comment

Choose a reason for hiding this comment

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

original:

img_paths = list(map(
    lambda x: os.path.join(
        settings.PIPELINE_WORKING_DIR,
        'images',
        'images',
        '_'.join([
            x['name'].replace('.','_'),
            x['datetime'].strftime('%Y-%m-%dT%H_%M_%S%z')
        ]),
        'measurements.parquet'
    ),
    p_run_model.image_set.values('name', 'datetime')
))

Suggested:

img_paths = list(map(
    lambda x: os.path.join(
        settings.PIPELINE_WORKING_DIR,
        'images',
        'images',
        x.replace('.','_'),
        'measurements.parquet'
    ),
    p_run_model.image_set..values_list('name', flat=True)
))

Please test it

@ajstewart ajstewart requested a review from srggrs September 22, 2020 03:59
@ajstewart
Copy link
Contributor Author

Tested and working.

@ajstewart ajstewart merged commit 9859653 into master Sep 22, 2020
@ajstewart ajstewart deleted the images-parquet-path-fix branch September 22, 2020 04:20
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

Successfully merging this pull request may close these issues.

2 participants