Coder Social home page Coder Social logo

Comments (4)

junderw avatar junderw commented on July 17, 2024 1

The bc1qdlxcmcncy059gw0my604y35s5257mxua6ttlje output is at index: 1, but you're using index: 0,...

I don't understand what you're talking about. Your input is clearly pointing to a different UTXO.

from bitcoinjs-lib.

junderw avatar junderw commented on July 17, 2024

The error is pretty clear.

It can’t sign for that input with that pubkey because that pubkey is unrelated to that input.

from bitcoinjs-lib.

bormisov1 avatar bormisov1 commented on July 17, 2024

The error is pretty clear.

It can’t sign for that input with that pubkey because that pubkey is unrelated to that input.

Sorry, what do you mean unrelated? This txn has bc1qdlxcmcncy059gw0my604y35s5257mxua6ttlje as output address, which can be derrived via bitcoin.payments.p2wpkh from 03163883cf37d71960982ee74ad91168160322688a78769f9c3db9bc72ab1142a9 pubkey.
And this hex is a raw representation of referenced tx:

010000000001017a5d1fd9635a4fe15beff85a18fc32651ff07736abc24d07afa9d0d8b66c656d0000000000ffffffff02b80b0000000000001600142e212c99d59342f463726ea8f0340a48f56fde049b530000000000001600146fcd8de27823e85439fb269f524690a2a9ed9b9d02483045022100ecab202e666a63668a1b68dcd873be4d57d61e2cbdd8f39b895e70d384b3e143022031ca826e45e944f38d4c9e95dc23ecf97035ed4b73b094feee84f057e0c1e721012103163883cf37d71960982ee74ad91168160322688a78769f9c3db9bc72ab1142a900000000

from bitcoinjs-lib.

bormisov1 avatar bormisov1 commented on July 17, 2024

The bc1qdlxcmcncy059gw0my604y35s5257mxua6ttlje output is at index: 1, but you're using index: 0,...

I don't understand what you're talking about. Your input is clearly pointing to a different UTXO.

Oh sorry, that was so stupid of me. Indeed this index: 0 caused the issue, and the code worked by coincidence when I had output mint index match an index at which this output would go in a new transaction. Sorry for wasting your time.

At least might be a hint for somebody as heedless as me in future... Thank you for your help and for this repository!

from bitcoinjs-lib.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.