Can't Open the File for Read (Doesn't Exist?)

Local folder or tarball paths

Troubleshooting

This section provides information on the following bug:

Type of error: Error message:
General startup issues - Error messages in the Bundle Manager window
- Bundle Manager missing or window doesn't open
- Problems afterwards upgrading Unity to new version
- Resetting your project's parcel configuration
Package installation issues - Package installation fails
- Packages not recognized
Problems installing git dependencies - No 'git' executable was found
- git-lfs: control not found
- Repository not found
- Could not read Username: final prompts disabled
- Can't update Git version
Asset Store A growing library of free and commercial assets created by Unity and members of the community. Offers a wide variety of assets, from textures, models and animations to whole projection examples, tutorials and Editor extensions. More info
See in Glossary
packages (My Assets)
- 'Failed to parse Http response' in My Assets context
Scoped registries - Missing 'My Registries' in the Package Manager window
Bug when building packages - Missing MonoBehaviour errors
- Loading error for hostfxr.dll on Windows

You lot can also run the Unity Parcel Manager Diagnostics tool if you lot are experiencing bug that might be network-related. For more information, encounter Network issues.

Fault messages in the Bundle Manager window

The Package Manager displays error indicators in the Parcel Managing director window when it encounters bug:

  • Organization-wide issues

    Error messages that appear in the condition bar betoken the Package Director has detected an issue that is not related to a specific package. For example, if the Parcel Manager cannot access the packet registry server, it displays this message in the condition bar:

    Network error message
    Network fault bulletin

    If your network cannot reach the package registry server, information technology is probably because in that location is a connexion trouble with the network. When you or your system ambassador set the network error, the status bar clears.

    If your network connection is working, just you are not signed into your Unity account, the Package Manager doesn't display any Nugget Store packages. When you try to use the My Avails context, the Package Managing director displays an mistake in the status bar:

    Logged out of Unity account
    Logged out of Unity account

    Click the Sign in button inside the listing view to sign into your Unity account through the Unity Hub.

  • Package-specific issues

    If a specific bundle has a trouble when loading or installing (for example, when determining which parcel versions to load), the mistake icon () appears in the package list next to the compromised package (A). To find out what the problem is, open the compromised package's details view to see the detailed error message (B):

    Dependency error message
    Dependency fault message

Package Manager missing or window doesn't open up

The Bundle Manager window might get moved offscreen or hidden by another window. When this happens, it looks like the Package Director window failed to open. In this instance, y'all can try to reset the window layout (Window > Layouts > Default) and reopen the Package Director window again.

If the Package Manager window still doesn't announced, cheque your Unity Console window A Unity Editor window that shows errors, warnings and other letters generated by Unity, or your own scripts. More info
See in Glossary
:

          Failed to resolve packages: The file [<project-path>/Packages/manifest.json] is not valid JSON:   Unexpected token '}' at 44:one   }                  

This error message indicates that your manifest.json file is malformed. It also tells you the line number where the Packet Manager failed to parse the file, so you tin fix the JSON. There are a number of online validators that you can use to try to correct the problem. Once you salve the corrected file, Unity reloads the Package Manager window.

If you upgraded from an early version of the Unity Editor, in that location may be other problems with your package manifest Each package has a manifest, which provides information about the packet to the Parcel Manager. The manifest contains information such as the proper name of the parcel, its version, a description for users, dependencies on other packages (if whatsoever), and other details. More than info
Encounter in Glossary
file:

  • As of 2019.iii, your manifest.json file should not contain any references to the com.unity.package-director-ui package. Yous tin can either reset your projection'due south package configuration or remove the following line from the manifest's dependencies list:

                                  "com.unity.package-director-ui": "2.1.1",                          
  • Cheque to see if your projection manifest Each Unity project has a project manifest, which acts equally an entry point for the Package Manager. This file must be available in the <projection>/Packages directory. The Package Managing director uses it to configure many things, including a list of dependencies for that projection, likewise every bit any package repository to query for packages. More than info
    Run across in Glossary
    uses "exclude" equally a parcel version. This is an obsolete value for the dependencies
    Encounter in Glossary
    property. If you find whatsoever lines similar these, remove the entire line. Package Director just installs packages that are explicitly included equally a dependency in your project, then once you remove that entry, Package Manager ignores the bundle and doesn't install it.

If the Package Manager still fails to load, follow the procedures nether Packages non recognized and Resetting your projection'due south package configuration.

Problems after upgrading Unity to new version

When you lot upgrade a project to a newer Unity version, the Package Manager automatically updates incompatible packages to newer compatible versions. Yet, if your packet doesn't compile, the Bundle Manager displays fault letters in the Panel.

