Skip to content

Problem loading images to gitlab with _ in the name #1347

Open
@shortcipher3

Description

I was debugging a problem I found with images not showing up in gitlab when using cml comment create and found some strange things, here is my test set:

    - echo "# no changes" > report.md
    - echo "![atest](./reports/model_pr_curves/person_iou0.5_51.png)" >> report.md
    - cp ./reports/model_pr_curves/person_iou0.5_51.png test.png
    - echo "# local_no_special_chars" >> report.md
    - echo "![btest](./test.png)" >> report.md
    - cp ./reports/model_pr_curves/person_iou0.5_51.png ./reports/model_pr_curves/test.png
    - echo "# nested_no_special_chars" >> report.md
    - echo "![ctest](./reports/model_pr_curves/test.png)" >> report.md
    - cp ./reports/model_pr_curves/person_iou0.5_51.png ./d_._test.png
    - echo "# local_special_chars" >> report.md
    - echo "![dtest](./d_._test.png)" >> report.md
    - cp ./reports/model_pr_curves/person_iou0.5_51.png ./reports/model_pr_curves/aaaaaaaaaaaaaaaa.png
    - echo "# long_path" >> report.md
    - echo "![etest](./reports/model_pr_curves/aaaaaaaaaaaaaaaa.png)" >> report.md
    - echo "![image](wild/creative/thinking/exercise.png)" >> report.md
    - npx github:iterative/cml#warn-publish-enoent comment create --publish-native report.md

no changes (atest) fails to load, local_no_special_chars (btest) loads,  nested_no_special_chars (ctest) loads, local_special_chars (dtest) fails to load, and long_path (etest) loads

It appears that cml doesn't like the _ character in the name. Also I noticed that on a different run the long_path test failed to load, I wonder if the content in the square brackets needs to be unique?

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions