When does wyUpdate fall back to the all-to newest version?

I am now testing wyBuild for one of our larger projects.

I have done a tiny change in the file, the patch itself was 79 kB. After running wyUpdate.exe manually, I saw status saying "cancelling update" for a short while and then it started downloading the whole package (I guess the app.all.to.newest version.wys was downloaded)

Could the order of creation of client.wyc be the source of this problem? (described here: viewtopic.php?f=1&t=301) or can there by a different cause of wyUpdate downloading the whole 30 MB package?

The client.wyc file might be the cause of the problem, but only if the version embedded in the client.wyc file doesn't match the version of your app.

Otherwise the problem is caused by a file not being patched properly. You can debug this by unchecking the "Create a catch-all update for corrupt installations" in "File->Properties->Update & Server files".

Then rebuild your updates, and test again. If it fails to patch again it will list the file.

Tell me if this helps.

I have now located the file - it is the resources file.

"Patch failed to apply to C:\Program Files\Company\Product Family\Product\bin\SomeAddin\de\App.resources.dll"

What is special about this file is that it is included in the deployment twice under different folders.

Once under bin\SomeAddin\de\Once under bin\de\

I have not been able to reproduce this in a test project with duplicates of simple text files, neither with the same files contained in this deployment.

If I rename the failing file before running wyUpdate.exe, same error (apparently due to a different cause, but no additional information is displayed)

It seems to be a more complex issue related to project structure or to file permissions within the Program Files folder...

How do I get a better error message out of wyUpdate? I am ready to recompile it, just please give me pointers where to look to include better (more detailed) error handling+reporting.

I seriously doubt it's a problem with file permissions - if it were you'd have seen the problem with other files.

The reason you see the Patch failed to apply is that the source file in your test folder is different than the file being referenced by wyBuild when it's creating the files.

If I were to guess I would say the problem is that instead of copying the file from "\de\App.resources.dll" to "\bin\SomeAddin\de\App.resources.dll" you compile the file twice - once to each of the folders. Then in wyBuild you might reference the same file for both folders even though the files are subtly different.

In wyBuild try referencing the same file in both folders. That is, add the same single "App.resources.dll" for both the "\de\" and the "\bin\SomeAddin\de\" folders. Then copy this same referenced file to the version you're testing your updates for.

Rebuild your updates, upload them, and retest.

Tell me if you still get an error.

The reason you see the Patch failed to apply is that the source file in your test folder is different than the file being referenced by wyBuild when it's creating the files.

If I were to guess I would say the problem is that instead of copying the file from "\de\App.resources.dll" to "\bin\SomeAddin\de\App.resources.dll" you compile the file twice - once to each of the folders. Then in wyBuild you might reference the same file for both folders even though the files are subtly different.

In wyBuild try referencing the same file in both folders. That is, add the same single "App.resources.dll" for both the "\de\" and the "\bin\SomeAddin\de\" folders. Then copy this same referenced file to the version you're testing your updates for.

Rebuild your updates, upload them, and retest.

Tell me if you still get an error.

I still get the error. I am absolutely certain that the package is built correctly. After compilation, we have a script that harvests all files, collects the directory structure as it will appear when installed in program files and copies this to a separate folder for the version that is currently being built. I then drag and drop all files from the folder into wyBuild. No space for user error by adding individual files manually.

I actually found out that the file is the same in two locations in our setup only after I started to investigate this problem. I am not copying/including the file by hand relying on the fact that it is the same file 🙂.

Can you run one more test? Make a simple project with a single file - the file that's failing to be patched when updating from version X to version Y.

Does it fail to be patched in this simple case?