bitcoin core – Transaction status: 0 / not confirmed, not in mempool

The software Bitcoin Core is using?

Then you need to have your software forget about your unconfirmed transaction that is not in the mempool, so you can do it again at a higher fee.

When starting your Bitcoin Core, run it with -zapwallettxes. This will make your wallet forget about the unconfirmed transactions relevant to your wallet. You can learn how to add that on Andrew Chow's blog.

Then the balance in your wallet must be converted to the balance before making the payment.

I learned this from here, but the other two methods are not applicable as you need to change your transaction to increase the fee.

bitcoin core – bitcoinjs-lib how to add multiple utxos in addInput

Hello, I want to do bitcoin bech32 address transactions using bitcoinjs-lib, here is my code below, it works fine when my address has only one utxos but when it increments to two or more as its array which doesn't pass to the addInput method then it fails. Please help me to go through it or what is the solution to handle multiple utxo as input.
Thank you

const bitcoin = require("bitcoinjs-lib");

//creating and signing a native p2wpkh
//p2wpk: addInput('00000....', 0, prevOutScript)
//sign(0, keyPair,,,value)

let NETWORK = bitcoin.networks.litecoin; 
let txb = new bitcoin.TransactionBuilder(NETWORK);

//get unspent output details
let txid = "9d1517a2499ce5496ba3c826785b25982c63dc5b59b0c256303bf19128e44747"; //transaction id of the output you want to spend
let outn = 0;  // n out

let keypair = bitcoin.ECPair.fromWIF(WIF, NETWORK);
let scriptPubkey = bitcoin.script.witnessPubKeyHash.output.encode(
                       bitcoin.crypto.hash160(  
                           keypair.getPublicKeyBuffer()
                       )
                   );

//add input
txb.addInput(txid, outn, null, scriptPubkey);

//add output
txb.addOutput("ltc1q9umns6nuxv3xrhzdwlmhkzujewu6hulyuwgx30",4999000); //first argument is receiving address, the second is the amount we are sending after deducting a mining fee

//signing
txb.sign(0, keypair, null, null, 5000000); //NOTE the amount is the FULL amount of the unspent output, NOT the amount we are sending
let tx = txb.build();
let txhex = tx.toHex();

console.log(txhex);

bitcoin core: creating custom transactions

I am currently learning how to create raw transactions. I can already create standard using bitcoin core (0.19.1), but when I wanted to create with custom opcode like this:

asm: OP_HASH160 d0c3f50336b5f109207d722c692191ff86263e96 OP_EQUAL OP_DROP 1
hex: a914d0c3f50336b5f109207d722c692191ff86263e96877551
  1. I created a raw transaction
createrawtransaction '({"txid":"1c164f99a7cd0fe6dba9a7fe10ad3c2be132a9260d4ccdeaf7e279073946ac52","vout":0})' '{"2MxmdfXx8rKGUmWUwQu59GksMNRdnQiRRM2":0.195}'

020000000152ac46390779e2f7eacd4c0d26a932e12b3cad10fea7a9dbe60fcda7994f161c0000000000ffffffff01e08b29010000000017a9143c98df42d7a69c7fd165aeb6128d45f21eeeac4d8700000000
  1. But when I wanted to sign this transaction, an error occurred (I also tried to modify the raw transaction from the first step) here is the result with the raw transaction modified from above, but still not working
signrawtransactionwithkey '020000000152ac46390779e2f7eacd4c0d26a932e12b3cad10fea7a9dbe60fcda7994f161c0000000000ffffffff0130c11d000000000019a914d0c3f50336b5f109207d722c692191ff86263e9687755100000000' '("$privkey")' '({"txid":"1c164f99a7cd0fe6dba9a7fe10ad3c2be132a9260d4ccdeaf7e279073946ac52","vout":0,"scriptPubKey":"a914d0c3f50336b5f109207d722c692191ff86263e96877551","redeemScript":"001453352afbbaa8cad22304201de8fbcc29e83fb2db","amount":0.02})'

Previous output scriptPubKey mismatch:
OP_HASH160 d0c3f50336b5f109207d722c692191ff86263e96 OP_EQUAL
vs:
OP_HASH160 d0c3f50336b5f109207d722c692191ff86263e96 OP_EQUAL OP_DROP 1 (code -22)

Now I know I am doing something wrong, but I don't know what and I can't find any information on how to do it correctly. So I have questions:

  1. What am I doing wrong?

  2. Can I create custom transactions using the Bitcoin core? If so, how?

  3. If I can't use this wallet, how can I do it? I'd be grateful for an example

Cannot send raw transaction Bitcoin Core 0.19.1 – script verification flag not required (signature must be zero for failed SIG CHECK (MULTI) operation)

I wanted to send a raw testnet transaction and was doing it like in the bitcoin documentation, but I still get this error:

non-mandatory script verification flag (signature must be zero for failed SIG CHECK (MULTI) operation) (code 64) (code -26).

What am I doing wrong?

  1. I take a transaction from me listunspent
{
    "txid": "8ee71fee9e4706100c09fb2da4c3ccdac1a4475981bd893ba1eba9417947abff",
    "vout": 0,
    "address": "2Mw44JvAhBs4hgh5bT3gP2NgbhTbVwngW1m",
    "label": "",
    "redeemScript": "00143b88811e01b3efaa0bcd9da16ef85ef3a1583349",
    "scriptPubKey": "a91429c3d920cd18e34db9035c4322474aae4465792187",
    "amount": 0.02641617,
    "confirmations": 16197,
    "spendable": true,
    "solvable": true,
    "desc": "sh(wpkh((8939dfa5/0'/0'/8')02a44b3dd2f0964048265982156f668c037dfabc140eb98f292dbb723d28b85261))#husuy9tw",
    "safe": true
}
  1. Then I create a raw transaction from this:
createrawtransaction '({"txid":"8ee71fee9e4706100c09fb2da4c3ccdac1a4475981bd893ba1eba9417947abff","vout":0})' '{"2NCH5HXBwfHegFEUTNrkSKzyYTnTYQKDUjU":0.02}'
  1. dumpprivkey

  2. And sign the transaction like this

signrawtransactionwithkey '0200000001ffab477941a9eba13b89bd815947a4c1daccc3a42dfb090c1006479eee1fe78e0000000000ffffffff0180841e000000000017a914d0c3f50336b5f109207d722c692191ff86263e968700000000' '(" $privKey ")' '({"txid":"8ee71fee9e4706100c09fb2da4c3ccdac1a4475981bd893ba1eba9417947abff","vout":0,"scriptPubKey":"a91429c3d920cd18e34db9035c4322474aae4465792187","redeemScript":"00143b88811e01b3efaa0bcd9da16ef85ef3a1583349","amount":0.02})'

{
  "hex": "02000000000101ffab477941a9eba13b89bd815947a4c1daccc3a42dfb090c1006479eee1fe78e00000000171600143b88811e01b3efaa0bcd9da16ef85ef3a1583349ffffffff0180841e000000000017a914d0c3f50336b5f109207d722c692191ff86263e968702473044022010c174b3306cac5ca8ddbb6eadf0de2299c2a216ade25088290c17880aa5bd60022017bc9de608e7ff59ffa09a6a60d848875d37edfc4a4b687f0eb94d4c2cd11b4f012102a44b3dd2f0964048265982156f668c037dfabc140eb98f292dbb723d28b8526100000000",
  "complete": true
}

But when I want to send a raw transaction

sendrawtransaction 02000000000101ffab477941a9eba13b89bd815947a4c1daccc3a42dfb090c1006479eee1fe78e00000000171600143b88811e01b3efaa0bcd9da16ef85ef3a1583349ffffffff0180841e000000000017a914d0c3f50336b5f109207d722c692191ff86263e968702473044022010c174b3306cac5ca8ddbb6eadf0de2299c2a216ade25088290c17880aa5bd60022017bc9de608e7ff59ffa09a6a60d848875d37edfc4a4b687f0eb94d4c2cd11b4f012102a44b3dd2f0964048265982156f668c037dfabc140eb98f292dbb723d28b8526100000000

non-mandatory-script-verify-flag (Signature must be zero for failed CHECK(MULTI)SIG operation) (code 64) (code -26)

I tried a lot of transactions but I can't send it and I can't see what I'm doing wrong. Normally the Bitcoin Core submit button works fine.

Skills: when to use cheating vs. relationship in Fate Core

Let's see the rules.

Cheat

Cheating is the ability about lie and mislead people.

Rapport

Rapport skill is about making positive connections with people and generating positive emotions. It is the ability to be loved and trustworthy.

People don't trust liars. If you lie, you use deception;

However, people who are sincere without tact all the time are not pleasant and everyone knows that there are questions for which no one expects an honest answer and that is puzzling if you get it. For example, how are you? Presumably, no checks are required for such routine hoaxes, and I'm assuming the Duchess's question isn't one of these despite looking like one.

