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

Automatic Detect Change Addresses #206

Open
besoeasy opened this issue Jan 27, 2025 · 2 comments
Open

Automatic Detect Change Addresses #206

besoeasy opened this issue Jan 27, 2025 · 2 comments

Comments

@besoeasy
Copy link

Hey while scanning by default it scans for 500 address, it only scans receiving address.

While we can verify change address by edit root option, my suggestion is that it should be automatically checked as well.

@JamieDriver
Copy link
Collaborator

JamieDriver commented Jan 27, 2025

Jade scans in blocks of 500 the usual/standard receive address space.
Yes, you can tweak that a bit - ie. you could add the /1/ if you wanted to scan for a change address instead.
You're suggesting scanning /0/* (receive) and /1/* by default ?
ofc this is not difficult, it just makes scanning take twice as long to get to eg. index 500 (as you'd have to check 1000 addresses rather than 500).
Perfectly doable though.

@besoeasy
Copy link
Author

besoeasy commented Jan 27, 2025

To expand on my previous message about address validation optimization - I propose this streamlined approach for the next update:

function checkAddress(address, index) {
   // 1. Check against receive addresses first
   if (isValidReceiveAddress(address, index)) {
       return true; // or return address object if needed
   }
   
   // 2. Fallback to change address check
   if (isValidChangeAddress(address, index)) {
       return true; // or return address object if needed
   }
   
   // 3. No matches found
   return false;
}

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

No branches or pull requests

2 participants