To correct these messages, read the error letters and prepare any problems you can. For instance, a package might exist missing a dependency on some other package or version. In that instance, you can try and install the package yourself.

Y'all can also attempt the post-obit sequence of solutions until yous detect something that works:

  • Support so delete the Packages binder nether your projection.
  • Back up then delete the package sources in your projection's Packages folder, leaving only the manifest.json file. Then endeavour to reload the project.
  • Create a new empty project. If the Package Manager window loads successfully, replace the Library/PackageCache/com.unity.package-director-ui@<version> folder in the failing project with the same folder from the newly created projection.
  • As a concluding resort, you tin can reset your projection to the default package Unity automatically pre-installs a select number of default packages (for case, the Analytics Library, Unity Timeline, etc.) when you create a new projection. This differs from a bundled bundle because you lot don't need to install information technology and information technology differs from a built-in package because information technology extends Unity's features rather than beingness able to enable or disable them.
    See in Glossary
    configuration and add back packages one at a fourth dimension until it works.

Resetting your project'southward package configuration

If a project has too many package issues, y'all can reset your project back to the default packet configuration for the Editor's version of Unity. This operation resets all packages in your projection. This might non set the source of the trouble, but it tin can assist you lot figure out what the problem is.

Annotation: Y'all tin't disengage resetting your package configuration, then make sure you back up the manifest.json file starting time or make sure your project is nether source command. You tin can also take extra precautions by cloning your project and testing out the operation on the clone earlier proceeding.

To return to the default package configuration, select Reset Packages to defaults from the Aid menu.

Help > Reset Packages to defaults
Help > Reset Packages to defaults

Resetting a clone of your project

You can too examination the return to the default packages earlier y'all perform the final change:

  1. Clone your project past copy-pasting your projection folder and renaming it so that it is easy to detect (for instance, if your project is called MyProject then you lot could employ something like clone_MyProject).

  2. Load your newly cloned project.

  3. From the Help menu, select Reset Packages to defaults.

    Depending on the size of your project, this might take a few minutes.

  4. Check that it successfully reset the packages. If so, you can perform the operation safely on the original project.

Bundle installation fails

If you are trying to install a new package from the registry and it is not working, it might be due to permission problems.

You must have full permissions on the cache folder:

  • Windows: C:\Users\yourname\AppData\Local\Unity\cache
  • MacOS: ~/Users/Library/Unity/cache

It might be a problem with the network. Cheque your firewall and proxy settings.

Sometimes institutional environments, such as schools, government offices, or network-protected workplaces set upward proxy servers to command traffic between the network and the Cyberspace, and use their own server certificates which are non recognized past Unity or the Package Manager. Talk to your network ambassador.

Packages not recognized

If you encounter a lot of compilation errors, this might indicate that Unity is not recognizing the packages in your existing project. In this case, you might be missing a .Net component.

For Windows:

  1. Download and install Visual Studio 2017 version 15.9.0 or higher with the .Net Core cross-platform development workload selected under Other Toolsets.
  2. Download and install the .NET SDK v2.2.101 component.

For MacOS:

  1. Download and install the .NET SDK v2.2.101 component.

  2. Install whatever recommended updates in Visual Studio

  3. Apply homebrew to mash and install mono:

                  mash update brew install mono # optional brew upgrade mono                          
  4. If necessary, delete the Library/obj/temp folder nether your project and restart Unity.

  5. If you are still experiencing difficulties, try rebooting your computer as well.

No 'git' executable was plant

