jwaliszko / ExpressiveAnnotations

Annotation-based conditional validation library.
MIT License
351 stars 123 forks source link

Wrong JavaScript version in NuGet 2.9.6 #190

Closed SpaceOgre closed 6 years ago

SpaceOgre commented 6 years ago

I installed the package 2018-02-19 and did not notice then, but today I needed the __meta__.element and it was not present. Then I noticed that the version that ships with NuGet states 2.7.4 in the js file.

To be able to upload it I hade to add txt at the end, otherwise it is the file that came with NuGet.

expressive.annotations.validate.js.txt

I fixed it temporarily by just copy the file here from GitHub.

jwaliszko commented 6 years ago

v2.9.6 product release contains following components:

MVC package contains all 3 components, so product version is always the same as the MVC package version. Minimal package contains only single component, mainly ExpressiveAnnotations.dll core annotations assembly. This is also mentioned in the installation section of the documentation.

Some more explanation:

At the initial stage of working at this library I had been thinking of how to version the releases. At first I thought the highest version of all the components will automatically define the version of the package. But after a while I realized it is not always possible, and manual versioning is needed - example is below:

init version ---> A.dll v1.0.0, B.dll v1.0.0, C.js v1.0.0 ---> release ---> NuGet package v1.0.0
bug fix in A ---> A.dll v1.0.1, B.dll v1.0.0, C.js v1.0.0 ---> release ---> NuGet package v1.0.1
bug fix in B ---> A.dll v1.0.1, B.dll v1.0.1, C.js v1.0.0 ---> release ---> NuGet package v?.?.? 
                                                                                   (chosen 1.0.2)
bug fix in B ---> A.dll v1.0.1, B.dll v1.0.2, C.js v1.0.0 ---> release ---> NuGet package v?.?.? 
                                                                                   (chosen 1.0.3)
feature in C ---> A.dll v1.0.1, B.dll v1.0.2, C.js v1.1.0 ---> release ---> NuGet package v?.?.? 
                                                                                   (chosen 1.1.0)

Because many NuGet packages contain only single component, there is no discrepancy between the package version and such a component (assembly/script/etc.) version.

SpaceOgre commented 6 years ago

Ah, makes sense.