Dynamo: Package Manager broken: Screws up folder structure and deletes data from JSON file

Created on 1 Mar 2018  路  9Comments  路  Source: DynamoDS/Dynamo

Dynamo version

Dynamo 1.2

Operating system

Win 10

What did you do?

Publish update to Dynamo Package via the Package Manager

What did you expect to see?

An updated package adhering to the folder structure

What did you see instead?

The folder structure is changed (the 'extra' folders dll's get copied to the bin folder (so they appear in both folders) and the XML description file gets put in extras even though it should be in the root directory, i.e. bin).

The other annoying problem it has is wiping the node libraries property from the JSON file, so if the package is then downloaded after updating, nothing appears in the library, so I have to re-publish the package to fix it. This needs to be fixed as its been an ongoing issue now for months.

Package Manager

Most helpful comment

Yep its a pain in the arse. One recommendation that I now use: add your pkg.JSON to your Visual Studio project and when you up-version your assembly, ensure you update your JSON accordindly. I also increment the package version while I'm at it, so when I publish a new version via the package manager I have nothing to input (into its nasty dialog), simply upload and thats it.

All 9 comments

Hi @ThomasMahon, if you publish an update locally do you see the same behavior?

Hi @mjkkirschner yep, I get the same behavior publishing locally. Could it be caused by the dll's in my extra's folder being compiled with other versions of the Revit API and Package Manager thinking they are the primary package dll's so it automatically moves them to the bin folder?

@ThomasMahon can you post a zip of your package including the json header file?

@mjkkirschner sure, as attached:

BimorphNodes.zip

Also, I published this version locally to test, and the problem with the JSON file node_libraries property also cropped up as you will see when you unzip the files - the property is reset to an empty list, so nothing appears in Dynamo when launched. The only solution I've found is to manually update it, then republish...a nuisance for users, not to mention the negative impacts on my semantic versioning

@ThomasMahon so one thing to consider regarding the node_libraries property.

This array contains the fullName of the assembly including specific version - if you have updated your package to include a new version of this assembly (via incrementing the assembly version in visual studio) then the package is likely finding that the previously noted assembly is no longer present and removing it from the list. - As that version indeed might no longer be present.

if you manually mark the new assembly as a nodeLibrary using the very hard to find right click on .dll context menu in the package manager client UI does that fix that particular issue?

Hi @mjkkirschner you are spot-on, that was the cause of the wiping of the parameter. If I right-click I can specify the up-versioned package dll as the new assembly and it publishes correctly.

The issue of mixing the dll's from the extra folder still persists however.

@ThomasMahon so one thing to consider regarding the node_libraries property.

This array contains the fullName of the assembly including specific version - if you have updated your package to include a new version of this assembly (via incrementing the assembly version in visual studio) then the package is likely finding that the previously noted assembly is no longer present and removing it from the list. - As that version indeed might no longer be present.

if you manually mark the new assembly as a nodeLibrary using the very hard to find right click on .dll context menu in the package manager client UI does that fix that particular issue?

I published a new version, but it did not work for anyone, not even me. I spent a lot of time researching until I could solve this problem on my own. I came here to create a report on this problem and found this solution. It turns out that this problem was discussed more than a year ago! But finding this solution is impossible until you solve the problem yourself!

Yep its a pain in the arse. One recommendation that I now use: add your pkg.JSON to your Visual Studio project and when you up-version your assembly, ensure you update your JSON accordindly. I also increment the package version while I'm at it, so when I publish a new version via the package manager I have nothing to input (into its nasty dialog), simply upload and thats it.

This is a great idea! Thank you! I will do the same.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

aliasguru picture aliasguru  路  10Comments

LuisaCPBR picture LuisaCPBR  路  4Comments

mccrone picture mccrone  路  8Comments

ksobon picture ksobon  路  11Comments

DrLicor picture DrLicor  路  4Comments