Now Destiny has mechanisms to overcome limits: aspects and stunts.

For your example, ask for a cheat check, but if the player wants to use a relationship they must accept an obligation in a new aspect: cheating flatterer and if they fail the duchess gets hollow. The player gets what he wants at a price.

In the long run, they can take the trick Flexible with the truth: Twice per session you can use Rapport instead of Cheat.

c ++ – Create OpenGL 4 context for WinAPI (Core and new – style context)

I'm trying to create a new style context OpenGL 4.2 in kernel mode for Windows OS (using WinAPI). My code is work:

#include 
#include 
#include 
#include 

using GLchar = char;
using DEBUGPROC = void (APIENTRY*)(GLenum source,
    GLenum type,
    GLuint id,
    GLenum severity,
    GLsizei length,
    const GLchar * message,
    const void* userParam);
using GlDebugMessageCallback = void(APIENTRY*)(DEBUGPROC callback,
    const void* userParam);
using WglCreateContextAttribsARB = HGLRC(APIENTRY*)(HDC, HGLRC, const int*);
using WglSwapIntervalEXT = BOOL(WINAPI*)(int interval);

#define GL_DEBUG_SOURCE_API               0x8246
#define GL_DEBUG_SOURCE_WINDOW_SYSTEM     0x8247
#define GL_DEBUG_SOURCE_SHADER_COMPILER   0x8248
#define GL_DEBUG_SOURCE_THIRD_PARTY       0x8249
#define GL_DEBUG_SOURCE_APPLICATION       0x824A
#define GL_DEBUG_SOURCE_OTHER             0x824B
#define GL_DEBUG_TYPE_ERROR               0x824C
#define GL_DEBUG_TYPE_DEPRECATED_BEHAVIOR 0x824D
#define GL_DEBUG_TYPE_UNDEFINED_BEHAVIOR  0x824E
#define GL_DEBUG_TYPE_PORTABILITY         0x824F
#define GL_DEBUG_TYPE_PERFORMANCE         0x8250
#define GL_DEBUG_TYPE_OTHER               0x8251
#define GL_DEBUG_TYPE_MARKER              0x8268
#define GL_DEBUG_TYPE_PUSH_GROUP          0x8269
#define GL_DEBUG_TYPE_POP_GROUP           0x826A
#define GL_DEBUG_SEVERITY_NOTIFICATION    0x826B
#define GL_DEBUG_LOGGED_MESSAGES          0x9145
#define GL_DEBUG_SEVERITY_HIGH            0x9146
#define GL_DEBUG_SEVERITY_MEDIUM          0x9147
#define GL_DEBUG_SEVERITY_LOW             0x9148
#define GL_DEBUG_OUTPUT                   0x92E0
#define WGL_CONTEXT_CORE_PROFILE_BIT_ARB            0x00000001
#define WGL_CONTEXT_DEBUG_BIT_ARB                   0x0001
#define WGL_CONTEXT_FLAGS_ARB                       0x2094
#define WGL_CONTEXT_FORWARD_COMPATIBLE_BIT_ARB      0x0002
#define WGL_CONTEXT_LAYER_PLANE_ARB                 0x2093
#define WGL_CONTEXT_MAJOR_VERSION_ARB               0x2091
#define WGL_CONTEXT_MINOR_VERSION_ARB               0x2092
#define WGL_CONTEXT_PROFILE_MASK_ARB                0x9126

LRESULT CALLBACK WndProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam);
void APIENTRY glDebugOutput(GLenum source, GLenum type, GLuint id, GLenum severity, GLsizei length, const GLchar* message, const void* userParam);

int width = 750;
int height = 500;

