New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Update getting-started.md #3825
Open
Juksefantomet
wants to merge
1
commit into
facebook:main
Choose a base branch
from
Juksefantomet:Juksefantomet-patch-1
base: main
Could not load branches
Branch not found: {{ refName }}
Could not load tags
Nothing to show
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What is this? Why is it needed?
Also can you share a reference from Expo mentioning that this is needed?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry for any missing clarifications, simply running
npx create-expo-app AppName
will fail unless you install that package, as it is not automatically resolved. So it simply ends immediately saying it is unable to resolve that package. I figured it would be natural to put that as a pre-requirement to be able to run expo create command.On a fresh ubuntu 22.04 installation. The only previous installed npm react related packages was normal react and create-react-app usage.
when executing
npx create-expo-app AppName
, during the first step "Downloading and extracting project files"Something went wrong in downloading and extracting the project files: NPM package not found: https://registry.npmjs.org/expo-template-blank/-/expo-template-blank-49.0.16.tgz
After installing the pull requested addition, the installation and project initialization continued as expected.
Taking my steps into consideration there might be other issues that were resolved as a result of me installing that package, but ultimately that step failed until i installed the template package prior to the create-expo-app command.
I hope this gave more clarification, if this is something that should be resolved elsewhere if expected to be resolved automatically by create-expo-app then I am all ears.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@Simek could check this over?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
AFAIK the installation of the template package should not be needed, I will rise this issue internally and get back with more information soon.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @Juksefantomet, there is a new template version published earlier today on npm (
49.0.17
). Can you please try creating a new project with that? Also, I'd suggest clearing yournpx
cache before creating a new project. There could've been an issue with49.0.16
but we are not sure yet.Alternatively, you can also try
yarn create expo YourProjectName
which always fetches the latest template.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I discovered the culprit, these are my steps with the conclusion at the bottom.
First steps:
cache and removal:
reinstalling node and npm
Attempted to create-expo-app
current os
I then realized we are using .npmrc due to our Gemfury private repositories in our organiztion:
~/.npmrc
I performed a simple:
redid my steps with cache and reinstall of npm and node.
executed the
npx create-expo-app test
And the download issue was NOT present, the blocker was .npmrc somehow, i hope this might shed some light on the create-expo-app script and how it might be searching for project download source prior to installation.
Additionally i realize this probably should've been an issue rather then a PR and i apologize for any inconvenience this might've caused.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you so much for sharing this in-detail steps and further information. I've shared this internally and will get back to you as I'm not sure what this is relates to (whether a proxy issue or something else).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@Juksefantomet, it seems the issue in the
.npmrc
file is caused by the custom registry (fury.io). We use npm directly to check for the existence of the template name. In your case, since its a proxy, we can't exactly know. One thing you'll have to upload the template package manually as stated in gemfury docs.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The custom Gemfury registry is only for private packages, I've not encountered this with any other installations. The registry is only defined so we can access our organizations private npm assets package 😄
Previously this caused issues until the
strict-ssl
andalways-auth
was defined, that usually caused multiple packages to attempt to download any package from the Gemfury registry rather then the npm registry.But since this is related to a package acquisition during a project initialization I can't really confirm if that behavior is expected to be the same.
I do remember configuring that proxy initially was frankly quite annoying. And for that reason we are moving away from Gemfury / private registries in the near future 😄
Perhaps adding a note regarding proxy registries is in place instead or an adjustment to any non npm default registry presence could throw a warning / message to the user?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for your feedback! I've shared this internally, and we'll look into updating our tools to show a warning for this particular scenario.