Search Unity

  1. Curious about what's going to be in 2021.1? Have a look at the 2021.1 beta blog post.
    Dismiss Notice

Package manager confusion

Discussion in '2018.1 Beta' started by kkqqpp, Apr 21, 2018.

  1. kkqqpp

    kkqqpp

    Joined:
    Aug 13, 2014
    Posts:
    7
    Hi Unity,

    I got some questions about the package manager.

    1. Once the project installs a package, where is the file store at?
    2. Is there any way to do overriding on a package content?
    3. If a package depends on another package (like the HD pipeline depends on the core pipeline), the user may don't know which packages should they install and which version is compatible. Is there any way to make a package that it installs all the sub-packages automatically?
    4. Is upgrade a package means that delete the whole old package and install a whole new package?

    Thanks.
     
  2. superpig

    superpig

    Drink more water! Unity Technologies

    Joined:
    Jan 16, 2011
    Posts:
    4,428
    It's stored in a global cache, shared between all projects on your machine. Somewhere in your LocalAppData folder, IIRC.

    The plan for this is that you will be able to 'embed' a package, which will save a complete copy of the package into the 'Packages' folder inside your project. Then you'll be able to edit it as much as you like, and it'll override the package from the global cache.

    The package manager already does this - if you install the HD pipeline then it should automatically be installing the core renderpipelines package as well. If that's not happening for you, it's a bug - please report it. :)

    From your project's point of view, kinda - the old files vanish and the new files appear - but in general we expect that the GUIDs for files will be consistent between different versions of a package, so e.g. if you have references to things in the package, those should not break (unless the new version actually removed the thing you're referencing).
     
    optimise likes this.
  3. optimise

    optimise

    Joined:
    Jan 22, 2014
    Posts:
    697
    Hi @superpig,
    I would be super nice if it supports able to keep pulling new version to the 'Packages' folder inside your project then remove redundant code, merge code and resolve code conflict just like version control so we can always get the new changes from the official package while still maintaining custom changes.

    Another feature I would also like to see is sometimes u just want to modify some files and u just override these files to the 'Packages' folder inside your project instead of whole full official package. When u build player, package manager will automatically use your custom files inside 'Packages' folder inside your project and override the official package. It will also able to detect and inform you if the file is no longer exists in the new version of official package that introduces breaking changes.

    Is this a bug? I use Unity Hub 0.16.0 and Unity 2018.1.0f1 to create a new project with High-Definition RP (Preview) template.

     
  4. Alex-Lian

    Alex-Lian

    Guest

    We expect to offer another pathway vs. embedding. Embedding will serve "short term immediate needs". Alternately, we do expect to offer a way to reference the git repo of the package itself, so you can modify, and merge at your control.

    Individual files would be hard to mix with the referenced version. I think we need to have a full copy of the package either embedded or as explained above as a repo.

    The Hub is expected to offer the templates, so that's to be expected and the HD RP template (Preview) is being offered in 2018.1 to be checked out.
     
    optimise likes this.
  5. optimise

    optimise

    Joined:
    Jan 22, 2014
    Posts:
    697
    Hi @Alex-Lian,
    I mean Render-pipelines core package does not automatically download. Seems like it's a bug. Just like what @superpig says

     
  6. elbows

    elbows

    Joined:
    Nov 28, 2009
    Posts:
    2,465
    Is there a plan to keep the version of pipeline etc used by the templates up-to-date? Because right now, choosing a SRP-based template, only to discover its using an old pipeline version and then having to update through the Package Manager UI, is not exactly a tidy experience. I've no objection to updating later using Package Manager UI when new packages are released, but to have the template use one that is already a number of versions out-of-date is disconcerting!
     
  7. Alex-Lian

    Alex-Lian

    Guest

    Ah yes, my misunderstanding. A bug, or really a deficiency at the moment. It's expected that the hub download all necessary and relevant packages for a template at the time its fetched.
     
    optimise likes this.
  8. Alex-Lian

    Alex-Lian

    Guest

    Yes, most definitely a concern and we haven't ironed out the right approach yet. We can't keep it perfectly up-to-date with respect to packages, because newer versions may have the reliance on new APIs not yet available in the version of Unity being used, etc.
     
    optimise and elbows like this.
unityunity