DetectPackageComplete / PackageState wrong #7392
-
I am upgrading a Wix v3 MSI and bootstrapper to v4. The bootstrapper also installs SQL Server Express 2017 as shown in this fragment.
On my system, I already have SQL Server installed and the v3 installer recognizes that it is installed. However, for the v4 installer when the DetectPackageComplete event is fired, the PackageState for this SQL Server package is Cached as shown in the screen print below. One other thing to note in the screen print - the state is cached, but the boolean variable "Cached" is false. When I look at the comment for Cached (“The package is not installed but is in the package cache.”), I do not believe it should be returning cached in this instance. I believe it should return Present as the v3 installer does. Here is a part of the log bundle log. It did detect that it was installed.
So, why did it say Cached for the package state? Is this a bug? thanks for any help |
Beta Was this translation helpful? Give feedback.
Replies: 4 comments 2 replies
-
It says Cached because this is a bug. The Cached value of the managed enum should have been removed at the same time it was removed from the native header in wixtoolset/burn#55. |
Beta Was this translation helpful? Give feedback.
-
OK. Will this be fixed in the next release of Wix? Until then, is it safe to say on v4.0 "== cached || == present" if what I really want is "== present"? |
Beta Was this translation helpful? Give feedback.
-
thanks - I will use "> absent". |
Beta Was this translation helpful? Give feedback.
-
Hey @Steve0212a , can you please guide me on how are you performing step debugging of wix installer as shown in this screenshot- |
Beta Was this translation helpful? Give feedback.
I don't know if will be in the next release, that depends on someone creating a bug for this and then us triaging it next week.
Since the cached value was moved to a separate boolean value, 99.9% of the time you would want to workaround this by doing "> absent". Almost nobody will need to tell the difference between Present and Superseded.