aws-codeartifact-proxy icon indicating copy to clipboard operation
aws-codeartifact-proxy copied to clipboard

Scoped packages fail for NPM

Open jgriffith-hbs opened this issue 11 months ago • 1 comments

When I call codeartifact requesting a scoped package @my-org/package1, it returns results

GET https://testdomain-12345567890.d.codeartifact.us-east-1.amazonaws.com/npm/testrepo/@my-org%2fpackage1/
Authorization: Bearer $AWS_CODEARTIFACT_AUTH_TOKEN

returns

{
  "_id": "@my-org/package1",
  "name": "@my-org/package1"
}

When I request the same package through the proxy, I get an error.

GET http://localhost:8080/testrepo/@my-org%2fpackage1/
{
  "success": false,
  "error": "1 validation error detected: Value '[@my-org/package1]' at 'versionSelection.targetedVersions' failed to satisfy constraint: Member must satisfy constraint: [Member must have length less than or equal to 255, Member must have length greater than or equal to 1, Member must satisfy regular expression pattern: [^#/\\p{C}\\p{IsWhitespace}]+]"
}

Can we fix the proxy so it works with scoped npm packages?

jgriffith-hbs avatar Dec 12 '24 14:12 jgriffith-hbs

I'm looking to use this, but scoped/namespaced is a requirement for us.

jeff-cook avatar Dec 20 '24 19:12 jeff-cook