Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(docs): add changelog for Unlock 13 and PublicLock 14 #13534

Merged
merged 2 commits into from Mar 28, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
21 changes: 20 additions & 1 deletion docs/docs/core-protocol/public-lock/README.md
Expand Up @@ -47,11 +47,30 @@ Lock managers can also alter the behavior of their locks thru the use of [hooks]

Changelogs can be found here for the last two versions.

### Version 14

**Released:**: Jan 2024

The version 14 introduces several changes in user-facing features :

- Introduces `setKeyExpiration` to allow a lock manager to update the timestamp of any existing keys freely
- Modifies `getHasValidKey` so a hook has a final say while determining the validity of a key
- Allows a lock manager to always transfer keys, even when transfers are disabled
- Disables fees for lock managers when transferring or sharing a key

For advanced users and developers, the lower level changes below are noteworthy:

- Replace `UnlockUtils` dependencies by optimized Open Zeppelin implementation
- Remove dev reward/cut when purchasing a key
- Add unchecked scopes on math operations (gas optimisation)
- New Solidity version 0.8.21 (creating issues on some chains that wont support new `PUSH0` evm opcode)
- Fix potential overflow when merging keys

### Version 13

**Released**: April 2023

This new version improved gas consumption of most functions (by using Solidity custom errors instead of require statements). It solves issues that were appearing when canceling or burning membership keys.
This new version improved gas consumption of most functions (by using Solidity custom errors instead of require statements). It solves issues that were appearing when canceling or burning membership keys.

The helpers functions `addKeyGranter` and `isKeyGranter` have been removed to reduce the size of the contract. The features are still accessible by calling directly `grantRole` and `hasRole` with `keccak256('KEY_GRANTER_ROLE')` as role.

Expand Down
16 changes: 16 additions & 0 deletions docs/docs/core-protocol/unlock/README.md
Expand Up @@ -11,3 +11,19 @@ This is our "factory" contract **(Unlock.sol)** and has several roles.
As of summer 2021, the unlock contract is **owned** by a multi-sig wallet managed by Unlock Inc. Our goal is to move toward decentralization by transferring ownership of the Unlock contact to [the Unlock DAO](../../governance/unlock-dao/).

This contract is upgradable using OpenZeppelin's upgradability framework. As of now, the ProxyAdmin is **owned** by a multi-sig wallet managed by Unlock Inc. Our goal is to move toward decentralization by transferring ownership of the Unlock contact to the [Unlock DAO](../../governance/unlock-dao/). Each implementation is versioned. The method `unlockVersion()` will yield the current version.

# Changelog

## Version 13

**Released**: Feb 2024

The main novelty in the version 13 of Unlock is a “swap and burn” feature that allow fees collected by the protocol to directly decrease the supply of UDT in circulation.

### **How it works**

- Fees are collected by the Unlock contract when a membership or subscription key is purchased or extended
- Fees are kept by the main Unlock contract, and can be denominated in any native or ERC20 currencies
- By calling the `swapAndBurn` function, the collected fees are sent from the Unlock contract to a contract that will 1) convert the tokens for the collected protocol fees to UDT (using Uniswap) and 2) send those UDT tokens to a burn address

In earlier versions of the protocol, UDT governance tokens were distributed by the Unlock contract using a developer reward. This is now deprecated and should be replaced by the protocol fee. The protocol fee is not enabled by default, and it will be up to the DAO to enable it now that the tools are in place.