sandpack icon indicating copy to clipboard operation
sandpack copied to clipboard

Team Pro account w/ Private Registry (Artifactory jFrog) request fails with 404

Open rfenderdtn opened this issue 2 years ago • 3 comments

Bug report

Packages affected

  • [ ] sandpack-client
  • [X] sandpack-react

Description of the problem

Using the trial Team Pro account so I can access private packages on Artifactory JFrog, I continually get HTTP 404 with a a message Couldn't find the requested release version @. when Sandpack makes the GET request to <teamName>-2-6-3-sandpack.codesandbox.io

What were you doing when the problem occurred?

Testing locally (http://localhost:3000) in a NextJS application running [email protected].

What steps can we take to reproduce the problem?

You can use NextJS but this can be reproduce with a simple CRA app as well using the following code snippet. This is the code snippet being used (actual names not used. replaced with fake teamId and dependency names):

<Sandpack
        template="react"
        teamId="myTeamName"
        customSetup={{
          dependencies: {
            "@customScope/custom-package": "latest",
          },
        }}
        files={{
          "/App.js": `import {Button} from "@customScope/custom-package";
  export default function App() {
  return <Button variant="primary">Hello</Button>
}`,
        }}
      />

Link to sandbox: link (optional)

Your Environment

Software Name/Version
Sandpack-react version 2.6.3
NextJS 13.1.2
React 18.2.0
Browser Chrome 112
Operating System macOS 12.6

rfenderdtn avatar May 08 '23 17:05 rfenderdtn

Hey, I'm sorry to hear you're facing issues with using private packages.

In order to understand what's going on, could you make a little test? Can you create a private sandbox using this same package and piece of code in your team? Sandpack uses the same mechanism as codesandbox.io to consume private packages, and if we can confirm this only happens on Sandpack or on the codesandbox.io as well, we can narrow down the issue and fix it.

Thanks

danilowoz avatar May 10 '23 10:05 danilowoz

EDIT: updated link to sandbox. @danilowoz it is private but I'm guessing you have god access to get in. if not let me know

@danilowoz , here is the link to the private sandbox: https://codesandbox.io/s/runtime-bash-q93c5c

It is failing on the install of our private packages. let me know what else you need

rfenderdtn avatar May 10 '23 14:05 rfenderdtn

I also see the following in Chrome DevTools > Console:

Failed to execute 'postMessage' on 'DOMWindow': The target origin provided ('https://ecocomponents-2-6-3-sandpack.codesandbox.io') does not match the recipient window's origin ('http://localhost:3000').

rfenderdtn avatar May 11 '23 15:05 rfenderdtn