int WINAPI WinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance, LPSTR lpCmdLine, int nCmdShow)
{
    // init window
    WNDCLASSEX wc;
    HWND hwnd;
    MSG msg;
    ZeroMemory(&wc, sizeof(WNDCLASSEX));
    wc.cbSize = sizeof(WNDCLASSEX);
    wc.lpfnWndProc = WndProc;
    wc.hInstance = hInstance;
    wc.hIcon = LoadIcon(NULL, IDI_APPLICATION);
    wc.hCursor = LoadCursor(NULL, IDC_ARROW);
    wc.hbrBackground = (HBRUSH)(COLOR_GRAYTEXT);
    wc.lpszClassName = "windowGL";
    wc.hIconSm = LoadIcon(NULL, IDI_APPLICATION);
    if (!RegisterClassEx(&wc))
        return 0;
    hwnd = CreateWindowEx(
        WS_EX_CLIENTEDGE,
        "windowGL",
        "The title Win32GL",
        WS_OVERLAPPEDWINDOW,
        CW_USEDEFAULT, CW_USEDEFAULT, width, height,
        NULL, NULL, hInstance, NULL);

    // init gl
    HGLRC hRC;
    HDC hDC = GetDC(hwnd);
    int pf = 0;
    PIXELFORMATDESCRIPTOR pfd = { 0 };
    pfd.nSize = sizeof(pfd);
    pfd.nVersion = 1;
    pfd.dwFlags = PFD_DRAW_TO_WINDOW | PFD_SUPPORT_OPENGL | PFD_DOUBLEBUFFER;
    pfd.iPixelType = PFD_TYPE_RGBA;
    pfd.cColorBits = 24;
    pfd.cDepthBits = 16;
    pfd.iLayerType = PFD_MAIN_PLANE;
    pf = ChoosePixelFormat(hDC, &pfd);
    SetPixelFormat(hDC, pf, &pfd);

    int flags() = { WGL_CONTEXT_MAJOR_VERSION_ARB, 4,
        WGL_CONTEXT_MINOR_VERSION_ARB, 4,
        WGL_CONTEXT_FLAGS_ARB, WGL_CONTEXT_FORWARD_COMPATIBLE_BIT_ARB | WGL_CONTEXT_DEBUG_BIT_ARB,
        WGL_CONTEXT_PROFILE_MASK_ARB, WGL_CONTEXT_CORE_PROFILE_BIT_ARB,
        0 };

    // make context
    HGLRC TempRC = wglCreateContext(hDC);
    wglMakeCurrent(hDC, TempRC);
    WglCreateContextAttribsARB wglCreateContextAttribsARB = (WglCreateContextAttribsARB)wglGetProcAddress("wglCreateContextAttribsARB");
    hRC = wglCreateContextAttribsARB(hDC, 0, flags);
    wglMakeCurrent(hDC, hRC);
    wglDeleteContext(TempRC);

    // vsync
    WglSwapIntervalEXT wglSwapIntervalEXT = (WglSwapIntervalEXT)wglGetProcAddress("wglSwapIntervalEXT");
    wglSwapIntervalEXT(0);

    // gl debug
    glEnable(GL_DEBUG_OUTPUT);
    GlDebugMessageCallback glDebugMessageCallback = (GlDebugMessageCallback)wglGetProcAddress("glDebugMessageCallbackARB");
    glDebugMessageCallback(glDebugOutput, 0);

    ShowWindow(hwnd, nCmdShow);
    UpdateWindow(hwnd);
    try
    {
        while (true)
        {
            if (PeekMessage(&msg, NULL, 0, 0, PM_REMOVE))
            {
                if (msg.message == WM_QUIT)
                    break;
                TranslateMessage(&msg);
                DispatchMessage(&msg);
            }
            else
            {
                glClearColor(0.8f, 0.5f, 0.9f, 1.0f);
                glClear(GL_COLOR_BUFFER_BIT);
                SwapBuffers(hDC);
            }
        }
    }
    catch (const std::exception & e)
    {
        MessageBox(NULL, e.what(), "Error!", MB_ICONERROR);
        return -1;
    }
    return 0;
}


LRESULT CALLBACK WndProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam)
{
    switch (msg)
    {
    case WM_CLOSE:
        DestroyWindow(hwnd);
        break;
    case WM_DESTROY:
        PostQuitMessage(0);
        break;
    case WM_SIZE:
        width = LOWORD(lParam);
        height = HIWORD(lParam);
        glViewport(0, 0, width, height);
        break;
    default:
        return DefWindowProc(hwnd, msg, wParam, lParam);
    }
    return 0;
}

