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

feat(cli): add experimental db export/import commands #413

Merged
merged 1 commit into from
May 18, 2022

Conversation

jansegre
Copy link
Member

This PR depends on #410, it's basically two commands (prefixed with x- to indicate they are experimental): x-import and x-export, that will export raw blocks+transactions with no metadata with a trivial serialization. The format is intended to be simple enough so it can be stable, it's useful for recreating a database without having to sync to the network, and also useful for running experiments related to the loading of transactions.

@jansegre jansegre self-assigned this May 13, 2022
@codecov
Copy link

codecov bot commented May 13, 2022

Codecov Report

Merging #413 (0938453) into dev (d0db4c1) will decrease coverage by 0.24%.
The diff coverage is 10.34%.

❗ Current head 0938453 differs from pull request most recent head decae0a. Consider uploading reports for the commit decae0a to get more accurate results

@@            Coverage Diff             @@
##              dev     #413      +/-   ##
==========================================
- Coverage   82.87%   82.62%   -0.25%     
==========================================
  Files         171      171              
  Lines       15613    15671      +58     
  Branches     2470     2476       +6     
==========================================
+ Hits        12939    12948       +9     
- Misses       2227     2277      +50     
+ Partials      447      446       -1     
Impacted Files Coverage Δ
hathor/util.py 63.67% <10.34%> (-17.58%) ⬇️
hathor/indexes/manager.py 92.85% <0.00%> (-0.90%) ⬇️
hathor/p2p/node_sync.py 84.02% <0.00%> (+0.98%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update d0db4c1...decae0a. Read the comment docs.

Copy link
Member

@msbrogli msbrogli left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I started reviewing it but I noticed that it has changes from other PRs. I'll wait for a rebase to finish the review.

hathor/cli/db_export.py Outdated Show resolved Hide resolved
hathor/cli/db_export.py Outdated Show resolved Hide resolved
hathor/cli/db_export.py Outdated Show resolved Hide resolved
hathor/cli/db_export.py Outdated Show resolved Hide resolved
hathor/cli/db_export.py Outdated Show resolved Hide resolved
hathor/cli/db_export.py Show resolved Hide resolved
@jansegre jansegre force-pushed the feat/db-export-import branch from b4b5810 to 5772360 Compare May 16, 2022 16:50
@jansegre jansegre requested a review from pedroferreira1 May 17, 2022 21:18
@jansegre jansegre force-pushed the feat/db-export-import branch from 5772360 to a60b86e Compare May 17, 2022 21:18
@jansegre jansegre marked this pull request as ready for review May 17, 2022 21:18
@jansegre jansegre force-pushed the feat/db-export-import branch from a60b86e to 0938453 Compare May 18, 2022 00:40
@jansegre jansegre force-pushed the feat/db-export-import branch from 0938453 to decae0a Compare May 18, 2022 16:56
@jansegre
Copy link
Member Author

Last test runs were OK, this run just has the commits signed.

@jansegre jansegre merged commit f1f82e4 into dev May 18, 2022
@jansegre jansegre deleted the feat/db-export-import branch May 18, 2022 16:59
@jansegre jansegre mentioned this pull request Jun 6, 2022
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

Successfully merging this pull request may close these issues.

3 participants