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

Rename erc20next to erc20 #3019

Closed
2 of 3 tasks
golmek opened this issue Jan 22, 2024 · 1 comment · Fixed by #3020, golemfactory/goth#666, #3032 or #3033
Closed
2 of 3 tasks

Rename erc20next to erc20 #3019

golmek opened this issue Jan 22, 2024 · 1 comment · Fixed by #3020, golemfactory/goth#666, #3032 or #3033
Assignees

Comments

@golmek
Copy link
Contributor

golmek commented Jan 22, 2024

Payment Driver - Backward compatibility

  • New Payment driver will get name of old payment driver erc20.
  • Decorate demand API will return new property - protocol.version , which will limit Requestors to accept only new Providers (version ≥ 2)
  • Provider offer need new property and constraint protocol.version , which will limit Provider to accept only new Requestors (version ≥ 2)
  Provider v1 Provider v2
Requestor - v1 OK (only v1 will not reject, because they do not have properties) NOT OK (constraint on provider)
Requestor - v2 NOT OK (constraint on requestor) OK
"payment":{
   "protocol.version": 2,
   "debit-notes":{
      "accept-timeout?":240
   },
   "platform":{
      "erc20-rinkeby-tglm":{
         "address":"0x86a269498fb5270f20bdc6fdcf6039122b0d3b23"
      },
      "zksync-rinkeby-tglm":{
         "address":"0x86a269498fb5270f20bdc6fdcf6039122b0d3b23"
      }
   }
}

Benefits:

  1. Lack of changes in older applications as we do not change erc20 name
  2. No communication to end user is needed
  3. Not accepted payments on old driver will be automatically migrated to the new one.
  4. Change is transparent for SDK

Drawbacks:

  1. We split network - new payment driver need to propagate through network and achieve > 50%. We need to phase out AR migration to new payment driver over time.
  2. Accepted but not settled payments on old driver will not be automatically migrated to the new one - payments will stuck forever. It should impact very small amount of users.

Source: https://hackmd.io/ghBbvjtkTnujJPbgm977YA?view

Acceptance Criteria:

  • Rename erc20next to erc20
  • Add ProtocolVersion to platform in the offer
  • Constraint ProtocolVersion in the demand to prevent interacting with old providers
@kamirr kamirr changed the title Payment Driver - new approach Rename erc20next to erc20 Jan 22, 2024
@kamirr kamirr reopened this Jan 22, 2024
@kamirr kamirr linked a pull request Jan 31, 2024 that will close this issue
@kamirr kamirr closed this as completed Jan 31, 2024
@kamirr kamirr linked a pull request Jan 31, 2024 that will close this issue
@golmek
Copy link
Contributor Author

golmek commented Feb 1, 2024

After discussion with Requc:
constraint on provider - was removed.
consequently - new Provider will be able to talk with new and old Requestors

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment