How to register .bit domain in electrum?

https://www.namecoin.org/dot-bit/
DogHunter
Posts: 6
Joined: Tue Nov 05, 2019 4:37 pm
os: linux

How to register .bit domain in electrum?

Post by DogHunter »

Hi,
I am new to NMC.

So I bought some NMC and was planning to issue several domains. I have chosen electrum-nmc because it does not require me to download whole blockchain.
I just need to register domain and update it to static ip address without any dns servers from godaddy or anything.

However I have no idea what I should do and I haven't found howto specifically for electrum-nmc. There is a howto to namecoin-qt with lots of information and command line usage. I suppose it gonna be much easier to do in electrum-nmc.

Right now I have no idea what I should put to "Data" and "Transfer to:" when I click "Register name". Is there anywhere howto available for electrum-nmc how to register domains or maybe you can just tell me what I should put there? (or tell me what exact lines I need from namecoin-qt documentation and what I should skip there)

Thanks

biolizard89
Posts: 2001
Joined: Tue Jun 05, 2012 6:25 am
os: linux

Re: How to register .bit domain in electrum?

Post by biolizard89 »

DogHunter wrote:
Tue Nov 05, 2019 4:45 pm
Hi,
I am new to NMC.

So I bought some NMC and was planning to issue several domains. I have chosen electrum-nmc because it does not require me to download whole blockchain.
I just need to register domain and update it to static ip address without any dns servers from godaddy or anything.

However I have no idea what I should do and I haven't found howto specifically for electrum-nmc. There is a howto to namecoin-qt with lots of information and command line usage. I suppose it gonna be much easier to do in electrum-nmc.

Right now I have no idea what I should put to "Data" and "Transfer to:" when I click "Register name". Is there anywhere howto available for electrum-nmc how to register domains or maybe you can just tell me what I should put there? (or tell me what exact lines I need from namecoin-qt documentation and what I should skip there)

Thanks
Hi! Thanks for reporting this UX issue. You're absolutely right that we should make this more understandable.

The "Data" field is what controls what IP address the domain points to (among other things). The full specification is in the following documents:

https://github.com/namecoin/proposals/b ... fa-0001.md
https://github.com/namecoin/proposals/b ... fa-0002.md
https://github.com/namecoin/proposals/b ... fa-0003.md

However, the short answer for your use case (pointing to a single IP address) is that your Data field should look like this:

Code: Select all

