codecov/codecov-ruby

Strange GitLab CI Behavior

stephendolan opened this issue · 6 comments

What is the purpose of this line in the library?

It is causing my repository to fail every pipeline with the message {"error": {"context": "slug", "reason": "slug must match pattern ^[\\w\\-\\.]{1,255}\\/[\\w\\-\\.]{1,255}$"}, "meta": {"status": 400}}.

My project path is https://gitlab.com/big-southern-software/point-to-point/hub.git

The library's split method causes big-southern-software/point-to-point/hub to be extracted, which does indeed fail the regular expression above that expects a single slash.

It seems as though this split method was utilized with GitHub-style single-hierarchy projects in mind, whereas GitLab allows infinite grouping hierarchies.

I also have this problem. It seems that codecov does not support multi-level project slugs (at least when coverage is reported). When I overrode the slug with the CODECOV_SLUG environment variable and set it to foo/bar then it worked correctly (and even included my top-level group). I'm not sure how it would work with a 4-deep group as I'm only trying with a 3-deep.

The codecov.io UI seems to support this properly. I believe this is a bug.

Hi all, sorry for the delay here (by years). Is this still an issue? I know we had made some significant changes to our GitLab integration, particularly with slug matching.

I'm using github with the codecov bash uploader and I'm also getting a similar error and have no idea what it means

    ....
    X> Failed to upload
    -> Sleeping for 30s and trying again...
/dev/fd/63: line 1668: [: 0+1: integer expression expected
    -> Uploading to Codecov
    HTTP 400
slug must match pattern ^[\w\-\.\~\/]+\/[\w\-\.]{1,255}$

@toymachiner62 can you link to the repository?

@toymachiner62 can you link to the repository?

It's a private repo so I can't here.

@toymachiner62 could you open a ticket in our community boards? I can DM you from there