If you try to install a package from a git URL, a message similar to this appears:

          Cannot perform upm operation: Unable to add package [https://github.example.com/myuser/myrepository.git]: No 'git' executable was found. Please install Git on your organisation and restart Unity [NotFound] UnityEditor.EditorApplication:Internal_CallUpdateFunctions()                  

git-lfs: control not found

If you are trying to download a package that uses Git LFS (Large File Storage), you might come across this fault message:

          Error when executing git command. git-lfs filter-process: command not constitute.                  

This indicates that Git LFS is probably not installed on your machine. To make certain, you could test it on the command line:

          git lfs --version                  

If you see something like this, Git LFS is installed:

          git-lfs/2.8.0 (GitHub; darwin amd64; go ane.12.7)                  

Otherwise, yous can install it by following the Bitbucket GitHub instructions.

Repository not found

If you specify a location that does non exist, a message like to this one appears in the Unity Panel:

          Cannot perform upm performance: Unable to add bundle [https://mycompany.github.com/gitproject/com.mycompany.mypackage.git]:   Error when executing git command. fatal: repository 'https://mycompany.github.com/gitproject/com.mycompany.mypackage.git/' not plant  [NotFound] UnityEditor.EditorApplication:Internal_CallUpdateFunctions() (at /Users/builduser/buildslave/unity/build/Editor/Mono/EditorApplication.cs:310)                  

Check your spelling. To make sure you are using the right URL, go to the repository's page and copy the URL from the Clone push:

Where to copy the URL on GitHub (A) and GitLab (B)
Where to copy the URL on GitHub (A) and GitLab (B)

Click the button to the right of the URL on GitHub (A) or GitLab (B) to re-create the URL to your clipboard.

If the location of the repository is right, there may be another trouble with the URL:

  • If you lot are targeting a specific revision, make sure your revision comes concluding. For case:
    https://github.case.com/myuser/myrepository1.git#revision
  • If you are targeting a revision and the package is non at the root, make sure the path query parameter precedes the revision ballast. For case:
    https://github.example.com/myuser/myrepository.git?path=/example/folder#v1.ii.3

Could not read Username: final prompts disabled

If you are trying to install a package from a individual repository that requires authentication, a message similar to this i appears in the Unity Console:

          Cannot perform upm performance: Unable to add parcel [https://mycompany.github.com/gitproject/com.mycompany.mypackage.git]:   Error when executing git command. fatal: could not read Username for 'https://mycompany.github.com': terminal prompts disabled  [NotFound] UnityEditor.EditorApplication:Internal_CallUpdateFunctions() (at /Users/builduser/buildslave/unity/build/Editor/Mono/EditorApplication.cs:310)                  

This bulletin is likely due to the fact that Package Director does not provide an interactive terminal or dialog where you lot can enter your username and countersign for HTTP, or your passphrase to unlock your SSH key:

  • With HTTP(Due south), every time you log onto BitBucket, GitHub or GitLab you need to enter your username and password in a terminal or a dialog box. Nevertheless, the Package Director does not provide an interactive final or dialog where you can enter your username and password for HTTP(Due south).

    To bypass this, use one of the workarounds suggested in Solutions for HTTPS.

  • SSH uses a pair of public and private SSH keys. You can add your public SSH cardinal to Bitbucket, GitHub or GitLab and then admission repositories without having to enter a username and password.

    All the same, if you have set up a passphrase to keep your SSH central safe, you still have to enter that passphrase in a final or a dialog box in order to authorize your cardinal. In that instance, yous can use an SSH amanuensis that tin unlock your SSH key to authenticate with the Package Director on your behalf.

Solutions for HTTPS

The Packet Managing director does non provide an interactive final or dialog where you can enter your HTTP(S) username and countersign. To featherbed this, utilize one of these workarounds:

  • Utilise a credential manager (Git Credential Manager for Windows or OSXKeyChain). Credential managers handle sending the countersign without having to use a terminal or a control prompt.
  • Use git-credentials from a last or control prompt. Then launch the Hub from the same terminal so that Unity has access to the cached or stored credentials.
  • Employ SSH to authenticate instead. If you set your SSH key without a passphrase, the Package Director doesn't have to decrypt information technology in lodge to authenticate with the Git server. If y'all decide to apply a passphrase for added security, you tin can still get effectually the authentication problem by using the ssh-amanuensis on either macOS or Windows.

Solutions for SSH

If yous are using the SSH protocol to install a parcel by Git URL, you might become an hallmark fault from Git. This typically happens when you prepare a private SSH key on your local motorcar that is protected by a passphrase.

The solution to this problem is to set up an SSH agent that can unlock your SSH key to authenticate with the Package Manager on your behalf. Follow the instructions in the department that corresponds to your operating system:

  • Setting upward OpenSSH for Windows
  • Adding SSH keys to your SSH Agent for macOS

Setting up OpenSSH for Windows

The native Windows OpenSSH version of the ssh-agent works ameliorate than the version available by default with Git for Windows. This procedure explains how to set upward the OpenSSH client and add your key to its ssh-agent. If you lot are using Git for Windows, y'all can also prioritize the native Windows OpenSSH over the Git for Windows SSH agent:

  1. Make sure the OpenSSH Customer is installed past searching for information technology in the Windows Settings Optional features window (Outset > Settings, then search for "Optional features"). This applies to Windows 10+.

  2. Check your %PATH% environment variable to brand sure the native Windows OpenSSH location appears (for example, C:\WINDOWS\System32\OpenSSH\).

    Note: If you are already using Git for Windows, make sure the native Windows OpenSSH location appears earlier the Git for Windows SSH location in your %PATH% variable. This ensures that Windows uses the native Windows OpenSSH agent over the Git for Windows SSH amanuensis.

  3. In a PowerShell concluding, start the ssh-agent process and brand sure it starts automatically:

                  # Gear up the ssh-agent service to first automatically and manually outset it now Become-Service ssh-agent | Set-Service -StartupType Automatic # Run the ssh-amanuensis procedure to start the ssh-amanuensis service ssh-agent                          
  4. Import your key into the ssh-agent by running ssh-add on the command line and then following the instructions. By default, the agent adds the %USERPROFILE%\.ssh\id_rsa key and prompts you lot for the password.

                  # Import the key ssh-add                          

    To apply a different primal, you can specify information technology as an argument:

                  # Set the ssh-agent service to kickoff automatically and manually start it now ssh-add <your-secure-ssh-key-name>                          

    If you lot tin can't think the name of your central, you can ask the agent to listing them:

                  ssh-add -50                          
  5. If you installed Git for Windows, reset the %GIT-SSH% environment variable to make sure that Git always uses the native Windows OpenSSH version of the ssh-agent:

                  [Environment]::SetEnvironmentVariable("GIT_SSH", "$((Get-Command ssh).Source)", [Arrangement.EnvironmentVariableTarget]::User)                          

Adding SSH keys to your SSH Agent for macOS

Use the following command to add your SSH keys to the ssh-amanuensis running on your macOS system:

          ssh-add -Thousand ~/.ssh/<your-secure-ssh-key-name>                  

Later y'all run this command, the final asks for the password to unlock your SSH cardinal and then adds information technology to the macOS keychain. However, once you restart your system, every key stored in the ssh-agent is reset.

To prevent re-entering your password afterwards restarting your system, open the ~/.ssh/config file (or create one if y'all don't find it), and add together the following:

          Host *     UseKeychain yes     AddKeysToAgent yes     IdentityFile ~/.ssh/<your-secure-ssh-central-name>                  

Restart your machine to utilize these changes.

Tin can't update Git version

If yous are trying to update your Git dependency The Packet Manager retrieves Git dependencies from a Git repository directly rather than from a package registry. Git dependencies employ a Git URL reference instead of a version, and there's no guarantee about the package quality, stability, validity, or even whether the version stated in its bundle.json file respects Semantic Versioning rules with regards to officially published releases of this bundle. More info
See in Glossary
to a newer version from the repository, but it's non working, it's probably because your Git dependency is locked. If you want to update your Git dependency to a newer version from the repository, apply the Add packet from git URL button and enter a Git URL. For more than information, see Locked Git dependencies.

'Failed to parse Http response' in My Assets context

If yous run across the following bulletin in the Console window when trying to download an Nugget Store bundle, at that place might be a trouble with your Asset Shop cache:

[PackageManager] Fault Failed to parse response. UnityEditor.AsyncHTTPClient![:D](https://forum.unity.com/styles/default/xenforo/articulate.png)one(State, Int32)

To solve this problem, delete all downloaded assets from the Asset Store bundle directory and then try downloading the assets again.

Warning: If your project contains a lot of nugget information, this might take a lot of time and bandwidth to re-download everything.

Missing 'My Registries' in the Packet Manager window

Not all registry providers are compatible with Unity'due south Package Director. If the package registry server yous added does not implement the /-/v1/search or /-/all endpoints, your scoped registry is not compatible with Unity'south Package Director, and doesn't appear in the My Registries context in the Parcel Director window.

Missing MonoBehaviour errors

While edifice, if there are a lot of errors about Missing Behavior, the UnityLinker might be mistakenly stripping out a component that it thinks is unreferenced. Information technology oftentimes does this because the stripping level is as well ambitious. For case, if you have a prefab An asset type that allows you to store a GameObject complete with components and properties. The prefab acts as a template from which you can create new object instances in the scene. More info
See in Glossary
in an AssetBundle that references the SpriteShape component in the second SpriteShape package, the object might be missing and might generate compiler warnings.

To prepare this, you can either lower the stripping level for the UnityLinker or declare the package's assemblies inside the link.xml file in order to preserve them from being stripped:

          <linker>     <assembly fullname="Unity.2D.SpriteShape.Runtime" preserve="all"/>     <assembly fullname="Unity.2D.Mutual.Runtime" preserve="all"/>  </linker>                  

For more data on stripping levels and the UnityLinker, see Managed code stripping.

Loading error for hostfxr.dll on Windows

If the Console reports that the hostfxr.dll library was found, but Unity failed to load it from C:\<path_to_app>\hostfxr.dll, you tin can fix this error on Windows 7 or Windows Server 2008 R2 by installing both KB2999226 and KB2533623 patches.

Local folder or tarball paths

olivermally1997.blogspot.com

Source: https://docs.unity3d.com/Manual/upm-errors.html

0 Response to "Can't Open the File for Read (Doesn't Exist?)"

Post a Comment

Iklan Atas Artikel

Iklan Tengah Artikel 1

Iklan Tengah Artikel 2

Iklan Bawah Artikel