{"ip":"123.45.67.89"}
Substitute whatever IP address you like. If it's an IPv6 address, use "ip6" instead of "ip". If you're not sure what to enter there (e.g. if you don't know the IP address you want yet), you can leave the "Data" field blank, and you'll be able to change it later (though changing it later will cost an extra transaction fee).

In the future, we will have a nice user-friendly wizard that automates most of this. Unfortunately, no one is currently assigned to this task, though we will hopefully have someone assigned to it soon. The relevant GitHub issue is https://github.com/namecoin/electrum-nmc/issues/50 .

The "Transfer to" field is for a Namecoin address that you want to be the owner of the newly registered domain. It's used for cases such as registering a name for a friend, or registering a name that you want to be moved directly to cold storage. If you leave it blank, Electrum-NMC will automatically use an address in your Electrum-NMC wallet, which is almost definitely what you want. We definitely should make this more clear in the UI; I've just filed a GitHub issue for that at https://github.com/namecoin/electrum-nmc/issues/186 .

Let us know if you have any more questions. Cheers!
Jeremy Rand, Lead Namecoin Application Engineer
NameID: id/jeremy
DyName: Dynamic DNS update client for .bit domains.

Donations: BTC 1EcUWRa9H6ZuWPkF3BDj6k4k1vCgv41ab8 ; NMC NFqbaS7ReiQ9MBmsowwcDSmp4iDznjmEh5

DogHunter
Posts: 6
Joined: Tue Nov 05, 2019 4:37 pm
os: linux

Re: How to register .bit domain in electrum?

Post by DogHunter »

Thanks for fast reply,
I just put JSON string with my ip address like you said and tried to register domain. After that electrum produced message box like "Insufficient funds". Now I see transaction with description "Pre-Registration" and amount "-0.0102495".txid is b8787c7026693aec8e66615a40f1163e538bef97d994dae579c848b2cc18f28e

So why insufficient funds if I have 8 NMC on ballance and what just happened? I cant control domains on Manage Names tab, Name, Value and Expires fields are empty and Status is "Registration Pending".

biolizard89
Posts: 2001
Joined: Tue Jun 05, 2012 6:25 am
os: linux

Re: How to register .bit domain in electrum?

Post by biolizard89 »

DogHunter wrote:
Fri Nov 08, 2019 3:14 pm
Thanks for fast reply,
I just put JSON string with my ip address like you said and tried to register domain. After that electrum produced message box like "Insufficient funds". Now I see transaction with description "Pre-Registration" and amount "-0.0102495".txid is b8787c7026693aec8e66615a40f1163e538bef97d994dae579c848b2cc18f28e

So why insufficient funds if I have 8 NMC on ballance and what just happened? I cant control domains on Manage Names tab, Name, Value and Expires fields are empty and Status is "Registration Pending".
Hmm, that sounds like a nice bug you've found. This is particularly interesting because Electrum-NMC's Travis builds started failing with an "Insufficient funds" error after I merged upstream's Lightning code. See https://github.com/namecoin/electrum-nmc/issues/178 . Daniel and I were initially operating under the assumption that either this was directly related to a Lightning refactor breaking something in Namecoin, or it was caused by a fee rate suggestion being broken. But your info suggests that there may be something wrong with the coin selection algorithm instead, where it incorrectly thinks that the wallet doesn't have enough funds even when it does, and that the fact that this appeared as a Travis fail following the Lightning merge might simply be an artifact of the Lightning merge adding more tests, which might have increased test coverage of the coin selection algorithm, thus exposing this bug.

I'll try to reproduce this on my end early next week and see whether your info helps me track down the bug.

Thanks again for the bug report; I'll report back when I know more.
Jeremy Rand, Lead Namecoin Application Engineer
NameID: id/jeremy
DyName: Dynamic DNS update client for .bit domains.

Donations: BTC 1EcUWRa9H6ZuWPkF3BDj6k4k1vCgv41ab8 ; NMC NFqbaS7ReiQ9MBmsowwcDSmp4iDznjmEh5

DogHunter
Posts: 6
Joined: Tue Nov 05, 2019 4:37 pm
os: linux

Re: How to register .bit domain in electrum?

Post by DogHunter »

But was domain issued at all? I sent you txid I wonder if data line got attached to tx because balance decreased a bit. Or coins just got destroyed for nothing?

Also if you wont be able to reproduce the bug please consider building appimages for electrum-nmc. Python is known as "very portable language" and I usually experienced a lot of issues when was using different electrum versions for different coins. However this problem completely vanished when devs started building appimages for electrum-btc and electrum-bch for example.

And there was not anything written to console when I experienced this bug, so I cant send you any more information.
Distro: Whonix-XFCE 15, Debian 10
uname -a: Linux host 4.19.0-5-amd64 #1 SMP Debian 4.19.37-5 (2019-06-19) x86_64 GNU/Linux

DogHunter
Posts: 6
Joined: Tue Nov 05, 2019 4:37 pm
os: linux

Re: How to register .bit domain in electrum?

Post by DogHunter »

Was not able to send bug report either. This happens when I press "Configure Name..." to edit that bugged blank domain entry.

Image
Image

biolizard89
Posts: 2001
Joined: Tue Jun 05, 2012 6:25 am
os: linux

Re: How to register .bit domain in electrum?

Post by biolizard89 »

Okay, so I spent several hours today diagnosing the issue. The issue you ran into is actually a combination of multiple bugs:
  • Upstream Electrum refactored their coin chooser, and this refactor broke the edge case of requesting exactly one mandatory input and exactly zero optional inputs. Unfortunately, this edge case is exactly what Electrum-NMC does when it's creating a name_firstupdate transaction (the mandatory input is the name_new, which has enough extra funds in it to avoid the need for an optional currency input). The result of this breakage is an incorrect "NotEnoughFunds" exception when creating the name_firstupdate.
  • Electrum-NMC was broadcasting the name_new transaction before it had confirmed that the name_firstupdate was created correctly. The result was that if the name_firstupdate failed, the name_new would still be broadcast, resulting in a name_new output that can't be spent, which means the registration fee and transaction fee for the name_new are lost.
  • Electrum-NMC doesn't handle name_new transactions properly in the Manage Names tab if there's no name_firstupdate present in the wallet. Normally this would only break the edge case where you receive a name_new as a transfer from another wallet, but because of the above bugs, you were getting errors while trying to right-click the name_new.
The first two will be fixed in Electrum-NMC 3.3.8, which should be tagged in the next couple days. The 3rd bug is fixed in master but I'm hesitant to backport it to 3.3.8 since it's a somewhat more invasive change, and generally isn't a big deal by itself.

Unfortunately, your 0.0102495 NMC is probably lost. If you want, feel free to PM me a NMC address and I'll refund you for that.

Thanks again for the bug report.
Jeremy Rand, Lead Namecoin Application Engineer
NameID: id/jeremy
DyName: Dynamic DNS update client for .bit domains.

Donations: BTC 1EcUWRa9H6ZuWPkF3BDj6k4k1vCgv41ab8 ; NMC NFqbaS7ReiQ9MBmsowwcDSmp4iDznjmEh5

DogHunter
Posts: 6
Joined: Tue Nov 05, 2019 4:37 pm
os: linux

Re: How to register .bit domain in electrum?

Post by DogHunter »

Lol no need to refund that pathetic amount, just make it work please. So you mean that transaction was destroyed just like it gets destroyed when issuing domains, but no domains were issued?

Was domain name lost or I can try reissue it with next electrum-nmc tag?

Thanks

biolizard89
Posts: 2001
Joined: Tue Jun 05, 2012 6:25 am
os: linux

Re: How to register .bit domain in electrum?

Post by biolizard89 »

DogHunter wrote:
Mon Nov 11, 2019 11:04 am
Lol no need to refund that pathetic amount, just make it work please. So you mean that transaction was destroyed just like it gets destroyed when issuing domains, but no domains were issued?
Yes, that's basically correct.
DogHunter wrote:
Mon Nov 11, 2019 11:04 am
Was domain name lost or I can try reissue it with next electrum-nmc tag?
You should be able to register the name in Electrum-NMC 3.3.8, which was released a few minutes ago. Let us know how it goes.
Jeremy Rand, Lead Namecoin Application Engineer
NameID: id/jeremy
DyName: Dynamic DNS update client for .bit domains.

Donations: BTC 1EcUWRa9H6ZuWPkF3BDj6k4k1vCgv41ab8 ; NMC NFqbaS7ReiQ9MBmsowwcDSmp4iDznjmEh5

DogHunter
Posts: 6
Joined: Tue Nov 05, 2019 4:37 pm
os: linux

Re: How to register .bit domain in electrum?

Post by DogHunter »

Hi,

The forum was down was not able to reply. So with new version of electrum I registered domain just fine and it is marked as registered, and JSON IP string seems correct.

However my domain does not resolve thru bdns api or opennic DNS servers, while my emercoin domain resolves just fine both ways.
I see Pre-registration and Registration with a green tick, so there are confirmations, and enough time have passed for new domain to propagate.

Also old incorrect domain registration is still in electum on "Manage Domains" tab and it crashes if I trying to edit that. Looks like some cosmetic UI problem.

Thanks

Post Reply