Skip to content

fetchFromBitbucket: url split in two when there is a space in rev #29733

@dotlambda

Description

@dotlambda

Issue description

I'm currently writing a derivation for QMapShack:

stdenv.mkDerivation rec {
  name = "QMapShack-${version}";
  version = "1.9.1";

  src = fetchFromBitbucket {
    owner = "maproom";
    repo = "qmapshack";
    rev = "V ${version}";
    sha256 = "1yswdq1s9jjhwb3wfiy3kkiiaqzagw28vjqvl13jxcnmq7y763sr";
  };
}

The important part is that rev = "V 1.9.1" (with a space).
When I try to build this package, two urls are downloaded:

trying https://bitbucket.org/maproom/qmapshack/get/V
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
curl: (22) The requested URL returned error: 404 

trying 1.9.1.tar.gz

I tried to find an error in fetchFromBitbucket, fetchzip and fetchurl but I really have no idea where the url is split in two.

Metadata

Metadata

Assignees

No one assigned

    Labels

    0.kind: bugSomething is broken3.skill: trivialThis is trivial to complete (typically find-and-replace)
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions