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

[BUG]Exception from 'wallet' Unclosed client session & Unclosed connector #7210

Closed
changpeng75 opened this issue Jul 8, 2021 · 42 comments
Closed
Labels
bug Something isn't working stale-issue flagged as stale and will be closed in 7 days if not updated

Comments

@changpeng75
Copy link

Describe the bug
when execute "chia plotnft show" system return follow

(venv) [root@localhost chia-blockchain]# chia plotnft show
Wallet height: 542246
Sync status: Synced
Wallet id 2:
Current state: FARMING_TO_POOL
Current state from block height: 524314
Launcher ID: xxx
Target address (not for plotting): xxx
Owner public key: xxx
P2 singleton address (pool contract address for plotting): xxx
Current pool URL: https://pool.xchpool.org
Relative lock height: 100 blocks
Exception from 'wallet' <bytes32: xxx>
Unclosed client session
client_session: <aiohttp.client.ClientSession object at 0x7f068788e280>
Unclosed connector
connections: ['[(<aiohttp.client_proto.ResponseHandler object at 0x7f0686dedbe0>, 11769.101785711)]']
connector: <aiohttp.connector.TCPConnector object at 0x7f068788e640>

node & wallet synced and no error in log file.

To Reproduce

Steps to reproduce the behavior:

  1. Go to '...'
  2. Click on '....'
  3. Scroll down to '....'
  4. See error

Expected behavior

Screenshots

Desktop

  • OS: Linux
  • OS Version/Flavor: CentOS7.9
  • CPU: Xeon E5450

Additional context

@changpeng75 changpeng75 added the bug Something isn't working label Jul 8, 2021
@changpeng75
Copy link
Author

what is Unclosed client session & Unclosed connector?

@changpeng75 changpeng75 changed the title [BUG] [BUG]Exception from 'wallet' Unclosed client session & Unclosed connector Jul 8, 2021
@hebe123
Copy link

hebe123 commented Jul 8, 2021

Same problem here. It occurred after I've deleted the wallet files (explained in here in step 1) and copied them over from a newer version. Did you do the same?

@marklysze
Copy link

marklysze commented Jul 8, 2021

I've got the same issue with mine. As mentioned by @hebe123, I deleted the wallet files in my docker setup and copied them over from a newer version.

Node is fully synced, wallet is synced. "chia wallet show" shows the two wallets (1: STANDARD_WALLET, 2: POOLING_WALLET)

@dailymoose
Copy link

I'm having the same error. I also created the NFT on another computer (Windows) and copied the DB files over to another computer (Ubuntu).

@changpeng75
Copy link
Author

Use same wallet file on windows 10 can return correct result. Show Current difficulty,Points balance and Payout instructions to me.

@marklysze
Copy link

Use same wallet file on windows 10 can return correct result. Show Current difficulty,Points balance and Payout instructions to me.

Are you saying that if you run "chia plotnft show" on Windows it works? Or are you saying you copied the Windows 10 file to Linux and it worked?

@kahn2k
Copy link

kahn2k commented Jul 9, 2021

Screenshot 2021-07-09 at 10 02 59 AM

Having the same issue, and my plots are not reporting partial proofs with the pool. I'm not sure if having 2 pool wallets is the reason for the error

@changpeng75
Copy link
Author

Use same wallet file on windows 10 can return correct result. Show Current difficulty,Points balance and Payout instructions to me.

Are you saying that if you run "chia plotnft show" on Windows it works? Or are you saying you copied the Windows 10 file to Linux and it worked?

Use same wallet file on windows can work correct.
Actually,I copy the wallet file from windows to centos 7,so I get xception from 'wallet' .

@changpeng75
Copy link
Author

So I delete the wallet file and syncing it from network.

@szarkivach
Copy link

Describe the bug
when execute "chia plotnft show" system return follow

(venv) [root@localhost chia-blockchain]# chia plotnft show
Wallet height: 542246
Sync status: Synced
Wallet id 2:
Current state: FARMING_TO_POOL
Current state from block height: 524314
Launcher ID: xxx
Target address (not for plotting): xxx
Owner public key: xxx
P2 singleton address (pool contract address for plotting): xxx
Current pool URL: https://pool.xchpool.org
Relative lock height: 100 blocks
Exception from 'wallet' <bytes32: xxx>
Unclosed client session
client_session: <aiohttp.client.ClientSession object at 0x7f068788e280>
Unclosed connector
connections: ['[(<aiohttp.client_proto.ResponseHandler object at 0x7f0686dedbe0>, 11769.101785711)]']
connector: <aiohttp.connector.TCPConnector object at 0x7f068788e640>

node & wallet synced and no error in log file.

To Reproduce

Steps to reproduce the behavior:

  1. Go to '...'
  2. Click on '....'
  3. Scroll down to '....'
  4. See error

Expected behavior

Screenshots

Desktop

  • OS: Linux
  • OS Version/Flavor: CentOS7.9
  • CPU: Xeon E5450

Additional context
Had same problem. I just totally deleted the wallet files and resynched from scratch and it works

@changpeng75
Copy link
Author

Describe the bug
when execute "chia plotnft show" system return follow
(venv) [root@localhost chia-blockchain]# chia plotnft show
Wallet height: 542246
Sync status: Synced
Wallet id 2:
Current state: FARMING_TO_POOL
Current state from block height: 524314
Launcher ID: xxx
Target address (not for plotting): xxx
Owner public key: xxx
P2 singleton address (pool contract address for plotting): xxx
Current pool URL: https://pool.xchpool.org
Relative lock height: 100 blocks
Exception from 'wallet' <bytes32: xxx>
Unclosed client session
client_session: <aiohttp.client.ClientSession object at 0x7f068788e280>
Unclosed connector
connections: ['[(<aiohttp.client_proto.ResponseHandler object at 0x7f0686dedbe0>, 11769.101785711)]']
connector: <aiohttp.connector.TCPConnector object at 0x7f068788e640>
node & wallet synced and no error in log file.
To Reproduce
Steps to reproduce the behavior:

  1. Go to '...'
  2. Click on '....'
  3. Scroll down to '....'
  4. See error

Expected behavior
Screenshots
Desktop

  • OS: Linux
  • OS Version/Flavor: CentOS7.9
  • CPU: Xeon E5450

Additional context
Had same problem. I just totally deleted the wallet files and resynched from scratch and it works

if so,this is a big bug.It's means datafile haven't compatibility.

@marklysze
Copy link

@changpeng75, it is strange that the wallet db can't be copied. I tried it on two different installs and I had the same error. Only option it seems is to resync wallet from scratch.

@dailymoose
Copy link

dailymoose commented Jul 9, 2021

@changpeng75, it is strange that the wallet db can't be copied. I tried it on two different installs and I had the same error. Only option it seems is to resync wallet from scratch.

Which is going to take 99999 hours on a Raspberry Pi... I'm currently resyncing from scratch on another Ubuntu machine and will try copying to the RPI once complete. That will tell us whether or not it's a platforms problem or just copying in general.

Edit: Oh, and I did delete my wallet DB files and it refused to sync the wallet from the blockchain database. So it's not just a wallet DB problem, blockchain too...

@marklysze
Copy link

marklysze commented Jul 9, 2021

@dailymoose I copied both the blockchain and wallet dbs from fully sync'd Windows system to Ubuntu and the blockchain is syncing and continuing the be fully synced. I had to delete the wallet db files to get that starting to sync. So I think the blockchain can work.

(And yes, I tried to set it up on a Synology NAS in a Docker container and syncing a wallet was impossible, need a solid machine for that. I ended up using the Synology NAS Docker ubuntu as a harvester only node.)

@changpeng75
Copy link
Author

@marklysze I syncing on 32xxxx,need more time to completed.Maybe it can work, who knows?

@marklysze
Copy link

@changpeng75, I hope it works like others have said. I just started my wallet resync and it's at 30xxx, so you'll probably know before I do. Fingers crossed.

@dailymoose
Copy link

@dailymoose I copied both the blockchain and wallet dbs from fully sync'd Windows system to Ubuntu and the blockchain is syncing and continuing the be fully synced. I had to delete the wallet db files to get that starting to sync. So I think the blockchain can work.

(And yes, I tried to set it up on a Synology NAS in a Docker container and syncing a wallet was impossible, need a solid machine for that. I ended up using the Synology NAS Docker ubuntu as a harvester only node.)

When you deleted the wallet db, did the wallet start syncing? My copied blockchain synced fully but the wallet kept saying "Requesting block 0-32" then would time out, retry, timeout, etc. I left it run all night like that and didn't get anywhere. If your wallet worked after deleting, only thing I can think of is maybe my blockchain was corrupt somewhere/somehow. Who knows...

