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

wrapper: handle intent baskets #286

Merged
merged 11 commits into from
Apr 30, 2019
Merged

wrapper: handle intent baskets #286

merged 11 commits into from
Apr 30, 2019

Conversation

sohkai
Copy link
Contributor

@sohkai sohkai commented Apr 17, 2019

Has a few kinks to work out, but works for single-transaction organization upgrades.

Copy link
Contributor

@izqui izqui left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💯

packages/aragon-wrapper/src/index.js Outdated Show resolved Hide resolved
async getTransactionPathForIntentBasket (intentBasket, { checkMode = 'all' } = {}) {
// Get transaction paths for entire basket
const intentsToCheck =
checkMode === 'all'
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Contributor

@2color 2color Apr 26, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is that because the intentBasket coming from the client will have the same path (they all call setApp)?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

all isn't used yet, since our only use case is calling the same function, but in the future when you might be including very different transactions (e.g. withdraw from Finance and burn a token at the same time, see aragon/client#363), it'll be important to use all to check that all the actions can actually be performed together.

@2color
Copy link
Contributor

2color commented Apr 26, 2019

I tested the direct transaction scenario on an org with an account that has the Manage apps permission and it only upgraded the voting app. See the transaction and the org

Moreover, the activity item didn't render the correct description:
Screen Shot 2019-04-26 at 12 11 53 pm

@sohkai
Copy link
Contributor Author

sohkai commented Apr 26, 2019

I tested the direct transaction scenario on an org with an account that has the Manage apps permission and it only upgraded the voting app.

Yes... debugging this with the client now. The problem is that if you have direct access, the only thing we can do is ask you to sign multiple transactions (and this bit isn't working well yet).

@luisivan luisivan mentioned this pull request Apr 29, 2019
25 tasks
@sohkai
Copy link
Contributor Author

sohkai commented Apr 29, 2019

The logic for how radspec is handled as been completely refactored into its own module. In the future we may think about letting users of @aragon/wrapper define their own radspec "preprocessors".

This also strips out a few unnecessary details out of the intents:

  • identifier: this was broken as part of 5.0.0-beta.1 anyway, since the identifier information has now been split from the apps observable
  • name: this is easily found by users if they match a path's to address with the corresponding app object

@2color
Copy link
Contributor

2color commented Apr 30, 2019

Still getting an error with 3color.aragonid.eth on rinkeby.
Screen Shot 2019-04-30 at 10 07 31 am

Could that be related to the removal of name?

https://github.com/aragon/aragon/blob/9ca9963681c7d94317879a7ac350a41bc898d2b6/src/components/SignerPanel/ActionPathsContent.js#L134-L140

Update: Working with latest master of aragon/client#732

@2color 2color closed this Apr 30, 2019
@2color 2color reopened this Apr 30, 2019
@sohkai
Copy link
Contributor Author

sohkai commented Apr 30, 2019

@2color Are you using the current head of aragon/client#732? It should be handling the removal of name now.

@2color 2color self-requested a review April 30, 2019 10:16
@sohkai sohkai merged commit 45a18a1 into master Apr 30, 2019
@sohkai sohkai deleted the intent-basket branch April 30, 2019 14:34
2color added a commit to 2color/aragon.js that referenced this pull request May 14, 2019
…th-cache

* origin/master:
  @aragon/wrapper 5.0.0-rc.5
  fix: add back name and identifer to describe script (aragon#299)
  wrapper: return original step if radspec couldn't be evaluated (aragon#298)
  @aragon/wrapper 5.0.0-rc.3
  wrapper: handle intent baskets (aragon#286)
  @aragon/wrapper 5.0.0-rc.3
  Wrapper: add artifacts for aragonPM apps (aragon#273)
  Wrapper: override fetched app info with on-chain values (aragon#288)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants