mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-11-10 14:08:40 +01:00
Merge bitcoin/bitcoin#28793: contrib: Add asmap-tool
6abe772a17contrib: Add asmap-tool (Fabian Jahr) Pull request description: This adds `asmap.py` and `asmap-tool.py` from sipa's `nextgen` branch: https://github.com/sipa/asmap/tree/nextgen The motivation is that we should maintain the tooling for de- and encoding asmap files within the bitcoin core repository because it is not possible to use an asmap file that is not encoded. We already had an earlier version of `asmap.py` within the seeds contrib tools. The newer version only had a small amount of changes and is still compatible, so the old version is removed from contrib/seeds and the new version is made available to `makeseeds.py`. ACKs for top commit: virtu: ACK [6abe772](6abe772a17) 0xB10C: ACK6abe772a17achow101: ACK6abe772a17brunoerg: ACK6abe772a17Tree-SHA512: cc2a82ffa4eb46fa0ce4ca769dd82f8d0d2f37fc3652aa748eeb060e1142f9da4035008fe89433e2fd524a4dc153b7b9c085748944b49137b37009b0c0be8afb
This commit is contained in:
@@ -9,11 +9,14 @@
|
||||
import argparse
|
||||
import collections
|
||||
import ipaddress
|
||||
from pathlib import Path
|
||||
import re
|
||||
import sys
|
||||
from typing import Union
|
||||
|
||||
from asmap import ASMap, net_to_prefix
|
||||
asmap_dir = Path(__file__).parent.parent / "asmap"
|
||||
sys.path.append(str(asmap_dir))
|
||||
from asmap import ASMap, net_to_prefix # noqa: E402
|
||||
|
||||
NSEEDS=512
|
||||
|
||||
|
||||
Reference in New Issue
Block a user