@marklysze
Copy link

@dailymoose I copied both the blockchain and wallet dbs from fully sync'd Windows system to Ubuntu and the blockchain is syncing and continuing the be fully synced. I had to delete the wallet db files to get that starting to sync. So I think the blockchain can work.
(And yes, I tried to set it up on a Synology NAS in a Docker container and syncing a wallet was impossible, need a solid machine for that. I ended up using the Synology NAS Docker ubuntu as a harvester only node.)

When you deleted the wallet db, did the wallet start syncing? My copied blockchain synced fully but the wallet kept saying "Requesting block 0-32" then would time out, retry, timeout, etc. I left it run all night like that and didn't get anywhere. If your wallet worked after deleting, only thing I can think of is maybe my blockchain was corrupt somewhere/somehow. Who knows...

Yes, it started syncing again, it started from zero and slowly incremented. I stopped all Chia services before deleting the wallet files then started the node and farmer, which started the wallet. It isn't fully synced yet so hopefully it works

@kahn2k
Copy link

kahn2k commented Jul 10, 2021

OK, I've managed to fix the issue by issuing another plotnft to a new pool with a synced wallet. There is no need to delete and resync your old wallet if it has already been synced.

I believe you can do the same by issuing plotnft to self and then back to the old pool should also fix it though I did not try that.

@changpeng75
Copy link
Author

OK, I've managed to fix the issue by issuing another plotnft to a new pool with a synced wallet. There is no need to delete and resync your old wallet if it has already been synced.

I believe you can do the same by issuing plotnft to self and then back to the old pool should also fix it though I did not try that.

Create a new plotnft on the device with incorrect wallet?

@kahn2k
Copy link

kahn2k commented Jul 10, 2021

OK, I've managed to fix the issue by issuing another plotnft to a new pool with a synced wallet. There is no need to delete and resync your old wallet if it has already been synced.
I believe you can do the same by issuing plotnft to self and then back to the old pool should also fix it though I did not try that.

Create a new plotnft on the device with incorrect wallet?

Yes. Wait a few minutes and it should fix the wallet error, and you should start farming to pool properly again

@changpeng75
Copy link
Author

OK, I've managed to fix the issue by issuing another plotnft to a new pool with a synced wallet. There is no need to delete and resync your old wallet if it has already been synced.
I believe you can do the same by issuing plotnft to self and then back to the old pool should also fix it though I did not try that.

Create a new plotnft on the device with incorrect wallet?

Yes. Wait a few minutes and it should fix the wallet error, and you should start farming to pool properly again

Thanks!I try it.

@changpeng75
Copy link
Author

changpeng75 commented Jul 10, 2021

Same incorrect.
If I use -i parameter specify new plotnft wallet I can get correct result. But if I specify old plotnft wallet I get same incorrect "Exception from 'wallet'".
And I use chia plotnft join -i 2 -u https://pool.xchpool.org rejoin the pool,
I get "Error performing operation on Plot NFT -f xxxxx wallet id: 2: 'NoneType' object is not iterable".

@changpeng75
Copy link
Author

I resync wallet from scratch and I get correct result.

@kahn2k
Copy link

kahn2k commented Jul 10, 2021

What is the -i 2 argument in the command? When I use chia plotnft create -s pool -u https://bar.examplepool.org , it worked.

@changpeng75
Copy link
Author

What is the -i 2 argument in the command? When I use chia plotnft create -s pool -u https://bar.examplepool.org , it worked.

Wallet ID.

@kahn2k
Copy link

kahn2k commented Jul 10, 2021

Maybe that's the reason. Have to plotnft to create a new wallet id. But once it clears the error, you can use the old wallet id.

@dailymoose
Copy link

dailymoose commented Jul 10, 2021

Ok, I finally got mine working... I synced everything from scratch on an Ubuntu server with SSD. That took over 1.5 days... The "chia plotnft show" command was working correctly there after the sync. Copied the wallet/db folders over the the RPI4. The RPI4 started fine and was back in sync with the wallet and blockchain (one issue resolved). However, I was still hitting the same bug as originally reported in this ticket. I then switched from pool A to pool B, waited a half hour, then switched back from pool B to pool A as noted above. The "chia plotnft show" command is now working correctly and am farming to the pool correctly.

No clue what's up but think I ruled out a cross-platform issue... Seems like there's a cache somewhere that needs updated/cleared but not sure where it could be as it's not in the .chia folder.

@marklysze
Copy link

marklysze commented Jul 10, 2021

@dailymoose, thank you for the update. Perhaps the plot nft is stored somewhere too?

Update: I'm fully synced with db and wallet on a fresh ubuntu and everything looks okay, the Plot NFT was created automatically and put into the config.yaml file.

I'm wondering if the config.yaml file needs to be updated manually if we copy the db files from a computer where the plot nft was already created? Two parts of the config.yaml seem to be updated:
"pool_public_keys: !!set" under the "farmer" node now has two keys
"pool_list:" under "the "pool" node now has the pool nft listed

I'm not running a second full node to check, but might be useful for someone else to try if they are having the same problem.

@Zerrox0
Copy link

Zerrox0 commented Jul 12, 2021

I had the same issue and I can confirm that it happens when the "pool_list" section in your config.yaml is missing your current pool settings.

Just copied the whole "pool_list:" section from my old machine to the new one and it works fine now.

@marklysze
Copy link

I had the same issue and I can confirm that it happens when the "pool_list" section in your config.yaml is missing your current pool settings.

Just copied the whole "pool_list:" section from my old machine to the new one and it works fine now.

Thanks for confirming for us, that will save countless hours for others trying the same thing

@Simoneu01
Copy link

I had the same issue and I can confirm that it happens when the "pool_list" section in your config.yaml is missing your current pool settings.

Just copied the whole "pool_list:" section from my old machine to the new one and it works fine now.

Thank you!

@kahn2k
Copy link

kahn2k commented Jul 13, 2021

I had the same issue and I can confirm that it happens when the "pool_list" section in your config.yaml is missing your current pool settings.

Just copied the whole "pool_list:" section from my old machine to the new one and it works fine now.

Works for me too. Thanks!

@coquinone
Copy link

I had the same issue and I can confirm that it happens when the "pool_list" section in your config.yaml is missing your current pool settings.

Just copied the whole "pool_list:" section from my old machine to the new one and it works fine now.

Confirm, I had the same issue and this resolved it.

@theRTC204
Copy link

I had the same issue and I can confirm that it happens when the "pool_list" section in your config.yaml is missing your current pool settings.

Just copied the whole "pool_list:" section from my old machine to the new one and it works fine now.

Thank you! This solved the error for me as well!

@mqm165
Copy link

mqm165 commented Jul 25, 2021

I had the same issue and I can confirm that it happens when the "pool_list" section in your config.yaml is missing your current pool settings.

Just copied the whole "pool_list:" section from my old machine to the new one and it works fine now.

it did work in terms of the wallet being synced normally,
but it was weird to note that the worker did not sync in the pool website.
the worker was offline, despite being normally synced in the chia plotnft show

note that I'm using flex pool, it shows individual workers

@github-actions
Copy link
Contributor

github-actions bot commented Aug 9, 2021

This issue has been flagged as stale as there has been no activity on it in 14 days. If this issue is still affecting you and in need of review, please update it to keep it open.

@github-actions github-actions bot added the stale-issue flagged as stale and will be closed in 7 days if not updated label Aug 9, 2021
@github-actions
Copy link
Contributor

This issue was automatically closed because it has been flagged as stale and subsequently passed 7 days with no further activity.

@adamvp
Copy link

adamvp commented Sep 1, 2021

Have same error

@mattselkey
Copy link

I had the same issue and I can confirm that it happens when the "pool_list" section in your config.yaml is missing your current pool settings.

Just copied the whole "pool_list:" section from my old machine to the new one and it works fine now.

this saved me full resync, kudos to you!! this should be in the wiki

@metalfacesec
Copy link

I had the same issue and I can confirm that it happens when the "pool_list" section in your config.yaml is missing your current pool settings.

Just copied the whole "pool_list:" section from my old machine to the new one and it works fine now.

This worked for me, thank you so much!

@greg-fischer
Copy link

Nice easy fix!!! Just ran into this because I'm installing a new server to run a node/farmer and copied the sqlite db's and while everything looks fine, the plotnft error showed. Really nice not having to run a full sync again! Would take me days!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working stale-issue flagged as stale and will be closed in 7 days if not updated
Projects
None yet
Development

No branches or pull requests