Commit b977367
committed
Merge #391: docs(changeset): Add section on version compatibility
80c962b docs(changeset): Add section on version compatibility (valued mammal)
e9bd912 fix(changeset): Add serde(default) attribute to locked_outpoints field (valued mammal)
Pull request description:
### Description
Partially addresses #234 by improving the documentation of `ChangeSet` by adding a version compatibility policy, clarifying what upgrade/downgrade paths are supported and how breaking changes should be handled. It also adds the `#[serde(default)]` attribute to `locked_outpoints` which is a newly added field in 3.0.
In summary the policy says:
- Changes to the `ChangeSet` data structure will correspond to a major version bump.
- Version N can read/deserialize data written by N-1, i.e., one major version back, but this guarantee doesn't extend to version N-2 or earlier.
- New fields introduced in version N must implement `Default` so that when deserializing, any missing fields are filled in with the default.
- Version N-1 can deserialize version N data by ignoring unknown fields, with the caveat that not all features from version N will be available.
- Outline a 3-version deprecation cycle
### Changelog notice
Changed
- Added `#[serde(default)]` to `ChangeSet::locked_outpoints`
### Checklists
#### All Submissions:
* [x] I've signed all my commits
* [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk/blob/master/CONTRIBUTING.md)
ACKs for top commit:
luisschwab:
ACK 80c962b
oleonardolima:
ACK 80c962b
Tree-SHA512: dec7197750ccbffaf3c8f99a82d8c9be40a88eb27c73b7fd33b07afe5af1e0d3496ed0a55efa2bcf3486ececfb44b25413bb3cbd40905fe9b2f76b6f938e8f2e1 file changed
Lines changed: 37 additions & 5 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
76 | 76 | | |
77 | 77 | | |
78 | 78 | | |
79 | | - | |
| 79 | + | |
80 | 80 | | |
81 | | - | |
82 | | - | |
83 | | - | |
84 | | - | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
| 100 | + | |
| 101 | + | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
| 106 | + | |
| 107 | + | |
| 108 | + | |
| 109 | + | |
| 110 | + | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
85 | 115 | | |
86 | 116 | | |
87 | 117 | | |
| |||
102 | 132 | | |
103 | 133 | | |
104 | 134 | | |
| 135 | + | |
105 | 136 | | |
106 | 137 | | |
107 | 138 | | |
| |||
117 | 148 | | |
118 | 149 | | |
119 | 150 | | |
| 151 | + | |
120 | 152 | | |
121 | 153 | | |
122 | 154 | | |
| |||
0 commit comments