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

fetch and assign async inputs and token details on transaction detail live #781

Conversation

tenmoves
Copy link
Contributor

Description

Please include a summary of the change and which issue is fixed. Please also include relevant motivation and context. List any dependencies that are required for this change.

Fixes #774

Type of change

Please delete options that are not relevant.

  • Bug fix (non-breaking change which fixes an issue)

How Has This Been Tested?

Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce. Please also list any relevant details for your test configuration

  • Tested locally on the page

Checklist:

  • My code follows the style guidelines of this project
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings
  • I have added tests that prove my fix is effective or that my feature works
  • New and existing unit tests pass locally with my changes
  • Any dependent changes have been merged and published in downstream modules

@tenmoves tenmoves added UI Invole user interface core team Assigned to the core team labels Dec 15, 2022
@tenmoves tenmoves self-assigned this Dec 15, 2022
|> assign(:token_properties, %{})
end

defp async_assign_uco_price(timestamp) do
Copy link
Member

Choose a reason for hiding this comment

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

I think this one is not necessary to use async here as it's a direct read of the ETS table.

Copy link
Contributor Author

@tenmoves tenmoves Dec 15, 2022

Choose a reason for hiding this comment

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

ok thanks, so I will keep everything inside handle_transaction function, except the 3 fields related to tokens and inputs.
do you think it's useful to first process inputs send a msg and assign and then spawn another task for tokens or it's not worth it ? (I think it's not worth it)

Copy link
Member

Choose a reason for hiding this comment

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

I think it might, because the token information is a "good to have" but not a "must to have", whereas the list of inputs is a hard requirement.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

done

@tenmoves tenmoves marked this pull request as ready for review December 16, 2022 09:13
@tenmoves tenmoves requested a review from Neylix December 16, 2022 09:13
@samuelmanzanera
Copy link
Member

Thanks for the PR. Seems ok for me.
Waiting the next with the stream of inputs.

@samuelmanzanera samuelmanzanera merged commit 7cfcee2 into archethic-foundation:develop Dec 22, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
core team Assigned to the core team UI Invole user interface
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Transaction's details timeout with internal server error
3 participants