git.iko.soy/typeable/swagger2
on v2.3 help sign in
typeable/swagger2/CHANGELOG.md
260 lines 12 kB history raw
12.3
2---
4Major changes:
6- Add support for `additionalProperties` with `Bool` value (see [#159](https://github.com/GetShopTV/swagger2/pull/159));
7- Add `ToSchema` `Object` instance (for aeson's `Object`) (see [`d72466a`](https://github.com/GetShopTV/swagger2/commit/d72466a));
9Dependencies and CI:
11- Aeson 1.4 (see [#158](https://github.com/GetShopTV/swagger2/pull/158));
12- Update .travis.yml (see [#160](https://github.com/GetShopTV/swagger2/pull/160));
13- Allow network 2.7 (see [#155](https://github.com/GetShopTV/swagger2/pull/155));
14- Allow lens-4.17 (see [#161](https://github.com/GetShopTV/swagger2/pull/161));
162.2.2
17-----
19* Add `ToSchema Version` instance
20* Use base-compat-batteries (0.10)
21* PVP bounds
232.2.1
24-----
26* Add `Semigroup` instances
27* GHC-8.4 compatibility
28* `Schema (NonEmpty a) instance (see [#141](https://github.com/GetShopTV/swagger2/pull/141))
29* Fix optional property for unary records (see [#142](https://github.com/GetShopTV/swagger2/issues/142))
30* Add `fromAesonOptions` helper (see [#146](https://github.com/GetShopTV/swagger2/issues/139))
31* Fix non-termination when using `datatypeNameModifier` with recursive data types (see [#132](https://github.com/GetShopTV/swagger2/issues/132))
332.2
34---
36* Treat unknown properties as validation errors in `validateToJSON` (see [#126](https://github.com/GetShopTV/swagger2/pull/126));
37* Add `validateJSON` and `validateJSONWithPatternChecker` to validate JSON `Value` against `Schema` without classes (see [#126](https://github.com/GetShopTV/swagger2/pull/126));
38* Add more `Schema` helpers (see [#126](https://github.com/GetShopTV/swagger2/pull/126)):
39 * `genericNameSchema` — to give a custom schema `Generic`-based name;
40 * `genericDeclareNamedSchemaNewtype` — to derive `NamedSchema` for `newtype`s;
41 * `declareSchemaBoundedEnumKeyMapping` — to derive more specific `Schema` for maps with `Bounded` `Enum` keys;
42* Add a few tests with invalid `Schema`.
442.1.6
45-----
47* Add `ToParamSchema` and `ToSchema` instances for `Fixed` (see [#121](https://github.com/GetShopTV/swagger2/pull/121)) and `Natural` (see [#123](https://github.com/GetShopTV/swagger2/pull/123));
48* Fix instance for `NominalDiffTime` (see [#121](https://github.com/GetShopTV/swagger2/pull/121));
49* Fix build for `aeson-1.2.2.0` (see [#125](https://github.com/GetShopTV/swagger2/pull/125)).
512.1.5
52-----
54* Type error by default when deriving Generic-based instances for mixed sum types (see [#118](https://github.com/GetShopTV/swagger2/pull/118));
55* Adjust `allOf` to accept referenced schemas (see [#119](https://github.com/GetShopTV/swagger2/issues/119));
56* Add instances for `Identity` (see [#116](https://github.com/GetShopTV/swagger2/pull/116));
57* Add Gitter chat badge (see [#114](https://github.com/GetShopTV/swagger2/pull/114)).
592.1.4.1
60-------
62* GHC-8.2 support (see [#95](https://github.com/GetShopTV/swagger2/issues/95), [#106](https://github.com/GetShopTV/swagger2/pull/106) and [#108](https://github.com/GetShopTV/swagger2/pull/108));
63* Documentation corrections (see [#105](https://github.com/GetShopTV/swagger2/pull/105));
64* Allow `generics-sop-0.3` (see [#102](https://github.com/GetShopTV/swagger2/pull/102));
65* Fix `ToSchema` example in docs (see [#104](https://github.com/GetShopTV/swagger2/pull/104)).
672.1.4
68-----
70* Add `liftDeclare` (see [#100](https://github.com/GetShopTV/swagger2/pull/100));
71* Add `MonadDeclare` instances for all monad transformers (see [#100](https://github.com/GetShopTV/swagger2/pull/100)).
732.1.3
74-----
76* Add [`UUID`](http://hackage.haskell.org/package/uuid-types/docs/Data-UUID-Types.html#t:UUID) instances (see [#81](https://github.com/GetShopTV/swagger2/pull/81)).
77* Add [`TypeError`](https://hackage.haskell.org/package/base-4.9.0.0/docs/GHC-TypeLits.html#g:4) `ToSchema` and `ToParamSchema ByteString` instances (see [#78](https://github.com/GetShopTV/swagger2/pull/78))
78* Improve documentation for generic sum type instance derivation (see [#75](https://github.com/GetShopTV/swagger2/pull/75))
79* Compile warning free (see [#82](https://github.com/GetShopTV/swagger2/pull/82))
812.1.2.1
82-------
84* Bug fix previous release
862.1.2
87---
89* Minor changes:
90 * Support `aeson-1.0.0.0` (see [#70](https://github.com/GetShopTV/swagger2/pull/70)).
922.1.1
93---
95* Minor changes:
96 * Proper `Schema` examples for `Char`, `Day`, `LocalTime`, `ZonedTime` and `UTCTime`.
982.1
99---
101* Major changes:
102 * Use `InsOrdHashMap` to preserve insertion order for endpoints and definitions (see [#56](https://github.com/GetShopTV/swagger2/pull/56));
103 * Add support for GHC 8.0 (see [#65](https://github.com/GetShopTV/swagger2/pull/65)).
1052.0.2
106---
108* Fixes:
109 * Fix `additionalProperties` to allow references;
110 * Fix `ToSchema` instances for `Map` and `HashMap` (prevent infinite recursion for recursive values).
1122.0.1
113---
115* Fixes:
116 * Re-export `Pattern` synonym from `Data.Swagger`;
117 * Documentation fixes.
1192.0
120---
122* Major changes:
123 * GHC 7.8 support (see [#49](https://github.com/GetShopTV/swagger2/pull/49));
124 * Switch to classy field lenses (see [#41](https://github.com/GetShopTV/swagger2/pull/41));
125 * Add `Data.Swagger.Schema.Validation` (see [#18](https://github.com/GetShopTV/swagger2/pull/18));
126 * Add `Data.Swagger.Operation` with helpers (see [#50](https://github.com/GetShopTV/swagger2/pull/50));
127 * Add `IsString` instances for some types (see [#47](https://github.com/GetShopTV/swagger2/pull/47));
128 * Add helpers to sketch `Schema` from JSON (see [#48](https://github.com/GetShopTV/swagger2/pull/48)).
130* Minor changes:
131 * Make `NamedSchema` a `data` rather than `type` (see [#42](https://github.com/GetShopTV/swagger2/pull/42));
132 * Change `Definitions` to `Definitions Schema`;
133 * Add schema templates for `"binary"`, `"byte"` and `"password"` formats (see [63ed597](https://github.com/GetShopTV/swagger2/commit/63ed59736dc4f942f0e2a7d668d7cee513fa9eaf));
134 * Add `Monoid` instance for `Contact`;
135 * Change `tags` to be `Set` rather than list.
137* Fixes:
138 * Fix schema for `()` and nullary constructors (see [ab65c4a](https://github.com/GetShopTV/swagger2/commit/ab65c4a48253c34f8a88221a53dc97bf5e6e8d29));
139 * Fix `Operation` `FromJSON` instance to allow missing `tags` and `parameters` properties.
1411.2.1
142---
144* Minor changes:
145 * Change `_SwaggerItemsPrimitive` type from a `Prism'` to a more restrictive `Review`-like `Optic'`.
147* Fixes:
148 * Fix build for GHC 8.0-rc1.
1501.2
151---
152* Minor changes (see [#36](https://github.com/GetShopTV/swagger2/pull/36)):
153 * Change default `ToSchema` instance for unit data types (i.e. types with one nullable constructor like `data Unit = Unit`):
154 now these types are treated like sum types with only one alternative;
155 * Add generic `ToParamSchema` instance for unit data types;
156 * Add `items: []` to schema for `()` (making it a valid schema).
158* Fixes:
159 * Do not omit `items: []` from `Schema` JSON;
160 * Do not generate unused definitions for nested `newtype`s (see [#38](https://github.com/GetShopTV/swagger2/pull/38)).
1621.1.1
163---
164* Fixes:
165 * `CollectionFormat Param` -> `CollectionFormat ParamOtherSchema`;
166 this change was necessary after putting `CollectionFormat` to `SwaggerItems`.
1681.1
169---
170* Major changes:
171 * Put `CollectionFormat` in one place (see [`3cc860d`](https://github.com/GetShopTV/swagger2/commit/3cc860dd3f002ab984f4d0e4ce1d1799f985832e)).
173* Minor changes:
174 * Use Swagger formats for `Int32`, `Int64`, `Float`, `Double`, `Day` and `ZonedTime` (see [#32](https://github.com/GetShopTV/swagger2/pull/32));
175 * Export `HeaderName`, `TagName`, `HttpStatusCode` type synonyms;
176 * Add `ToParamSchema` instances for `[a]`, `Set a` and `HashSet a`;
177 * Add `Monoid` instances for `Header` and `Example`.
179* Fixes:
180 * Use overwrite strategy for `HashMap` `SwaggerMonoid` instances by default.
1821.0
183---
184* Major changes:
185 * Add `Data` and `Typeable` instances for `Data.Swagger` types;
186 * Merge `ParamType`/`ItemsType`/`SchemaType` into `SwaggerType` GADT;
187 * Merge collection format types into `CollectionFormat` GADT;
188 * Introduce `SwaggerItems` GADT, replacing `Items` and `SchemaItems` in `ParamSchema` (see [#24](https://github.com/GetShopTV/swagger2/pull/24));
189 * Move type, format and items fields to `ParamSchema` (former `SchemaComon`);
190 * Prepend reference path automatically (see [commit 49d1fad](https://github.com/GetShopTV/swagger2/commit/49d1fadd2100644e70c442667180d0d73e107a5f))
191 and thus remove `"#/definitions/"` from user code, leaving much clearer `Reference "Name"`;
192 * Change `Data.Swagger.Schema` (see [#19](https://github.com/GetShopTV/swagger2/pull/19)):
193 * Change the only method of `ToSchema` to `declareNamedSchema` which should produce a `NamedSchema`
194 along with a list of schema definitions used to produce it;
195 * Add `declareSchema`, `declareSchemaRef`;
196 * Replace `genericTo*` helpers with `genericDeclare*` helpers;
197 * Add `paramSchemaTo[Named]Schema` helpers to facilitate code reuse for primitive schemas;
198 * Add helpers for inlining `Schema` references dynamically (see [#23](https://github.com/GetShopTV/swagger2/pull/23));
199 * Add `ToParamSchema` class (see [#17](https://github.com/GetShopTV/swagger2/pull/17)) with
200 * generic default implementation and
201 * instances for some base types compliant with `http-api-data` instances;
202 * Add `Data.Swagger.Declare` module with
203 * `DeclareT` monad transformer;
204 * `MonadDeclare` type class;
205 * various helpers;
206 * Rename parameter-related types:
207 * `Parameter` -> `Param`;
208 * `ParameterSchema` -> `ParamAnySchema`;
209 * `ParameterOtherSchema` -> `ParamOtherSchema`;
210 * `ParameterLocation` -> `ParamLocation`;
211 * `SchemaCommon` -> `ParamSchema`;
212 * `parameter*` fields renamed to `param*` fields;
213 * `schemaCommon*` fields renamed to `paramSchema*` fields;
214 * `HasSchemaCommon` -> `HasParamSchema`.
216* Minor changes:
217 * Replace TH-generated JSON instances with `Generic`-based (see [#25](https://github.com/GetShopTV/swagger2/pull/25));
218 * Drop `template-haskell` dependency;
219 * Omit empty array/object properties from `toJSON` output ([#22](https://github.com/GetShopTV/swagger2/pull/22));
220 * Remove `minLength` property from schemas for `time` types;
221 * Move `SchemaOptions` to `Data.Swagger.SchemaOptions`;
222 * Remove `useReferences` from `SchemaOptions` (see [#23](https://github.com/GetShopTV/swagger2/pull/23));
223 * Place all internal submodules under `Data.Swagger.Internal`;
224 * Better documentation (see [#26](https://github.com/GetShopTV/swagger2/pull/26)).
2260.4.1
227---
228* Fixes:
229 * Use `PackageImports` for `Data.HashSet` to avoid test failure on stackage (see [#15](https://github.com/GetShopTV/swagger2/issues/15));
230 * Add an upper version bound for `aeson` due to `aeson-0.10.0.0` bug (see [bos/aeson#293](https://github.com/bos/aeson/issues/293));
231 * Switch to Cabal-based multi GHC Travis config.
2330.4
234---
235* Remove `Swagger`/`swagger` prefixes;
236* Add `ToSchema` type class with default generic implementation;
237* Add configurable generic `ToSchema` helpers;
238* Add `doctest` test suite;
239* Fixes:
240 * Fix `HasSchemaCommon` instance for `Schema`;
241 * Change `minimum`, `maximum` and `multipleOf` properties to be any number,
242 not necessarily an integer;
243 * Fix all warnings.
2450.3
246---
247* Fixes:
248 * Fix `SwaggerMonoid Text` instance;
249 * Wrap `Bool` in `Maybe` everywhere;
250 * These changes make all `Data.Swagger` `Monoid` instances obey monoid laws
251 (previously right identity law was broken by some instances).
2530.2
254---
255* Add `Data.Swagger.Lens`;
256* Support references;
257* Fixes:
258 * Fix `FromJSON SwaggerHost` instance;
259 * Add missing `Maybe`s for field types;
260 * Decode petstore `swagger.json` successfully.