void APIENTRY glDebugOutput(GLenum source, GLenum type, GLuint id, GLenum severity, GLsizei length, const GLchar* message, const void* userParam)
{
    if (id == 131169 || id == 131185 || id == 131218 || id == 131204)
        return;

    std::stringstream error;
    error << "---------------" << std::endl;
    error << "Debug message (" << id << "): " << message << std::endl;

    switch (source)
    {
    case GL_DEBUG_SOURCE_API:
        error << "Source: API";
        break;
    case GL_DEBUG_SOURCE_WINDOW_SYSTEM:
        error << "Source: Window System";
        break;
    case GL_DEBUG_SOURCE_SHADER_COMPILER:
        error << "Source: Shader Compiler";
        break;
    case GL_DEBUG_SOURCE_THIRD_PARTY:
        error << "Source: Third Party";
        break;
    case GL_DEBUG_SOURCE_APPLICATION:
        error << "Source: Application";
        break;
    case GL_DEBUG_SOURCE_OTHER:
        error << "Source: Other";
        break;
    }
    error << std::endl;

    switch (type)
    {
    case GL_DEBUG_TYPE_ERROR:
        error << "Type: Error";
        break;
    case GL_DEBUG_TYPE_DEPRECATED_BEHAVIOR:
        error << "Type: Deprecated Behaviour";
        break;
    case GL_DEBUG_TYPE_UNDEFINED_BEHAVIOR:
        error << "Type: Undefined Behaviour";
        break;
    case GL_DEBUG_TYPE_PORTABILITY:
        error << "Type: Portability";
        break;
    case GL_DEBUG_TYPE_PERFORMANCE:
        error << "Type: Performance";
        break;
    case GL_DEBUG_TYPE_MARKER:
        error << "Type: Marker";
        break;
    case GL_DEBUG_TYPE_PUSH_GROUP:
        error << "Type: Push Group";
        break;
    case GL_DEBUG_TYPE_POP_GROUP:
        error << "Type: Pop Group";
        break;
    case GL_DEBUG_TYPE_OTHER:
        error << "Type: Other";
        break;
    }
    error << std::endl;

    switch (severity)
    {
    case GL_DEBUG_SEVERITY_HIGH:
        error << "Severity: high";
        break;
    case GL_DEBUG_SEVERITY_MEDIUM:
        error << "Severity: medium";
        break;
    case GL_DEBUG_SEVERITY_LOW:
        error << "Severity: low";
        break;
    case GL_DEBUG_SEVERITY_NOTIFICATION:
        error << "Severity: notification";
        break;
    }
    error << std::endl;
    error << std::endl;

    throw std::runtime_error("Error render OpenGL: n" + error.str());
}

All error handling was skipped. The application works and renders the image. Questions:

1) Am I creating the context in the new style correctly?

2) if I start the bandicam and msi afterburner application, with my application blocked. Error:

Debug message (1282): Error has been generated. GL error GL_INVALID_OPERATION in PushAttrib: (ID: 3950967337) Generic error
Source: API
Type: Error
Severity: high

3) If I try to enable wireframe mode, with my app locked

glPolygonMode(GL_FRONT, GL_LINE);
glPolygonMode(GL_BACK, GL_LINE);

Error:

Debug message (1280): Error has been generated. GL error GL_INVALID_ENUM in PolygonMode: (ID: 213353305) Generic error
Source: API
Type: Error
Severity: high

Why?

Thank you

bitcoin core – Creating mining competition in regtest

As we know, Bitcoin core-Regtest is used to configure our own blockchain from Genesis Block. I have created two nodes on my local host that are running on different ports (I am using Windows 8.1). They are connected to each other. Now I want to increase the difficulty level and create mining competition between two nodes.

I can use manually generate Number_of_blocks to mine that many Number_of_blocks on any node and also includes my recent transactions that are not yet included in the blockchain during mining.

But how can I have a deal that increases difficulty and starts mining on both nodes, and whoever comes first will transmit the block and win the race?

Any reference or step by step explanation would be highly appreciated.

magento2 – Magento 2 – Replace core template in own module

I want to cancel the template Magento_Client / templates / form / register.phtml in my own module

At the moment, the cancellation is in my topic:

app / design / frontend / company / base / Magento_Customer / templates / form / register.phtml

but I need it in my module:

application / code / company / client / ???

it's possible?


I am developing a module that is adding a new field at customer registration form.

I need the override in my module, otherwise users would have to add my module and also modify its theme.

blockchain – Bitcoin stuck in the bitcoin core

Aware of the fact that Bitcoin Core has to sync 800gb of data before displaying my coins, I transferred some money into a wallet created with the app. Now my money is stuck. The files are too many for my system.
I tried to retrieve my wallet through a public / private key, but it doesn't work on blockchain (it says my wallet is empty) or electrum. Also, the transaction with which I received my money cannot be found with insight.bitpay, but I can find it on Blockchain.
I can't understand I have my public and private wallet key, is it possible that I lose my currency?

Bitcoin Core wallet doesn't load and requires re-indexing after I've already done so

My Bitcoin Core is in sync. But I can't open a wallet, it says it might need a re-index. Although I already did. Also, I can't do dumpprivkey because it says no wallet loads.
How can I get it to work or at least get my private key to use another wallet …?