Commit Graph

2105 Commits

Author SHA1 Message Date
Sebastian Bor c99f4195f1
Governance: Voters weights add-in (#2450)
* feat: setup and configure voter weight addin

feat: add use_voter_weight_add_in flag to realm config

chore: use spl-governance 1.1.1 version

chore: make clippy happy

chore: add test to deserialise v1 CreateRealm instruction from v2

feat: add voter-weight-addin skeleton project

chore: build voter-weight-addin before governance

fix: temp workaround to make spl_governance_voter_weight_addin available in CI

chore: add tests with voter-weight-addin

feat: implement deposit instruction for voter weight addin

feat: add voter_weight_expiry

fix: set voter_weight_expiry

chore: restore positive execute tests

chore: restore ignored tests

wip: pass voter weight accounts to create_account_governance2

wip: read voter weight account

chore: make clippy happy

wip: add realm and validation to voter_weight deposit

fix: update addin

chore: make clippy happy

chore: fix voter_weight_record names

feat: use voter weight provided by addin when governance created

chore: update addin

chore: remove governance stake pool program

feat: remove time offset from revise

chore: fix build

feat: create RealmAddins account when realm with addin is created

chore: make clippy happy

feat: set voter weight addin using SetRealmConfig instruction

chore: make clippy happy

chore: update comments

chore: reorder SetrealmConfig accounts

chore: infer use_community_voter_weight_addin

chore: infer use_community_voter_weight_addin

chore: update voter weight addin comments

feat: use voter weight addin id from RealmAddins account

* feat: use voter weight addin to create proposal

* feat: use voter weight addin to cast vote

* chore: make clippy happy

* feat: use voter weight addin to create token governance

* feat: use voter weight addin to create mint governance

* feat: use voter weight adding to create program governance

* chore: create assert_can_withdraw_governing_tokens() helper function

* chore: fix compilation

* fix: ensure governance authority signed transaction to create governance

* feat: implement CreateTokenOwnerRecord instruction

* chore: fix chat tests

* chore: update comments

* chore: rename RealmAddins account to RealmConfig account

* chore: add more reserved space to GovernanceConfig account

* chore: update instruction comments

* chore: update comments

* chore: fix compilation

* chore: remove ignore directive for tests

* feat: panic when depositing tokens into a realm with voter weight addin

* chore: rename community_voter_weight to community_voter_weight_addin

* feat: make payer account optional for SetRealmConfig
2021-10-13 13:15:22 +01:00
Michael Vines 1c417ffa4f Fork Token 2022 program 2021-10-12 10:43:58 -07:00
Michael Vines 12732f8d5a Upgrade to Solana 1.8.0 2021-10-12 09:40:06 -07:00
Jon Cinque f630d71fdc
stake-pool-cli: Bump version to 0.6.2 (#2501) 2021-10-12 00:29:38 -04:00
Jon Cinque b8cc6fa12c
stake-pool-cli: Fix funding authority flag name (#2500) 2021-10-12 00:04:35 -04:00
joeaba 3cf123312e
adding PR target 2021-10-11 15:27:03 +05:30
joeaba c1ae9d34a2
turning off travis.yml by changing its formate from yml to txt so that it can't get triggered on travis 2021-10-11 11:19:29 +05:30
Jarry Xiao 290833e76d
Building on top of Toly's PR, v1 compiles (#2476)
* Building on top of Toly's PR, v1 compiles

* formatting

* minor architecture changes and comments

* more formatting

* refactor of processor

* Might pass formatting now; TODO add native token logic

* Comment typos

* clippy

* order swap

* changed the ordering of some print statements

* modified source code to transfer SOL directly in the case that the taker mint is equal to Native SOL

* formatting

* Explicitly check for delegate in the source code

* formatting

* Added debug logs to test client, fixed some lingering bugs

* Clippy
2021-10-09 16:16:49 -05:00
axleiro 4a45f4a896
Update spl_action.yml 2021-10-09 18:12:42 +05:30
joeaba 5be914885e
adding spl_action.yml 2021-10-09 13:40:40 +05:30
dependabot[bot] df959d0605
build(deps-dev): bump flowgen from 1.14.1 to 1.15.0 in /token-swap/js (#2492)
Bumps flowgen from 1.14.1 to 1.15.0.

---
updated-dependencies:
- dependency-name: flowgen
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-10-07 10:15:57 +00:00
Jon Cinque 13375afff2
stake-pool: Add last epoch values for APR calculation (#2491)
* stake-pool: Add last epoch values for APR calculation

* Bump versions for release
2021-10-07 00:01:15 -04:00
dependabot[bot] 06563bf879
build(deps-dev): bump @types/node in /token-lending/js (#2488)
Bumps [@types/node](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/node) from 16.10.2 to 16.10.3.
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/node)

---
updated-dependencies:
- dependency-name: "@types/node"
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-10-06 09:19:39 +00:00
Jon Cinque 3d52925865
stake-pool: Bump version for 0.6.0 release (#2487) 2021-10-06 00:11:20 -04:00
Jon Cinque b80c10f406
stake-pool: Add withdraw-sol command + CLI + docs (#2475)
* stake-pool: plumb sol withdraw fee and authority

* Add sol withdraw instruction and processor

* Cleanup sysvar usage

* Fix stack size violation

* Add tests

* Add CLI support

* Add docs for new command

* Integrate review feedback
2021-10-05 22:44:03 -04:00
dependabot[bot] 28adc9656b
build(deps-dev): bump @typescript-eslint/eslint-plugin (#2483)
Bumps [@typescript-eslint/eslint-plugin](https://github.com/typescript-eslint/typescript-eslint/tree/HEAD/packages/eslint-plugin) from 4.32.0 to 4.33.0.
- [Release notes](https://github.com/typescript-eslint/typescript-eslint/releases)
- [Changelog](https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/CHANGELOG.md)
- [Commits](https://github.com/typescript-eslint/typescript-eslint/commits/v4.33.0/packages/eslint-plugin)

---
updated-dependencies:
- dependency-name: "@typescript-eslint/eslint-plugin"
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-10-05 09:17:16 +00:00
dependabot[bot] 2cc7a01679
build(deps-dev): bump @typescript-eslint/parser in /token-lending/js (#2482)
Bumps [@typescript-eslint/parser](https://github.com/typescript-eslint/typescript-eslint/tree/HEAD/packages/parser) from 4.32.0 to 4.33.0.
- [Release notes](https://github.com/typescript-eslint/typescript-eslint/releases)
- [Changelog](https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/parser/CHANGELOG.md)
- [Commits](https://github.com/typescript-eslint/typescript-eslint/commits/v4.33.0/packages/parser)

---
updated-dependencies:
- dependency-name: "@typescript-eslint/parser"
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-10-05 09:17:06 +00:00
dependabot[bot] c371995c86
build(deps-dev): bump typedoc from 0.22.4 to 0.22.5 in /token-lending/js (#2480)
Bumps [typedoc](https://github.com/TypeStrong/TypeDoc) from 0.22.4 to 0.22.5.
- [Release notes](https://github.com/TypeStrong/TypeDoc/releases)
- [Changelog](https://github.com/TypeStrong/typedoc/blob/master/CHANGELOG.md)
- [Commits](https://github.com/TypeStrong/TypeDoc/compare/v0.22.4...v0.22.5)

---
updated-dependencies:
- dependency-name: typedoc
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-10-04 09:18:16 +00:00
dependabot[bot] 1b5b891594
build(deps-dev): bump @rollup/plugin-commonjs in /token-lending/js (#2479)
Bumps [@rollup/plugin-commonjs](https://github.com/rollup/plugins/tree/HEAD/packages/commonjs) from 20.0.0 to 21.0.0.
- [Release notes](https://github.com/rollup/plugins/releases)
- [Changelog](https://github.com/rollup/plugins/blob/master/packages/commonjs/CHANGELOG.md)
- [Commits](https://github.com/rollup/plugins/commits/commonjs-v21.0.0/packages/commonjs)

---
updated-dependencies:
- dependency-name: "@rollup/plugin-commonjs"
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-10-04 09:16:52 +00:00
dependabot[bot] 53c94ed13d
build(deps-dev): bump rollup from 2.57.0 to 2.58.0 in /token-lending/js (#2477)
Bumps [rollup](https://github.com/rollup/rollup) from 2.57.0 to 2.58.0.
- [Release notes](https://github.com/rollup/rollup/releases)
- [Changelog](https://github.com/rollup/rollup/blob/master/CHANGELOG.md)
- [Commits](https://github.com/rollup/rollup/compare/v2.57.0...v2.58.0)

---
updated-dependencies:
- dependency-name: rollup
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-10-01 09:18:23 +00:00
dependabot[bot] f236d6ec7f
build(deps-dev): bump flow-bin from 0.160.2 to 0.161.0 in /token-swap/js (#2471)
Bumps [flow-bin](https://github.com/flowtype/flow-bin) from 0.160.2 to 0.161.0.
- [Release notes](https://github.com/flowtype/flow-bin/releases)
- [Commits](https://github.com/flowtype/flow-bin/commits)

---
updated-dependencies:
- dependency-name: flow-bin
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-09-30 10:38:12 +00:00
dependabot[bot] 8facdabb65
build(deps): bump @solana/web3.js in /token-swap/js (#2470)
Bumps [@solana/web3.js](https://github.com/solana-labs/solana-web3.js) from 1.29.0 to 1.29.2.
- [Release notes](https://github.com/solana-labs/solana-web3.js/releases)
- [Changelog](https://github.com/solana-labs/solana-web3.js/blob/master/.releaserc.json)
- [Commits](https://github.com/solana-labs/solana-web3.js/compare/v1.29.0...v1.29.2)

---
updated-dependencies:
- dependency-name: "@solana/web3.js"
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-09-30 09:30:18 +00:00
dependabot[bot] 9a29e79f55
build(deps-dev): bump @types/node in /token-lending/js (#2469)
Bumps [@types/node](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/node) from 16.10.1 to 16.10.2.
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/node)

---
updated-dependencies:
- dependency-name: "@types/node"
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-09-30 09:17:59 +00:00
dependabot[bot] 431c867aeb
build(deps-dev): bump @solana/web3.js in /token-lending/js (#2468)
Bumps [@solana/web3.js](https://github.com/solana-labs/solana-web3.js) from 1.29.1 to 1.29.2.
- [Release notes](https://github.com/solana-labs/solana-web3.js/releases)
- [Changelog](https://github.com/solana-labs/solana-web3.js/blob/master/.releaserc.json)
- [Commits](https://github.com/solana-labs/solana-web3.js/compare/v1.29.1...v1.29.2)

---
updated-dependencies:
- dependency-name: "@solana/web3.js"
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-09-30 09:16:59 +00:00
joeaba 2496e7862d
Update and rename spl_action.yml to spl_action.txt 2021-09-30 01:54:26 +05:30
joeaba 18cd17cf85
Update and rename spl_action.txt to spl_action.yml 2021-09-30 01:44:36 +05:30
joeaba b3176c6479
commenting.action.yml 2021-09-30 01:38:36 +05:30
Michael Vines abc06eed68 Avoid hard coding spl_token id 2021-09-29 12:49:15 -07:00
joeaba e3d80c2695
uncomment .travis.yml 2021-09-30 01:06:47 +05:30
joeaba a3feb1d16a
Update spl_action.yml 2021-09-30 01:04:14 +05:30
joeaba dee9767470
test 2021-09-30 00:32:47 +05:30
joeaba 0204d29441
rename .travis.yml file with .travis.txt 2021-09-29 17:18:49 +05:30
joeaba fbc2ed6eb2
commented .travis.yml 2021-09-29 17:12:29 +05:30
joeaba 85d928f931
addding action.yml 2021-09-29 16:23:26 +05:30
Ryo Onodera 2221e5df74 token-cli: Bump version to 2.0.15 2021-09-28 22:03:41 +09:00
dependabot[bot] d00b971e57
build(deps-dev): bump @typescript-eslint/eslint-plugin (#2462)
Bumps [@typescript-eslint/eslint-plugin](https://github.com/typescript-eslint/typescript-eslint/tree/HEAD/packages/eslint-plugin) from 4.31.2 to 4.32.0.
- [Release notes](https://github.com/typescript-eslint/typescript-eslint/releases)
- [Changelog](https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/CHANGELOG.md)
- [Commits](https://github.com/typescript-eslint/typescript-eslint/commits/v4.32.0/packages/eslint-plugin)

---
updated-dependencies:
- dependency-name: "@typescript-eslint/eslint-plugin"
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-09-28 09:46:12 +00:00
dependabot[bot] efac04a809
build(deps-dev): bump @types/node in /token-lending/js (#2461)
Bumps [@types/node](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/node) from 16.9.6 to 16.10.1.
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/node)

---
updated-dependencies:
- dependency-name: "@types/node"
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-09-28 09:30:53 +00:00
dependabot[bot] dac34d4016
build(deps-dev): bump @typescript-eslint/parser in /token-lending/js (#2460)
Bumps [@typescript-eslint/parser](https://github.com/typescript-eslint/typescript-eslint/tree/HEAD/packages/parser) from 4.31.1 to 4.32.0.
- [Release notes](https://github.com/typescript-eslint/typescript-eslint/releases)
- [Changelog](https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/parser/CHANGELOG.md)
- [Commits](https://github.com/typescript-eslint/typescript-eslint/commits/v4.32.0/packages/parser)

---
updated-dependencies:
- dependency-name: "@typescript-eslint/parser"
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-09-28 09:16:53 +00:00
dependabot[bot] 07155a0fc9
build(deps-dev): bump @types/prettier in /token-lending/js (#2459)
Bumps [@types/prettier](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/prettier) from 2.3.2 to 2.4.1.
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/prettier)

---
updated-dependencies:
- dependency-name: "@types/prettier"
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-09-28 09:15:23 +00:00
Muhammed Abiola 3e945798fc
Update twitter.ts (#2454)
Minor contraction error.
2021-09-27 10:58:11 -06:00
dependabot[bot] 2122e68d34
build(deps-dev): bump @solana/web3.js in /token-lending/js (#2455)
Bumps [@solana/web3.js](https://github.com/solana-labs/solana-web3.js) from 1.29.0 to 1.29.1.
- [Release notes](https://github.com/solana-labs/solana-web3.js/releases)
- [Changelog](https://github.com/solana-labs/solana-web3.js/blob/master/.releaserc.json)
- [Commits](https://github.com/solana-labs/solana-web3.js/compare/v1.29.0...v1.29.1)

---
updated-dependencies:
- dependency-name: "@solana/web3.js"
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-09-27 09:16:54 +00:00
Jon Cinque 5337a4f17f
stake-pool: Use `matches!` to allow for fix in underlying error (#2453) 2021-09-26 23:58:30 +02:00
joeaba 1aa12ad24d
Update .travis.yml 2021-09-25 13:57:48 +05:30
dependabot[bot] e7bec90dbc
build(deps): bump ansi-regex from 5.0.0 to 5.0.1 in /token-lending/js (#2452)
Bumps [ansi-regex](https://github.com/chalk/ansi-regex) from 5.0.0 to 5.0.1.
- [Release notes](https://github.com/chalk/ansi-regex/releases)
- [Commits](https://github.com/chalk/ansi-regex/compare/v5.0.0...v5.0.1)

---
updated-dependencies:
- dependency-name: ansi-regex
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-09-24 10:45:08 +00:00
dependabot[bot] 6087affb60
build(deps-dev): bump flow-bin from 0.160.1 to 0.160.2 in /token-swap/js (#2451)
Bumps [flow-bin](https://github.com/flowtype/flow-bin) from 0.160.1 to 0.160.2.
- [Release notes](https://github.com/flowtype/flow-bin/releases)
- [Commits](https://github.com/flowtype/flow-bin/commits)

---
updated-dependencies:
- dependency-name: flow-bin
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-09-24 10:26:25 +00:00
Ryo Onodera 462f1e0708
Really plumb dump_transaction_message (#2448) 2021-09-24 12:05:26 +09:00
Jon Cinque 006c410534
stake-pool-cli: Update minimum balance to be correct (#2449) 2021-09-24 01:46:37 +02:00
Jon Cinque d8b8aae4f5
stake-pool: Update docs and help messages (#2435)
* stake-pool: Update docs and help messages

* Integrate review feedback
2021-09-23 23:42:25 +02:00
Alexander Ray 11a36d9bd1
- fix "attempt to subtract with overflow" issue (#2445)
* - fix "attempt to subtract with overflow" issue

* Update stake-pool/cli/src/main.rs

Co-authored-by: Jon Cinque <jon.cinque@gmail.com>

* Update stake-pool/cli/src/main.rs

Co-authored-by: Jon Cinque <jon.cinque@gmail.com>

* - run cargo fmt on it

Co-authored-by: Jon Cinque <jon.cinque@gmail.com>
2021-09-22 21:53:32 +02:00
dependabot[bot] c013698891
build(deps-dev): bump rollup from 2.56.3 to 2.57.0 in /token-lending/js (#2444)
Bumps [rollup](https://github.com/rollup/rollup) from 2.56.3 to 2.57.0.
- [Release notes](https://github.com/rollup/rollup/releases)
- [Changelog](https://github.com/rollup/rollup/blob/master/CHANGELOG.md)
- [Commits](https://github.com/rollup/rollup/compare/v2.56.3...v2.57.0)

---
updated-dependencies:
- dependency-name: rollup
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-09-22 10:18:10 +00:00