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

Blockchain Engineering: Token Transaction Engine III #153

Open
wants to merge 150 commits into
base: master
Choose a base branch
from

Conversation

Jorgeromeu
Copy link

@Jorgeromeu Jorgeromeu commented Apr 19, 2023

Implemented a Token Transaction Engine for use in DeToks. More information can be found in the README

Jorgeromeu and others added 30 commits March 5, 2023 21:37
Missing implementation of sending a token authenticated with ipv8 overlay.
Token basic structure
…1/trustchain-superapp into feature/initial_token_sending
…1/trustchain-superapp into feature/initial_token_sending
Transaction with local host:
- proposal half-block
- sign and send proposal half-block
- agreement half-block
- sign and send agreement half-block
Decide to agree a proposal receive trough a pop-up message
…integrate with TrustChainApplication.kt and automaticly build the interfaces for database functions etc
To find new peers, first use the button "find peers", then it is possible to send proposal and receive agreement among 2 different peers.
Problems:
- Inconsistent. Sometimes blocks are not received
Merge mainline tribbler into our fork
@Jorgeromeu Jorgeromeu temporarily deployed to apk_build April 19, 2023 15:36 — with GitHub Actions Inactive
@timhuisman1 timhuisman1 temporarily deployed to apk_build April 20, 2023 07:34 — with GitHub Actions Inactive
Copy link
Collaborator

@OrestisKan OrestisKan left a comment

Choose a reason for hiding this comment

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

Codebase is pretty clean and no major issue found in the code.

val record = rowView.findViewById(R.id.item_number) as TextView
val token_id = rowView.findViewById(R.id.item_id) as TextView

record.text = "Group:" + (token.tokenIntId / groupAmount) + " Token ID: " + token.tokenIntId
Copy link
Collaborator

Choose a reason for hiding this comment

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

Using format strings is better

Comment on lines +96 to +98
var newID = uid
if (sendingToSelf) {
newID = UUID.randomUUID().toString()
Copy link
Collaborator

Choose a reason for hiding this comment

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

I don't see the Id being being incremented just randomized

var newID = uid
//Log.d(LOGTAG, "Sending to self: $sendingToSelf")
if (sendingToSelf) {
newID = UUID.randomUUID().toString()
Copy link
Collaborator

Choose a reason for hiding this comment

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

Again just random not incremented

* Receive a grouped token agreement block and remove tokens from personal database
* @param block: The agreement block
*/
@Suppress("UNCHECKED_CAST")
Copy link
Collaborator

Choose a reason for hiding this comment

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

Not a good practice

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.

6 participants