From a647d26337a2773ffa63ec808785a0046e912055 Mon Sep 17 00:00:00 2001 From: Daniel Seiller Date: Mon, 15 Jul 2019 00:43:57 +0200 Subject: [PATCH] Initial commit --- .gitignore | 10 + MANIFEST.in | 2 + README.md | 43 + build_gui.py | 13 + clean.bat | 5 + ed_lrr_gui/__init__.py | 2 + ed_lrr_gui/__main__.py | 235 ++++ ed_lrr_gui/config.py | 45 + ed_lrr_gui/gui/__init__.py | 0 ed_lrr_gui/gui/ed_lrr.py | 350 ++++++ ed_lrr_gui/gui/ed_lrr.ui | 584 ++++++++++ pyproject.toml | 2 + rust/.cargo/config | 2 + rust/Cargo.lock | 2091 ++++++++++++++++++++++++++++++++++++ rust/Cargo.toml | 34 + rust/src/common.rs | 38 + rust/src/download.rs | 63 ++ rust/src/lib.rs | 66 ++ rust/src/preprocess.rs | 220 ++++ rust/src/route.rs | 879 +++++++++++++++ setup.py | 23 + 21 files changed, 4707 insertions(+) create mode 100644 .gitignore create mode 100644 MANIFEST.in create mode 100644 README.md create mode 100644 build_gui.py create mode 100644 clean.bat create mode 100644 ed_lrr_gui/__init__.py create mode 100644 ed_lrr_gui/__main__.py create mode 100644 ed_lrr_gui/config.py create mode 100644 ed_lrr_gui/gui/__init__.py create mode 100644 ed_lrr_gui/gui/ed_lrr.py create mode 100644 ed_lrr_gui/gui/ed_lrr.ui create mode 100644 pyproject.toml create mode 100644 rust/.cargo/config create mode 100644 rust/Cargo.lock create mode 100644 rust/Cargo.toml create mode 100644 rust/src/common.rs create mode 100644 rust/src/download.rs create mode 100644 rust/src/lib.rs create mode 100644 rust/src/preprocess.rs create mode 100644 rust/src/route.rs create mode 100644 setup.py diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..86707f4 --- /dev/null +++ b/.gitignore @@ -0,0 +1,10 @@ +/target +/dist +/build +**/*.rs.bk +*.tmp +*.idx +.vscode/** +build.bat +test.bat +__pycache__ \ No newline at end of file diff --git a/MANIFEST.in b/MANIFEST.in new file mode 100644 index 0000000..900cc3b --- /dev/null +++ b/MANIFEST.in @@ -0,0 +1,2 @@ +include rust/Cargo.toml +recursive-include rust/src * \ No newline at end of file diff --git a/README.md b/README.md new file mode 100644 index 0000000..299b692 --- /dev/null +++ b/README.md @@ -0,0 +1,43 @@ +# Testing + +```bash +conda create -n ed_lrr_gui_env python=3 +conda activate ed_lrr_gui_env +python build_gui.py +pip install -e . +rs_gui_test +``` + +# Building + +```bash +conda create -n ed_lrr_gui_env python=3 +conda activate ed_lrr_gui_env +python build_gui.py +python build_gui.py +python build_gui.py +pip install setuptools_rust +pip install . +python setup.py build +python setup.py bdist_wheel +python setup.py sdist +mkdir exe +cd exe +pyinstaller --noupx --name ed_lrr_gui ../ed_lrr_gui/__main__.py +pyinstaller --noupx --onefile --name ed_lrr_gui ../ed_lrr_gui/__main__.py +cd .. +``` + +# Clean + +```bash +rm -rfv _*.pyd *.pyc *.egg-info pip-wheel-metadata dist exe build __pycache__ +cd rust +cargo clean +cargo clean --release +cd .. +``` + +# TODO +- refactor ed_lrr to use callbacks +- integrate callbacks into the GUI \ No newline at end of file diff --git a/build_gui.py b/build_gui.py new file mode 100644 index 0000000..6327ad2 --- /dev/null +++ b/build_gui.py @@ -0,0 +1,13 @@ +import subprocess as SP +from glob import glob +import os + + +ui_path = os.path.dirname(os.path.abspath(__file__)) +for root, folders, files in os.walk(ui_path): + for file in files: + file = os.path.join(root, file) + outfile, ext = os.path.splitext(file) + if ext == ".ui": + outfile = outfile + ".py" + SP.check_call(["pyuic5", "--from-imports", "-o", outfile, file]) diff --git a/clean.bat b/clean.bat new file mode 100644 index 0000000..098a107 --- /dev/null +++ b/clean.bat @@ -0,0 +1,5 @@ +rm -rfv _*.pyd *.egg-info pip-wheel-metadata dist exe build __pycache__ +cd rust +cargo clean +cargo clean --release +cd .. \ No newline at end of file diff --git a/ed_lrr_gui/__init__.py b/ed_lrr_gui/__init__.py new file mode 100644 index 0000000..2d1a9d6 --- /dev/null +++ b/ed_lrr_gui/__init__.py @@ -0,0 +1,2 @@ +from _ed_lrr import * +from . import gui diff --git a/ed_lrr_gui/__main__.py b/ed_lrr_gui/__main__.py new file mode 100644 index 0000000..7f83a54 --- /dev/null +++ b/ed_lrr_gui/__main__.py @@ -0,0 +1,235 @@ +import sys +from PyQt5.QtCore import QThread, pyqtSignal, Qt +from PyQt5.QtWidgets import ( + QMainWindow, + QApplication, + QFileDialog, + QProgressDialog, + QTreeWidgetItem, +) +from PyQt5.QtGui import QPalette, QColor +import ed_lrr_gui +import ed_lrr_gui.config as cfg +from ed_lrr_gui.gui.ed_lrr import Ui_ED_LRR +import os +from datetime import datetime + +# print(ed_lrr_gui.test({"a": 1, "b": 2})) +# exit(1) + + +class Progressdialog(QProgressDialog): + def __init__(self, *args, **kwargs): + super().__init__(*args, **kwargs) + self.setWindowModality(Qt.WindowModal) + + +class App(QApplication): + def __init__(self): + super().__init__(sys.argv) + self.setStyle("Fusion") + self.set_pallete() + + def set_pallete(self): + colors = { + "Window": QColor(53, 53, 53), + "WindowText": Qt.white, + "Base": QColor(15, 15, 15), + "AlternateBase": QColor(53, 53, 53), + "ToolTipBase": Qt.white, + "ToolTipText": Qt.white, + "Text": Qt.white, + "Button": QColor(53, 53, 53), + "ButtonText": Qt.white, + "BrightText": Qt.red, + "Highlight": QColor(255, 128, 0), + "HighlightedText": Qt.black, + } + palette = QPalette() + for entry, color in colors.items(): + palette.setColor(getattr(QPalette, entry), color) + if color == Qt.darkGray: + palette.setColor( + QPalette.Disabled, getattr(QPalette, entry), QColor(53, 53, 53) + ) + else: + palette.setColor( + QPalette.Disabled, getattr(QPalette, entry), Qt.darkGray + ) + self.setPalette(palette) + + +class ED_LRR(Ui_ED_LRR): + pbar_thread = None + + def __init__(self): + super().__init__() + self.config = cfg.load() + + def get_open_file(self, filetypes, callback=None): + fileName, _ = QFileDialog.getOpenFileName( + self.main_window, + "Open file", + str(cfg.data_dir), + filetypes, + options=QFileDialog.DontUseNativeDialog, + ) + if callback: + return callback(fileName) + return fileName + + def get_save_file(self, filetypes, callback=None): + fileName, _ = QFileDialog.getSaveFileName( + self.main_window, + "Save file", + str(cfg.data_dir), + filetypes, + options=QFileDialog.DontUseNativeDialog, + ) + if callback: + return callback(fileName) + return fileName + + def set_sys_lst(self, path): + if path not in self.config.history_out_path: + self.config.history_out_path.append(path) + self.inp_sys_lst.addItem(path) + self.inp_out_pp.addItem(path) + + def set_bodies_file(self, path): + if path not in self.config.history_bodies_path: + self.config.history_bodies_path.append(path) + self.inp_bodies_pp.addItem(path) + + def set_systems_file(self, path): + if path not in self.config.history_systems_path: + self.config.history_systems_path.append(path) + self.inp_systems_pp.addItem(path) + + def update_dropdowns(self): + return + + def log(self, *args): + t = datetime.today() + msg_t = "[{}] {}".format(t, str.format(*args)) + self.txt_log.append(msg_t) + + def set_comp_mode(self, _): + if self.rd_comp.isChecked(): + comp_mode = "Compute Route" + self.btn_add.setText("Search+Add") + self.lst_sys.setEnabled(True) + self.btn_rm.setEnabled(True) + self.cmb_mode.setEnabled(True) + mode = self.cmb_mode.currentText() + self.set_route_mode(mode) + if self.rd_precomp.isChecked(): + comp_mode = "Precompute Graph" + self.btn_add.setText("Select") + self.lst_sys.setEnabled(False) + self.btn_rm.setEnabled(False) + self.lbl_greedyness.setEnabled(False) + self.sld_greedyness.setEnabled(False) + self.cmb_mode.setEnabled(False) + + def set_route_mode(self, mode): + self.lbl_greedyness.setEnabled(mode == "A*-Search") + self.sld_greedyness.setEnabled(mode == "A*-Search") + + def set_greedyness(self, value): + val = value / 100 + self.lbl_greedyness.setText("Greedyness Factor ({:.0%})".format(val)) + + def sys_to_dict(self, n): + header = [ + self.lst_sys.headerItem().data(c, 0) + for c in range(self.lst_sys.headerItem().columnCount()) + ] + system = [ + self.lst_sys.topLevelItem(n).data(c, 0) + for c in range(self.lst_sys.topLevelItem(n).columnCount()) + ] + return dict(zip(header, system)) + + def run(self): + settings = {} + settings["permute"] = [None, False, True][self.chk_permute_keep.checkState()] + settings["range"] = self.sb_range.value() + settings["systems"] = [ + self.sys_to_dict(i) for i in range(self.lst_sys.topLevelItemCount()) + ] + print(settings) + # progress = Progressdialog("TEST\nBLAH", "Cancel", 0, 0, self.main_window) + # progress.setWindowTitle("Computing Route") + # progress.setFixedSize(400, 100) + # progress.setRange(0, 0) + # progress.show() + + def add_system(self): + n = self.lst_sys.topLevelItemCount() + 1 + item = QTreeWidgetItem(self.lst_sys, ["A" + str(n), "B" + str(n)]) + item.setFlags(item.flags() & ~Qt.ItemIsDropEnabled) + + def remove_system(self): + root = self.lst_sys.invisibleRootItem() + for item in self.lst_sys.selectedItems(): + root.removeChild(item) + + def setup_signals(self): + self.set_greedyness(self.sld_greedyness.value()) + self.cmb_mode.currentTextChanged.connect(self.set_route_mode) + self.rd_comp.toggled.connect(self.set_comp_mode) + self.rd_precomp.toggled.connect(self.set_comp_mode) + self.sld_greedyness.valueChanged.connect(self.set_greedyness) + self.btn_go.clicked.connect(self.run) + self.btn_add.clicked.connect(self.add_system) + self.btn_rm.clicked.connect(self.remove_system) + self.btn_out_browse_pp.clicked.connect( + lambda: self.get_save_file("CSV File (*.csv)", self.set_sys_lst) + ) + self.btn_sys_lst_browse.clicked.connect( + lambda: self.get_open_file("CSV File (*.csv)", self.set_sys_lst) + ) + + self.btn_bodies_browse_pp.clicked.connect( + lambda: self.get_open_file("JSON File (*.json)", self.set_bodies_file) + ) + self.btn_bodies_dest_browse_dl.clicked.connect( + lambda: self.get_save_file("JSON File (*.json)", self.set_bodies_file) + ) + self.btn_systems_browse_pp.clicked.connect( + lambda: self.get_open_file("JSON File (*.json)", self.set_systems_file) + ) + self.btn_systems_dest_browse_dl.clicked.connect( + lambda: self.get_save_file("JSON File (*.json)", self.set_systems_file) + ) + self.menu_act_quit.triggered.connect(self.app.quit) + + def handle_close(self): + cfg.write(self.config) + print("BYEEEEEE!") + + def setupUi(self, MainWindow, app): + super().setupUi(MainWindow) + self.update_dropdowns() + self.main_window = MainWindow + self.app = app + self.setup_signals() + self.lst_sys.setHeaderLabels(["Name", "Type"]) + + +def main(): + import sys + + app = App() + MainWindow = QMainWindow() + ui = ED_LRR() + ui.setupUi(MainWindow, app) + MainWindow.show() + ret = app.exec_() + ui.handle_close() + sys.exit(ret) + + +if __name__ == "__main__": + main() diff --git a/ed_lrr_gui/config.py b/ed_lrr_gui/config.py new file mode 100644 index 0000000..3e748b7 --- /dev/null +++ b/ed_lrr_gui/config.py @@ -0,0 +1,45 @@ +import pathlib +import appdirs +import yaml +from collections import namedtuple + +config_dir = pathlib.Path(appdirs.user_config_dir("ED_LRR")) +config_dir.mkdir(parents=True, exist_ok=True) +config_file = config_dir / "config.yml" +config_file.touch() + +data_dir = pathlib.Path(appdirs.user_data_dir("ED_LRR")) +data_dir.mkdir(parents=True, exist_ok=True) + + +def make_config(): + return { + "history_bodies_url": [], + "history_systems_url": [], + "history_bodies_path": [], + "history_systems_path": [], + "history_out_path": [], + "range": None, + "primary": False, + "mode": "bfs", + "greedyness": 0.5, + } + + +def write(cfg): + with config_file.open("w", encoding="utf-8") as of: + yaml.dump(cfg._asdict(), of, default_flow_style=False) + + +def load(): + data = yaml.load(config_file.open(encoding="utf-8"), Loader=yaml.Loader) + if data is None: + data = make_config() + write(data) + + return namedtuple("Config", data)(**data) + + +# print("CFG:", yaml.load_config()) +# print(config_file, data_dir) +# exit(1) diff --git a/ed_lrr_gui/gui/__init__.py b/ed_lrr_gui/gui/__init__.py new file mode 100644 index 0000000..e69de29 diff --git a/ed_lrr_gui/gui/ed_lrr.py b/ed_lrr_gui/gui/ed_lrr.py new file mode 100644 index 0000000..70c41d8 --- /dev/null +++ b/ed_lrr_gui/gui/ed_lrr.py @@ -0,0 +1,350 @@ +# -*- coding: utf-8 -*- + +# Form implementation generated from reading ui file 'D:\devel\rust\py_test\ed_lrr_gui\gui\ed_lrr.ui' +# +# Created by: PyQt5 UI code generator 5.13.0 +# +# WARNING! All changes made in this file will be lost! + + +from PyQt5 import QtCore, QtGui, QtWidgets + + +class Ui_ED_LRR(object): + def setupUi(self, ED_LRR): + ED_LRR.setObjectName("ED_LRR") + ED_LRR.setEnabled(True) + ED_LRR.resize(577, 500) + sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Fixed) + sizePolicy.setHorizontalStretch(0) + sizePolicy.setVerticalStretch(0) + sizePolicy.setHeightForWidth(ED_LRR.sizePolicy().hasHeightForWidth()) + ED_LRR.setSizePolicy(sizePolicy) + ED_LRR.setMinimumSize(QtCore.QSize(577, 500)) + ED_LRR.setMaximumSize(QtCore.QSize(577, 500)) + ED_LRR.setDocumentMode(False) + ED_LRR.setTabShape(QtWidgets.QTabWidget.Rounded) + self.centralwidget = QtWidgets.QWidget(ED_LRR) + self.centralwidget.setObjectName("centralwidget") + self.verticalLayout = QtWidgets.QVBoxLayout(self.centralwidget) + self.verticalLayout.setObjectName("verticalLayout") + self.tabs = QtWidgets.QTabWidget(self.centralwidget) + self.tabs.setEnabled(True) + self.tabs.setTabShape(QtWidgets.QTabWidget.Rounded) + self.tabs.setTabsClosable(False) + self.tabs.setTabBarAutoHide(False) + self.tabs.setObjectName("tabs") + self.tab_download = QtWidgets.QWidget() + self.tab_download.setObjectName("tab_download") + self.formLayout = QtWidgets.QFormLayout(self.tab_download) + self.formLayout.setObjectName("formLayout") + self.lbl_bodies_dl = QtWidgets.QLabel(self.tab_download) + self.lbl_bodies_dl.setObjectName("lbl_bodies_dl") + self.formLayout.setWidget(1, QtWidgets.QFormLayout.LabelRole, self.lbl_bodies_dl) + self.lbl_systems_dl = QtWidgets.QLabel(self.tab_download) + self.lbl_systems_dl.setObjectName("lbl_systems_dl") + self.formLayout.setWidget(3, QtWidgets.QFormLayout.LabelRole, self.lbl_systems_dl) + self.inp_bodies_dl = QtWidgets.QComboBox(self.tab_download) + self.inp_bodies_dl.setEditable(True) + self.inp_bodies_dl.setObjectName("inp_bodies_dl") + self.formLayout.setWidget(1, QtWidgets.QFormLayout.FieldRole, self.inp_bodies_dl) + self.inp_systems_dl = QtWidgets.QComboBox(self.tab_download) + self.inp_systems_dl.setEditable(True) + self.inp_systems_dl.setObjectName("inp_systems_dl") + self.formLayout.setWidget(3, QtWidgets.QFormLayout.FieldRole, self.inp_systems_dl) + self.gridLayout = QtWidgets.QGridLayout() + self.gridLayout.setObjectName("gridLayout") + self.inp_bodies_dest_dl = QtWidgets.QComboBox(self.tab_download) + sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Fixed) + sizePolicy.setHorizontalStretch(0) + sizePolicy.setVerticalStretch(0) + sizePolicy.setHeightForWidth(self.inp_bodies_dest_dl.sizePolicy().hasHeightForWidth()) + self.inp_bodies_dest_dl.setSizePolicy(sizePolicy) + self.inp_bodies_dest_dl.setEditable(True) + self.inp_bodies_dest_dl.setObjectName("inp_bodies_dest_dl") + self.gridLayout.addWidget(self.inp_bodies_dest_dl, 0, 0, 1, 1) + self.btn_bodies_dest_browse_dl = QtWidgets.QPushButton(self.tab_download) + self.btn_bodies_dest_browse_dl.setObjectName("btn_bodies_dest_browse_dl") + self.gridLayout.addWidget(self.btn_bodies_dest_browse_dl, 0, 1, 1, 1) + self.formLayout.setLayout(2, QtWidgets.QFormLayout.FieldRole, self.gridLayout) + self.gridLayout_2 = QtWidgets.QGridLayout() + self.gridLayout_2.setObjectName("gridLayout_2") + self.btn_systems_dest_browse_dl = QtWidgets.QPushButton(self.tab_download) + self.btn_systems_dest_browse_dl.setObjectName("btn_systems_dest_browse_dl") + self.gridLayout_2.addWidget(self.btn_systems_dest_browse_dl, 0, 1, 1, 1) + self.inp_systems_dest_dl = QtWidgets.QComboBox(self.tab_download) + sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Fixed) + sizePolicy.setHorizontalStretch(0) + sizePolicy.setVerticalStretch(0) + sizePolicy.setHeightForWidth(self.inp_systems_dest_dl.sizePolicy().hasHeightForWidth()) + self.inp_systems_dest_dl.setSizePolicy(sizePolicy) + self.inp_systems_dest_dl.setEditable(True) + self.inp_systems_dest_dl.setObjectName("inp_systems_dest_dl") + self.gridLayout_2.addWidget(self.inp_systems_dest_dl, 0, 0, 1, 1) + self.formLayout.setLayout(4, QtWidgets.QFormLayout.FieldRole, self.gridLayout_2) + self.btn_download = QtWidgets.QPushButton(self.tab_download) + self.btn_download.setObjectName("btn_download") + self.formLayout.setWidget(5, QtWidgets.QFormLayout.LabelRole, self.btn_download) + self.label = QtWidgets.QLabel(self.tab_download) + self.label.setObjectName("label") + self.formLayout.setWidget(2, QtWidgets.QFormLayout.LabelRole, self.label) + self.label_2 = QtWidgets.QLabel(self.tab_download) + self.label_2.setObjectName("label_2") + self.formLayout.setWidget(4, QtWidgets.QFormLayout.LabelRole, self.label_2) + self.tabs.addTab(self.tab_download, "") + self.tab_preprocess = QtWidgets.QWidget() + self.tab_preprocess.setObjectName("tab_preprocess") + self.formLayout_3 = QtWidgets.QFormLayout(self.tab_preprocess) + self.formLayout_3.setObjectName("formLayout_3") + self.lbl_bodies_pp = QtWidgets.QLabel(self.tab_preprocess) + self.lbl_bodies_pp.setObjectName("lbl_bodies_pp") + self.formLayout_3.setWidget(0, QtWidgets.QFormLayout.LabelRole, self.lbl_bodies_pp) + self.gr_bodies_pp = QtWidgets.QGridLayout() + self.gr_bodies_pp.setObjectName("gr_bodies_pp") + self.btn_bodies_browse_pp = QtWidgets.QPushButton(self.tab_preprocess) + self.btn_bodies_browse_pp.setObjectName("btn_bodies_browse_pp") + self.gr_bodies_pp.addWidget(self.btn_bodies_browse_pp, 0, 1, 1, 1) + self.inp_bodies_pp = QtWidgets.QComboBox(self.tab_preprocess) + sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Fixed) + sizePolicy.setHorizontalStretch(0) + sizePolicy.setVerticalStretch(0) + sizePolicy.setHeightForWidth(self.inp_bodies_pp.sizePolicy().hasHeightForWidth()) + self.inp_bodies_pp.setSizePolicy(sizePolicy) + self.inp_bodies_pp.setEditable(True) + self.inp_bodies_pp.setObjectName("inp_bodies_pp") + self.gr_bodies_pp.addWidget(self.inp_bodies_pp, 0, 0, 1, 1) + self.formLayout_3.setLayout(0, QtWidgets.QFormLayout.FieldRole, self.gr_bodies_pp) + self.lbl_systems_pp = QtWidgets.QLabel(self.tab_preprocess) + self.lbl_systems_pp.setObjectName("lbl_systems_pp") + self.formLayout_3.setWidget(1, QtWidgets.QFormLayout.LabelRole, self.lbl_systems_pp) + self.gr_systems_pp = QtWidgets.QGridLayout() + self.gr_systems_pp.setObjectName("gr_systems_pp") + self.btn_systems_browse_pp = QtWidgets.QPushButton(self.tab_preprocess) + self.btn_systems_browse_pp.setObjectName("btn_systems_browse_pp") + self.gr_systems_pp.addWidget(self.btn_systems_browse_pp, 0, 1, 1, 1) + self.inp_systems_pp = QtWidgets.QComboBox(self.tab_preprocess) + sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Fixed) + sizePolicy.setHorizontalStretch(0) + sizePolicy.setVerticalStretch(0) + sizePolicy.setHeightForWidth(self.inp_systems_pp.sizePolicy().hasHeightForWidth()) + self.inp_systems_pp.setSizePolicy(sizePolicy) + self.inp_systems_pp.setEditable(True) + self.inp_systems_pp.setObjectName("inp_systems_pp") + self.gr_systems_pp.addWidget(self.inp_systems_pp, 0, 0, 1, 1) + self.formLayout_3.setLayout(1, QtWidgets.QFormLayout.FieldRole, self.gr_systems_pp) + self.lbl_out_pp = QtWidgets.QLabel(self.tab_preprocess) + self.lbl_out_pp.setObjectName("lbl_out_pp") + self.formLayout_3.setWidget(2, QtWidgets.QFormLayout.LabelRole, self.lbl_out_pp) + self.gr_out_grid_pp = QtWidgets.QGridLayout() + self.gr_out_grid_pp.setObjectName("gr_out_grid_pp") + self.btn_out_browse_pp = QtWidgets.QPushButton(self.tab_preprocess) + sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Minimum, QtWidgets.QSizePolicy.Fixed) + sizePolicy.setHorizontalStretch(0) + sizePolicy.setVerticalStretch(0) + sizePolicy.setHeightForWidth(self.btn_out_browse_pp.sizePolicy().hasHeightForWidth()) + self.btn_out_browse_pp.setSizePolicy(sizePolicy) + self.btn_out_browse_pp.setObjectName("btn_out_browse_pp") + self.gr_out_grid_pp.addWidget(self.btn_out_browse_pp, 0, 1, 1, 1) + self.inp_out_pp = QtWidgets.QComboBox(self.tab_preprocess) + sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Fixed) + sizePolicy.setHorizontalStretch(0) + sizePolicy.setVerticalStretch(0) + sizePolicy.setHeightForWidth(self.inp_out_pp.sizePolicy().hasHeightForWidth()) + self.inp_out_pp.setSizePolicy(sizePolicy) + self.inp_out_pp.setEditable(True) + self.inp_out_pp.setObjectName("inp_out_pp") + self.gr_out_grid_pp.addWidget(self.inp_out_pp, 0, 0, 1, 1) + self.formLayout_3.setLayout(2, QtWidgets.QFormLayout.FieldRole, self.gr_out_grid_pp) + self.btn_preprocess = QtWidgets.QPushButton(self.tab_preprocess) + self.btn_preprocess.setObjectName("btn_preprocess") + self.formLayout_3.setWidget(3, QtWidgets.QFormLayout.LabelRole, self.btn_preprocess) + self.tabs.addTab(self.tab_preprocess, "") + self.tab_route = QtWidgets.QWidget() + self.tab_route.setObjectName("tab_route") + self.formLayout_2 = QtWidgets.QFormLayout(self.tab_route) + self.formLayout_2.setObjectName("formLayout_2") + self.lbl_sys_lst = QtWidgets.QLabel(self.tab_route) + self.lbl_sys_lst.setObjectName("lbl_sys_lst") + self.formLayout_2.setWidget(0, QtWidgets.QFormLayout.LabelRole, self.lbl_sys_lst) + self.gr_sys = QtWidgets.QGridLayout() + self.gr_sys.setObjectName("gr_sys") + self.btn_sys_lst_browse = QtWidgets.QPushButton(self.tab_route) + self.btn_sys_lst_browse.setObjectName("btn_sys_lst_browse") + self.gr_sys.addWidget(self.btn_sys_lst_browse, 0, 1, 1, 1) + self.inp_sys_lst = QtWidgets.QComboBox(self.tab_route) + sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Fixed) + sizePolicy.setHorizontalStretch(0) + sizePolicy.setVerticalStretch(0) + sizePolicy.setHeightForWidth(self.inp_sys_lst.sizePolicy().hasHeightForWidth()) + self.inp_sys_lst.setSizePolicy(sizePolicy) + self.inp_sys_lst.setEditable(True) + self.inp_sys_lst.setObjectName("inp_sys_lst") + self.gr_sys.addWidget(self.inp_sys_lst, 0, 0, 1, 1) + self.formLayout_2.setLayout(0, QtWidgets.QFormLayout.FieldRole, self.gr_sys) + self.btn_add = QtWidgets.QPushButton(self.tab_route) + self.btn_add.setObjectName("btn_add") + self.formLayout_2.setWidget(1, QtWidgets.QFormLayout.LabelRole, self.btn_add) + self.inp_sys = QtWidgets.QLineEdit(self.tab_route) + self.inp_sys.setObjectName("inp_sys") + self.formLayout_2.setWidget(1, QtWidgets.QFormLayout.FieldRole, self.inp_sys) + self.btn_rm = QtWidgets.QPushButton(self.tab_route) + self.btn_rm.setObjectName("btn_rm") + self.formLayout_2.setWidget(3, QtWidgets.QFormLayout.LabelRole, self.btn_rm) + self.gr_mode = QtWidgets.QGridLayout() + self.gr_mode.setObjectName("gr_mode") + self.rd_comp = QtWidgets.QRadioButton(self.tab_route) + self.rd_comp.setChecked(True) + self.rd_comp.setObjectName("rd_comp") + self.gr_mode.addWidget(self.rd_comp, 0, 1, 1, 1) + self.rd_precomp = QtWidgets.QRadioButton(self.tab_route) + self.rd_precomp.setObjectName("rd_precomp") + self.gr_mode.addWidget(self.rd_precomp, 0, 2, 1, 1) + self.formLayout_2.setLayout(3, QtWidgets.QFormLayout.FieldRole, self.gr_mode) + self.btn_permute = QtWidgets.QPushButton(self.tab_route) + self.btn_permute.setObjectName("btn_permute") + self.formLayout_2.setWidget(4, QtWidgets.QFormLayout.LabelRole, self.btn_permute) + self.chk_permute_keep = QtWidgets.QCheckBox(self.tab_route) + sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Fixed) + sizePolicy.setHorizontalStretch(0) + sizePolicy.setVerticalStretch(0) + sizePolicy.setHeightForWidth(self.chk_permute_keep.sizePolicy().hasHeightForWidth()) + self.chk_permute_keep.setSizePolicy(sizePolicy) + self.chk_permute_keep.setTristate(True) + self.chk_permute_keep.setObjectName("chk_permute_keep") + self.formLayout_2.setWidget(4, QtWidgets.QFormLayout.FieldRole, self.chk_permute_keep) + self.lst_sys = QtWidgets.QTreeWidget(self.tab_route) + sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Expanding) + sizePolicy.setHorizontalStretch(0) + sizePolicy.setVerticalStretch(0) + sizePolicy.setHeightForWidth(self.lst_sys.sizePolicy().hasHeightForWidth()) + self.lst_sys.setSizePolicy(sizePolicy) + self.lst_sys.setMinimumSize(QtCore.QSize(0, 0)) + self.lst_sys.setDragEnabled(True) + self.lst_sys.setDragDropOverwriteMode(False) + self.lst_sys.setDragDropMode(QtWidgets.QAbstractItemView.InternalMove) + self.lst_sys.setDefaultDropAction(QtCore.Qt.MoveAction) + self.lst_sys.setAlternatingRowColors(True) + self.lst_sys.setSelectionMode(QtWidgets.QAbstractItemView.ExtendedSelection) + self.lst_sys.setSelectionBehavior(QtWidgets.QAbstractItemView.SelectRows) + self.lst_sys.setObjectName("lst_sys") + self.lst_sys.headerItem().setText(0, "1") + self.formLayout_2.setWidget(5, QtWidgets.QFormLayout.SpanningRole, self.lst_sys) + self.sb_range = QtWidgets.QDoubleSpinBox(self.tab_route) + self.sb_range.setObjectName("sb_range") + self.formLayout_2.setWidget(6, QtWidgets.QFormLayout.FieldRole, self.sb_range) + self.lbl_range = QtWidgets.QLabel(self.tab_route) + self.lbl_range.setObjectName("lbl_range") + self.formLayout_2.setWidget(6, QtWidgets.QFormLayout.LabelRole, self.lbl_range) + self.gr_opts = QtWidgets.QGridLayout() + self.gr_opts.setObjectName("gr_opts") + self.cmb_mode = QtWidgets.QComboBox(self.tab_route) + self.cmb_mode.setObjectName("cmb_mode") + self.cmb_mode.addItem("") + self.cmb_mode.addItem("") + self.cmb_mode.addItem("") + self.gr_opts.addWidget(self.cmb_mode, 0, 2, 1, 1) + self.lbl_greedyness = QtWidgets.QLabel(self.tab_route) + self.lbl_greedyness.setEnabled(True) + self.lbl_greedyness.setObjectName("lbl_greedyness") + self.gr_opts.addWidget(self.lbl_greedyness, 1, 1, 1, 1) + self.chk_primary = QtWidgets.QCheckBox(self.tab_route) + self.chk_primary.setObjectName("chk_primary") + self.gr_opts.addWidget(self.chk_primary, 0, 3, 1, 1) + self.sld_greedyness = QtWidgets.QSlider(self.tab_route) + self.sld_greedyness.setMaximum(100) + self.sld_greedyness.setPageStep(10) + self.sld_greedyness.setProperty("value", 50) + self.sld_greedyness.setOrientation(QtCore.Qt.Horizontal) + self.sld_greedyness.setTickPosition(QtWidgets.QSlider.TicksBelow) + self.sld_greedyness.setTickInterval(10) + self.sld_greedyness.setObjectName("sld_greedyness") + self.gr_opts.addWidget(self.sld_greedyness, 1, 2, 1, 2) + self.lbl_mode = QtWidgets.QLabel(self.tab_route) + self.lbl_mode.setObjectName("lbl_mode") + self.gr_opts.addWidget(self.lbl_mode, 0, 1, 1, 1) + self.formLayout_2.setLayout(7, QtWidgets.QFormLayout.SpanningRole, self.gr_opts) + self.btn_go = QtWidgets.QPushButton(self.tab_route) + self.btn_go.setFlat(False) + self.btn_go.setObjectName("btn_go") + self.formLayout_2.setWidget(8, QtWidgets.QFormLayout.LabelRole, self.btn_go) + self.tabs.addTab(self.tab_route, "") + self.tab_log = QtWidgets.QWidget() + self.tab_log.setObjectName("tab_log") + self.gridLayout_3 = QtWidgets.QGridLayout(self.tab_log) + self.gridLayout_3.setObjectName("gridLayout_3") + self.txt_log = QtWidgets.QTextEdit(self.tab_log) + self.txt_log.setEnabled(True) + self.txt_log.setFrameShadow(QtWidgets.QFrame.Sunken) + self.txt_log.setLineWidth(1) + self.txt_log.setReadOnly(True) + self.txt_log.setAcceptRichText(False) + self.txt_log.setObjectName("txt_log") + self.gridLayout_3.addWidget(self.txt_log, 0, 0, 1, 1) + self.tabs.addTab(self.tab_log, "") + self.verticalLayout.addWidget(self.tabs) + ED_LRR.setCentralWidget(self.centralwidget) + self.menu = QtWidgets.QMenuBar(ED_LRR) + self.menu.setGeometry(QtCore.QRect(0, 0, 577, 21)) + self.menu.setObjectName("menu") + self.menu_file = QtWidgets.QMenu(self.menu) + self.menu_file.setObjectName("menu_file") + ED_LRR.setMenuBar(self.menu) + self.bar_status = QtWidgets.QStatusBar(ED_LRR) + self.bar_status.setObjectName("bar_status") + ED_LRR.setStatusBar(self.bar_status) + self.menu_act_quit = QtWidgets.QAction(ED_LRR) + self.menu_act_quit.setObjectName("menu_act_quit") + self.menu_file.addAction(self.menu_act_quit) + self.menu.addAction(self.menu_file.menuAction()) + + self.retranslateUi(ED_LRR) + self.tabs.setCurrentIndex(2) + QtCore.QMetaObject.connectSlotsByName(ED_LRR) + ED_LRR.setTabOrder(self.rd_comp, self.cmb_mode) + ED_LRR.setTabOrder(self.cmb_mode, self.chk_primary) + ED_LRR.setTabOrder(self.chk_primary, self.sld_greedyness) + ED_LRR.setTabOrder(self.sld_greedyness, self.rd_precomp) + + def retranslateUi(self, ED_LRR): + _translate = QtCore.QCoreApplication.translate + ED_LRR.setWindowTitle(_translate("ED_LRR", "Elite: Dangerous Long Range Route Plotter")) + self.lbl_bodies_dl.setText(_translate("ED_LRR", "bodies.json")) + self.lbl_systems_dl.setText(_translate("ED_LRR", "systemsWithCoordinates.json")) + self.inp_bodies_dl.setCurrentText(_translate("ED_LRR", "https://www.edsm.net/dump/bodies.json")) + self.inp_systems_dl.setCurrentText(_translate("ED_LRR", "https://www.edsm.net/dump/systemsWithCoordinates.json")) + self.btn_bodies_dest_browse_dl.setText(_translate("ED_LRR", "...")) + self.btn_systems_dest_browse_dl.setText(_translate("ED_LRR", "...")) + self.btn_download.setText(_translate("ED_LRR", "Download")) + self.label.setText(_translate("ED_LRR", "Download path")) + self.label_2.setText(_translate("ED_LRR", "Download path")) + self.tabs.setTabText(self.tabs.indexOf(self.tab_download), _translate("ED_LRR", "Download")) + self.lbl_bodies_pp.setText(_translate("ED_LRR", "bodies.json")) + self.btn_bodies_browse_pp.setText(_translate("ED_LRR", "...")) + self.lbl_systems_pp.setText(_translate("ED_LRR", "systemsWithCoordinates.json")) + self.btn_systems_browse_pp.setText(_translate("ED_LRR", "...")) + self.lbl_out_pp.setText(_translate("ED_LRR", "Output")) + self.btn_out_browse_pp.setText(_translate("ED_LRR", "...")) + self.btn_preprocess.setText(_translate("ED_LRR", "Preprocess")) + self.tabs.setTabText(self.tabs.indexOf(self.tab_preprocess), _translate("ED_LRR", "Preprocess")) + self.lbl_sys_lst.setText(_translate("ED_LRR", "System List")) + self.btn_sys_lst_browse.setText(_translate("ED_LRR", "...")) + self.btn_add.setText(_translate("ED_LRR", "Search+Add")) + self.btn_rm.setText(_translate("ED_LRR", "Remove")) + self.rd_comp.setText(_translate("ED_LRR", "Compute Route")) + self.rd_precomp.setText(_translate("ED_LRR", "Precompute Graph")) + self.btn_permute.setText(_translate("ED_LRR", "Permute")) + self.chk_permute_keep.setText(_translate("ED_LRR", "Keep endpoints (No, first only, yes)")) + self.lbl_range.setText(_translate("ED_LRR", "Jump Range (Ly)")) + self.cmb_mode.setCurrentText(_translate("ED_LRR", "Breadth-First Search")) + self.cmb_mode.setItemText(0, _translate("ED_LRR", "Breadth-First Search")) + self.cmb_mode.setItemText(1, _translate("ED_LRR", "Greedy-Search")) + self.cmb_mode.setItemText(2, _translate("ED_LRR", "A*-Search")) + self.lbl_greedyness.setText(_translate("ED_LRR", "Greedyness Factor")) + self.chk_primary.setText(_translate("ED_LRR", "Primary Stars Only")) + self.lbl_mode.setText(_translate("ED_LRR", "Mode")) + self.btn_go.setText(_translate("ED_LRR", "GO!")) + self.tabs.setTabText(self.tabs.indexOf(self.tab_route), _translate("ED_LRR", "Route")) + self.tabs.setTabText(self.tabs.indexOf(self.tab_log), _translate("ED_LRR", "Log")) + self.menu_file.setTitle(_translate("ED_LRR", "File")) + self.menu_act_quit.setText(_translate("ED_LRR", "Quit")) + self.menu_act_quit.setShortcut(_translate("ED_LRR", "Ctrl+Q")) diff --git a/ed_lrr_gui/gui/ed_lrr.ui b/ed_lrr_gui/gui/ed_lrr.ui new file mode 100644 index 0000000..24cb6be --- /dev/null +++ b/ed_lrr_gui/gui/ed_lrr.ui @@ -0,0 +1,584 @@ + + + ED_LRR + + + true + + + + 0 + 0 + 577 + 500 + + + + + 0 + 0 + + + + + 577 + 500 + + + + + 577 + 500 + + + + Elite: Dangerous Long Range Route Plotter + + + false + + + QTabWidget::Rounded + + + + + + + true + + + QTabWidget::Rounded + + + 2 + + + false + + + false + + + + Download + + + + + + bodies.json + + + + + + + systemsWithCoordinates.json + + + + + + + true + + + https://www.edsm.net/dump/bodies.json + + + + + + + true + + + https://www.edsm.net/dump/systemsWithCoordinates.json + + + + + + + + + + 0 + 0 + + + + true + + + + + + + ... + + + + + + + + + + + ... + + + + + + + + 0 + 0 + + + + true + + + + + + + + + Download + + + + + + + Download path + + + + + + + Download path + + + + + + + + Preprocess + + + + + + bodies.json + + + + + + + + + ... + + + + + + + + 0 + 0 + + + + true + + + + + + + + + systemsWithCoordinates.json + + + + + + + + + ... + + + + + + + + 0 + 0 + + + + true + + + + + + + + + Output + + + + + + + + + + 0 + 0 + + + + ... + + + + + + + + 0 + 0 + + + + true + + + + + + + + + Preprocess + + + + + + + + Route + + + + + + System List + + + + + + + + + ... + + + + + + + + 0 + 0 + + + + true + + + + + + + + + Search+Add + + + + + + + + + + Remove + + + + + + + + + Compute Route + + + true + + + + + + + Precompute Graph + + + + + + + + + Permute + + + + + + + + 0 + 0 + + + + Keep endpoints (No, first only, yes) + + + true + + + + + + + + 0 + 0 + + + + + 0 + 0 + + + + true + + + false + + + QAbstractItemView::InternalMove + + + Qt::MoveAction + + + true + + + QAbstractItemView::ExtendedSelection + + + QAbstractItemView::SelectRows + + + + 1 + + + + + + + + + + + Jump Range (Ly) + + + + + + + + + Breadth-First Search + + + + Breadth-First Search + + + + + Greedy-Search + + + + + A*-Search + + + + + + + + true + + + Greedyness Factor + + + + + + + Primary Stars Only + + + + + + + 100 + + + 10 + + + 50 + + + Qt::Horizontal + + + QSlider::TicksBelow + + + 10 + + + + + + + Mode + + + + + + + + + GO! + + + false + + + + + + + + Log + + + + + + true + + + QFrame::Sunken + + + 1 + + + true + + + false + + + + + + + + + + + + + 0 + 0 + 577 + 21 + + + + + File + + + + + + + + + Quit + + + Ctrl+Q + + + + + rd_comp + cmb_mode + chk_primary + sld_greedyness + rd_precomp + + + + diff --git a/pyproject.toml b/pyproject.toml new file mode 100644 index 0000000..2b6e07f --- /dev/null +++ b/pyproject.toml @@ -0,0 +1,2 @@ +[build-system] +requires = ["setuptools", "wheel", "setuptools-rust"] \ No newline at end of file diff --git a/rust/.cargo/config b/rust/.cargo/config new file mode 100644 index 0000000..f0b7483 --- /dev/null +++ b/rust/.cargo/config @@ -0,0 +1,2 @@ +[build] +rustflags = ["-C", "target-cpu=native"] \ No newline at end of file diff --git a/rust/Cargo.lock b/rust/Cargo.lock new file mode 100644 index 0000000..84eb592 --- /dev/null +++ b/rust/Cargo.lock @@ -0,0 +1,2091 @@ +# This file is automatically @generated by Cargo. +# It is not intended for manual editing. +[[package]] +name = "adler32" +version = "1.0.3" +source = "registry+https://github.com/rust-lang/crates.io-index" + +[[package]] +name = "aho-corasick" +version = "0.7.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "memchr 2.2.0 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "ansi_term" +version = "0.11.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "winapi 0.3.7 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "arrayvec" +version = "0.4.10" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "nodrop 0.1.13 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "atty" +version = "0.2.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "libc 0.2.58 (registry+https://github.com/rust-lang/crates.io-index)", + "termion 1.5.3 (registry+https://github.com/rust-lang/crates.io-index)", + "winapi 0.3.7 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "autocfg" +version = "0.1.4" +source = "registry+https://github.com/rust-lang/crates.io-index" + +[[package]] +name = "backtrace" +version = "0.3.32" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "backtrace-sys 0.1.30 (registry+https://github.com/rust-lang/crates.io-index)", + "cfg-if 0.1.9 (registry+https://github.com/rust-lang/crates.io-index)", + "libc 0.2.58 (registry+https://github.com/rust-lang/crates.io-index)", + "rustc-demangle 0.1.15 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "backtrace-sys" +version = "0.1.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "cc 1.0.37 (registry+https://github.com/rust-lang/crates.io-index)", + "libc 0.2.58 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "base64" +version = "0.10.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "byteorder 1.3.2 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "bincode" +version = "1.1.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "autocfg 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)", + "byteorder 1.3.2 (registry+https://github.com/rust-lang/crates.io-index)", + "serde 1.0.94 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "bitflags" +version = "1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" + +[[package]] +name = "block-buffer" +version = "0.7.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "block-padding 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)", + "byte-tools 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)", + "byteorder 1.3.2 (registry+https://github.com/rust-lang/crates.io-index)", + "generic-array 0.12.3 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "block-padding" +version = "0.1.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "byte-tools 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "bstr" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "lazy_static 1.3.0 (registry+https://github.com/rust-lang/crates.io-index)", + "memchr 2.2.0 (registry+https://github.com/rust-lang/crates.io-index)", + "regex-automata 0.1.7 (registry+https://github.com/rust-lang/crates.io-index)", + "serde 1.0.94 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "byte-tools" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" + +[[package]] +name = "byteorder" +version = "1.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" + +[[package]] +name = "bytes" +version = "0.4.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "byteorder 1.3.2 (registry+https://github.com/rust-lang/crates.io-index)", + "either 1.5.2 (registry+https://github.com/rust-lang/crates.io-index)", + "iovec 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "c2-chacha" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "lazy_static 1.3.0 (registry+https://github.com/rust-lang/crates.io-index)", + "ppv-lite86 0.2.5 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "cc" +version = "1.0.37" +source = "registry+https://github.com/rust-lang/crates.io-index" + +[[package]] +name = "cfg-if" +version = "0.1.9" +source = "registry+https://github.com/rust-lang/crates.io-index" + +[[package]] +name = "clap" +version = "2.33.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "ansi_term 0.11.0 (registry+https://github.com/rust-lang/crates.io-index)", + "atty 0.2.11 (registry+https://github.com/rust-lang/crates.io-index)", + "bitflags 1.1.0 (registry+https://github.com/rust-lang/crates.io-index)", + "strsim 0.8.0 (registry+https://github.com/rust-lang/crates.io-index)", + "textwrap 0.11.0 (registry+https://github.com/rust-lang/crates.io-index)", + "unicode-width 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)", + "vec_map 0.8.1 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "clicolors-control" +version = "1.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "atty 0.2.11 (registry+https://github.com/rust-lang/crates.io-index)", + "lazy_static 1.3.0 (registry+https://github.com/rust-lang/crates.io-index)", + "libc 0.2.58 (registry+https://github.com/rust-lang/crates.io-index)", + "winapi 0.3.7 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "cloudabi" +version = "0.0.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "bitflags 1.1.0 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "console" +version = "0.7.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "atty 0.2.11 (registry+https://github.com/rust-lang/crates.io-index)", + "clicolors-control 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)", + "encode_unicode 0.3.5 (registry+https://github.com/rust-lang/crates.io-index)", + "lazy_static 1.3.0 (registry+https://github.com/rust-lang/crates.io-index)", + "libc 0.2.58 (registry+https://github.com/rust-lang/crates.io-index)", + "parking_lot 0.8.0 (registry+https://github.com/rust-lang/crates.io-index)", + "regex 1.1.7 (registry+https://github.com/rust-lang/crates.io-index)", + "termios 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)", + "unicode-width 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)", + "winapi 0.3.7 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "cookie" +version = "0.12.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "time 0.1.42 (registry+https://github.com/rust-lang/crates.io-index)", + "url 1.7.2 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "cookie_store" +version = "0.7.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "cookie 0.12.0 (registry+https://github.com/rust-lang/crates.io-index)", + "failure 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)", + "idna 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)", + "log 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)", + "publicsuffix 1.5.2 (registry+https://github.com/rust-lang/crates.io-index)", + "serde 1.0.94 (registry+https://github.com/rust-lang/crates.io-index)", + "serde_json 1.0.40 (registry+https://github.com/rust-lang/crates.io-index)", + "time 0.1.42 (registry+https://github.com/rust-lang/crates.io-index)", + "try_from 0.3.2 (registry+https://github.com/rust-lang/crates.io-index)", + "url 1.7.2 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "core-foundation" +version = "0.6.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "core-foundation-sys 0.6.2 (registry+https://github.com/rust-lang/crates.io-index)", + "libc 0.2.58 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "core-foundation-sys" +version = "0.6.2" +source = "registry+https://github.com/rust-lang/crates.io-index" + +[[package]] +name = "crc32fast" +version = "1.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "cfg-if 0.1.9 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "crossbeam-deque" +version = "0.7.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "crossbeam-epoch 0.7.1 (registry+https://github.com/rust-lang/crates.io-index)", + "crossbeam-utils 0.6.5 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "crossbeam-epoch" +version = "0.7.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "arrayvec 0.4.10 (registry+https://github.com/rust-lang/crates.io-index)", + "cfg-if 0.1.9 (registry+https://github.com/rust-lang/crates.io-index)", + "crossbeam-utils 0.6.5 (registry+https://github.com/rust-lang/crates.io-index)", + "lazy_static 1.3.0 (registry+https://github.com/rust-lang/crates.io-index)", + "memoffset 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)", + "scopeguard 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "crossbeam-queue" +version = "0.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "crossbeam-utils 0.6.5 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "crossbeam-utils" +version = "0.6.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "cfg-if 0.1.9 (registry+https://github.com/rust-lang/crates.io-index)", + "lazy_static 1.3.0 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "csv" +version = "1.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "bstr 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)", + "csv-core 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)", + "itoa 0.4.4 (registry+https://github.com/rust-lang/crates.io-index)", + "ryu 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)", + "serde 1.0.94 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "csv-core" +version = "0.1.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "memchr 2.2.0 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "ctor" +version = "0.1.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "quote 0.6.12 (registry+https://github.com/rust-lang/crates.io-index)", + "syn 0.15.39 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "digest" +version = "0.8.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "generic-array 0.12.3 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "dtoa" +version = "0.4.4" +source = "registry+https://github.com/rust-lang/crates.io-index" + +[[package]] +name = "ed_lrr" +version = "0.1.0" +dependencies = [ + "bincode 1.1.4 (registry+https://github.com/rust-lang/crates.io-index)", + "byteorder 1.3.2 (registry+https://github.com/rust-lang/crates.io-index)", + "csv 1.1.1 (registry+https://github.com/rust-lang/crates.io-index)", + "fnv 1.0.6 (registry+https://github.com/rust-lang/crates.io-index)", + "humantime 1.2.0 (registry+https://github.com/rust-lang/crates.io-index)", + "indicatif 0.11.0 (registry+https://github.com/rust-lang/crates.io-index)", + "permutohedron 0.2.4 (registry+https://github.com/rust-lang/crates.io-index)", + "pyo3 0.7.0 (registry+https://github.com/rust-lang/crates.io-index)", + "reqwest 0.9.18 (registry+https://github.com/rust-lang/crates.io-index)", + "rstar 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)", + "serde 1.0.94 (registry+https://github.com/rust-lang/crates.io-index)", + "serde_derive 1.0.94 (registry+https://github.com/rust-lang/crates.io-index)", + "serde_json 1.0.40 (registry+https://github.com/rust-lang/crates.io-index)", + "sha3 0.8.2 (registry+https://github.com/rust-lang/crates.io-index)", + "structopt 0.2.18 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "either" +version = "1.5.2" +source = "registry+https://github.com/rust-lang/crates.io-index" + +[[package]] +name = "encode_unicode" +version = "0.3.5" +source = "registry+https://github.com/rust-lang/crates.io-index" + +[[package]] +name = "encoding_rs" +version = "0.8.17" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "cfg-if 0.1.9 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "error-chain" +version = "0.12.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "backtrace 0.3.32 (registry+https://github.com/rust-lang/crates.io-index)", + "version_check 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "failure" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "backtrace 0.3.32 (registry+https://github.com/rust-lang/crates.io-index)", + "failure_derive 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "failure_derive" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "proc-macro2 0.4.30 (registry+https://github.com/rust-lang/crates.io-index)", + "quote 0.6.12 (registry+https://github.com/rust-lang/crates.io-index)", + "syn 0.15.39 (registry+https://github.com/rust-lang/crates.io-index)", + "synstructure 0.10.2 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "flate2" +version = "1.0.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "crc32fast 1.2.0 (registry+https://github.com/rust-lang/crates.io-index)", + "libc 0.2.58 (registry+https://github.com/rust-lang/crates.io-index)", + "miniz_oxide_c_api 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "fnv" +version = "1.0.6" +source = "registry+https://github.com/rust-lang/crates.io-index" + +[[package]] +name = "foreign-types" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "foreign-types-shared 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "foreign-types-shared" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" + +[[package]] +name = "fuchsia-cprng" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" + +[[package]] +name = "fuchsia-zircon" +version = "0.3.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "bitflags 1.1.0 (registry+https://github.com/rust-lang/crates.io-index)", + "fuchsia-zircon-sys 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "fuchsia-zircon-sys" +version = "0.3.3" +source = "registry+https://github.com/rust-lang/crates.io-index" + +[[package]] +name = "futures" +version = "0.1.28" +source = "registry+https://github.com/rust-lang/crates.io-index" + +[[package]] +name = "futures-cpupool" +version = "0.1.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "futures 0.1.28 (registry+https://github.com/rust-lang/crates.io-index)", + "num_cpus 1.10.1 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "generic-array" +version = "0.12.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "typenum 1.10.0 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "getrandom" +version = "0.1.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "lazy_static 1.3.0 (registry+https://github.com/rust-lang/crates.io-index)", + "libc 0.2.58 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "ghost" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "proc-macro2 0.4.30 (registry+https://github.com/rust-lang/crates.io-index)", + "quote 0.6.12 (registry+https://github.com/rust-lang/crates.io-index)", + "syn 0.15.39 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "h2" +version = "0.1.25" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "byteorder 1.3.2 (registry+https://github.com/rust-lang/crates.io-index)", + "bytes 0.4.12 (registry+https://github.com/rust-lang/crates.io-index)", + "fnv 1.0.6 (registry+https://github.com/rust-lang/crates.io-index)", + "futures 0.1.28 (registry+https://github.com/rust-lang/crates.io-index)", + "http 0.1.17 (registry+https://github.com/rust-lang/crates.io-index)", + "indexmap 1.0.2 (registry+https://github.com/rust-lang/crates.io-index)", + "log 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)", + "slab 0.4.2 (registry+https://github.com/rust-lang/crates.io-index)", + "string 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)", + "tokio-io 0.1.12 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "heck" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "unicode-segmentation 1.3.0 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "http" +version = "0.1.17" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "bytes 0.4.12 (registry+https://github.com/rust-lang/crates.io-index)", + "fnv 1.0.6 (registry+https://github.com/rust-lang/crates.io-index)", + "itoa 0.4.4 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "http-body" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "bytes 0.4.12 (registry+https://github.com/rust-lang/crates.io-index)", + "futures 0.1.28 (registry+https://github.com/rust-lang/crates.io-index)", + "http 0.1.17 (registry+https://github.com/rust-lang/crates.io-index)", + "tokio-buf 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "httparse" +version = "1.3.4" +source = "registry+https://github.com/rust-lang/crates.io-index" + +[[package]] +name = "humantime" +version = "1.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "quick-error 1.2.2 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "hyper" +version = "0.12.31" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "bytes 0.4.12 (registry+https://github.com/rust-lang/crates.io-index)", + "futures 0.1.28 (registry+https://github.com/rust-lang/crates.io-index)", + "futures-cpupool 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)", + "h2 0.1.25 (registry+https://github.com/rust-lang/crates.io-index)", + "http 0.1.17 (registry+https://github.com/rust-lang/crates.io-index)", + "http-body 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)", + "httparse 1.3.4 (registry+https://github.com/rust-lang/crates.io-index)", + "iovec 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)", + "itoa 0.4.4 (registry+https://github.com/rust-lang/crates.io-index)", + "log 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)", + "net2 0.2.33 (registry+https://github.com/rust-lang/crates.io-index)", + "rustc_version 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)", + "time 0.1.42 (registry+https://github.com/rust-lang/crates.io-index)", + "tokio 0.1.22 (registry+https://github.com/rust-lang/crates.io-index)", + "tokio-buf 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)", + "tokio-executor 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)", + "tokio-io 0.1.12 (registry+https://github.com/rust-lang/crates.io-index)", + "tokio-reactor 0.1.9 (registry+https://github.com/rust-lang/crates.io-index)", + "tokio-tcp 0.1.3 (registry+https://github.com/rust-lang/crates.io-index)", + "tokio-threadpool 0.1.15 (registry+https://github.com/rust-lang/crates.io-index)", + "tokio-timer 0.2.11 (registry+https://github.com/rust-lang/crates.io-index)", + "want 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "hyper-tls" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "bytes 0.4.12 (registry+https://github.com/rust-lang/crates.io-index)", + "futures 0.1.28 (registry+https://github.com/rust-lang/crates.io-index)", + "hyper 0.12.31 (registry+https://github.com/rust-lang/crates.io-index)", + "native-tls 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)", + "tokio-io 0.1.12 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "idna" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "matches 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)", + "unicode-bidi 0.3.4 (registry+https://github.com/rust-lang/crates.io-index)", + "unicode-normalization 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "indexmap" +version = "1.0.2" +source = "registry+https://github.com/rust-lang/crates.io-index" + +[[package]] +name = "indicatif" +version = "0.11.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "console 0.7.7 (registry+https://github.com/rust-lang/crates.io-index)", + "lazy_static 1.3.0 (registry+https://github.com/rust-lang/crates.io-index)", + "number_prefix 0.2.8 (registry+https://github.com/rust-lang/crates.io-index)", + "parking_lot 0.8.0 (registry+https://github.com/rust-lang/crates.io-index)", + "regex 1.1.7 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "inventory" +version = "0.1.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "ctor 0.1.9 (registry+https://github.com/rust-lang/crates.io-index)", + "ghost 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)", + "inventory-impl 0.1.3 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "inventory-impl" +version = "0.1.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "proc-macro2 0.4.30 (registry+https://github.com/rust-lang/crates.io-index)", + "quote 0.6.12 (registry+https://github.com/rust-lang/crates.io-index)", + "syn 0.15.39 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "iovec" +version = "0.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "libc 0.2.58 (registry+https://github.com/rust-lang/crates.io-index)", + "winapi 0.2.8 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "itertools" +version = "0.8.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "either 1.5.2 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "itoa" +version = "0.4.4" +source = "registry+https://github.com/rust-lang/crates.io-index" + +[[package]] +name = "keccak" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" + +[[package]] +name = "kernel32-sys" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "winapi 0.2.8 (registry+https://github.com/rust-lang/crates.io-index)", + "winapi-build 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "lazy_static" +version = "1.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "spin 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "libc" +version = "0.2.58" +source = "registry+https://github.com/rust-lang/crates.io-index" + +[[package]] +name = "lock_api" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "owning_ref 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)", + "scopeguard 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "lock_api" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "scopeguard 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "log" +version = "0.4.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "cfg-if 0.1.9 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "mashup" +version = "0.1.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "mashup-impl 0.1.9 (registry+https://github.com/rust-lang/crates.io-index)", + "proc-macro-hack 0.4.1 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "mashup-impl" +version = "0.1.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "proc-macro-hack 0.4.1 (registry+https://github.com/rust-lang/crates.io-index)", + "proc-macro2 0.4.30 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "matches" +version = "0.1.8" +source = "registry+https://github.com/rust-lang/crates.io-index" + +[[package]] +name = "memchr" +version = "2.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "libc 0.2.58 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "memoffset" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" + +[[package]] +name = "mime" +version = "0.3.13" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "unicase 2.4.0 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "mime_guess" +version = "2.0.0-alpha.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "mime 0.3.13 (registry+https://github.com/rust-lang/crates.io-index)", + "phf 0.7.24 (registry+https://github.com/rust-lang/crates.io-index)", + "phf_codegen 0.7.24 (registry+https://github.com/rust-lang/crates.io-index)", + "unicase 1.4.2 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "miniz_oxide" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "adler32 1.0.3 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "miniz_oxide_c_api" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "cc 1.0.37 (registry+https://github.com/rust-lang/crates.io-index)", + "crc32fast 1.2.0 (registry+https://github.com/rust-lang/crates.io-index)", + "libc 0.2.58 (registry+https://github.com/rust-lang/crates.io-index)", + "miniz_oxide 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "mio" +version = "0.6.19" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "fuchsia-zircon 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)", + "fuchsia-zircon-sys 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)", + "iovec 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)", + "kernel32-sys 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)", + "libc 0.2.58 (registry+https://github.com/rust-lang/crates.io-index)", + "log 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)", + "miow 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)", + "net2 0.2.33 (registry+https://github.com/rust-lang/crates.io-index)", + "slab 0.4.2 (registry+https://github.com/rust-lang/crates.io-index)", + "winapi 0.2.8 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "miow" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "kernel32-sys 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)", + "net2 0.2.33 (registry+https://github.com/rust-lang/crates.io-index)", + "winapi 0.2.8 (registry+https://github.com/rust-lang/crates.io-index)", + "ws2_32-sys 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "native-tls" +version = "0.2.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "lazy_static 1.3.0 (registry+https://github.com/rust-lang/crates.io-index)", + "libc 0.2.58 (registry+https://github.com/rust-lang/crates.io-index)", + "log 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)", + "openssl 0.10.23 (registry+https://github.com/rust-lang/crates.io-index)", + "openssl-probe 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)", + "openssl-sys 0.9.47 (registry+https://github.com/rust-lang/crates.io-index)", + "schannel 0.1.15 (registry+https://github.com/rust-lang/crates.io-index)", + "security-framework 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)", + "security-framework-sys 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)", + "tempfile 3.1.0 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "net2" +version = "0.2.33" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "cfg-if 0.1.9 (registry+https://github.com/rust-lang/crates.io-index)", + "libc 0.2.58 (registry+https://github.com/rust-lang/crates.io-index)", + "winapi 0.3.7 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "nodrop" +version = "0.1.13" +source = "registry+https://github.com/rust-lang/crates.io-index" + +[[package]] +name = "num-traits" +version = "0.2.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "autocfg 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "num_cpus" +version = "1.10.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "libc 0.2.58 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "number_prefix" +version = "0.2.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "num-traits 0.2.8 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "numtoa" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" + +[[package]] +name = "opaque-debug" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" + +[[package]] +name = "openssl" +version = "0.10.23" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "bitflags 1.1.0 (registry+https://github.com/rust-lang/crates.io-index)", + "cfg-if 0.1.9 (registry+https://github.com/rust-lang/crates.io-index)", + "foreign-types 0.3.2 (registry+https://github.com/rust-lang/crates.io-index)", + "lazy_static 1.3.0 (registry+https://github.com/rust-lang/crates.io-index)", + "libc 0.2.58 (registry+https://github.com/rust-lang/crates.io-index)", + "openssl-sys 0.9.47 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "openssl-probe" +version = "0.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" + +[[package]] +name = "openssl-sys" +version = "0.9.47" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "autocfg 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)", + "cc 1.0.37 (registry+https://github.com/rust-lang/crates.io-index)", + "libc 0.2.58 (registry+https://github.com/rust-lang/crates.io-index)", + "pkg-config 0.3.14 (registry+https://github.com/rust-lang/crates.io-index)", + "vcpkg 0.2.7 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "owning_ref" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "stable_deref_trait 1.1.1 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "parking_lot" +version = "0.7.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "lock_api 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)", + "parking_lot_core 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "parking_lot" +version = "0.8.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "lock_api 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)", + "parking_lot_core 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)", + "rustc_version 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "parking_lot_core" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "libc 0.2.58 (registry+https://github.com/rust-lang/crates.io-index)", + "rand 0.6.5 (registry+https://github.com/rust-lang/crates.io-index)", + "rustc_version 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)", + "smallvec 0.6.10 (registry+https://github.com/rust-lang/crates.io-index)", + "winapi 0.3.7 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "parking_lot_core" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "cfg-if 0.1.9 (registry+https://github.com/rust-lang/crates.io-index)", + "cloudabi 0.0.3 (registry+https://github.com/rust-lang/crates.io-index)", + "libc 0.2.58 (registry+https://github.com/rust-lang/crates.io-index)", + "rand 0.6.5 (registry+https://github.com/rust-lang/crates.io-index)", + "redox_syscall 0.1.54 (registry+https://github.com/rust-lang/crates.io-index)", + "rustc_version 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)", + "smallvec 0.6.10 (registry+https://github.com/rust-lang/crates.io-index)", + "winapi 0.3.7 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "pdqselect" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" + +[[package]] +name = "percent-encoding" +version = "1.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" + +[[package]] +name = "permutohedron" +version = "0.2.4" +source = "registry+https://github.com/rust-lang/crates.io-index" + +[[package]] +name = "phf" +version = "0.7.24" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "phf_shared 0.7.24 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "phf_codegen" +version = "0.7.24" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "phf_generator 0.7.24 (registry+https://github.com/rust-lang/crates.io-index)", + "phf_shared 0.7.24 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "phf_generator" +version = "0.7.24" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "phf_shared 0.7.24 (registry+https://github.com/rust-lang/crates.io-index)", + "rand 0.6.5 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "phf_shared" +version = "0.7.24" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "siphasher 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)", + "unicase 1.4.2 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "pkg-config" +version = "0.3.14" +source = "registry+https://github.com/rust-lang/crates.io-index" + +[[package]] +name = "ppv-lite86" +version = "0.2.5" +source = "registry+https://github.com/rust-lang/crates.io-index" + +[[package]] +name = "proc-macro-hack" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "proc-macro-hack-impl 0.4.1 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "proc-macro-hack-impl" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" + +[[package]] +name = "proc-macro2" +version = "0.4.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "unicode-xid 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "publicsuffix" +version = "1.5.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "error-chain 0.12.1 (registry+https://github.com/rust-lang/crates.io-index)", + "idna 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)", + "lazy_static 1.3.0 (registry+https://github.com/rust-lang/crates.io-index)", + "regex 1.1.7 (registry+https://github.com/rust-lang/crates.io-index)", + "url 1.7.2 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "pyo3" +version = "0.7.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "inventory 0.1.3 (registry+https://github.com/rust-lang/crates.io-index)", + "libc 0.2.58 (registry+https://github.com/rust-lang/crates.io-index)", + "mashup 0.1.9 (registry+https://github.com/rust-lang/crates.io-index)", + "num-traits 0.2.8 (registry+https://github.com/rust-lang/crates.io-index)", + "pyo3cls 0.7.0 (registry+https://github.com/rust-lang/crates.io-index)", + "regex 1.1.7 (registry+https://github.com/rust-lang/crates.io-index)", + "spin 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)", + "version_check 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "pyo3-derive-backend" +version = "0.7.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "proc-macro2 0.4.30 (registry+https://github.com/rust-lang/crates.io-index)", + "quote 0.6.12 (registry+https://github.com/rust-lang/crates.io-index)", + "syn 0.15.39 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "pyo3cls" +version = "0.7.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "proc-macro2 0.4.30 (registry+https://github.com/rust-lang/crates.io-index)", + "pyo3-derive-backend 0.7.0 (registry+https://github.com/rust-lang/crates.io-index)", + "quote 0.6.12 (registry+https://github.com/rust-lang/crates.io-index)", + "syn 0.15.39 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "quick-error" +version = "1.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" + +[[package]] +name = "quote" +version = "0.6.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "proc-macro2 0.4.30 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "rand" +version = "0.6.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "autocfg 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)", + "libc 0.2.58 (registry+https://github.com/rust-lang/crates.io-index)", + "rand_chacha 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)", + "rand_core 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)", + "rand_hc 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)", + "rand_isaac 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)", + "rand_jitter 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)", + "rand_os 0.1.3 (registry+https://github.com/rust-lang/crates.io-index)", + "rand_pcg 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)", + "rand_xorshift 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)", + "winapi 0.3.7 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "rand" +version = "0.7.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "getrandom 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)", + "libc 0.2.58 (registry+https://github.com/rust-lang/crates.io-index)", + "rand_chacha 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)", + "rand_core 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)", + "rand_hc 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "rand_chacha" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "autocfg 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)", + "rand_core 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "rand_chacha" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "autocfg 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)", + "c2-chacha 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)", + "rand_core 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "rand_core" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "rand_core 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "rand_core" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" + +[[package]] +name = "rand_core" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "getrandom 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "rand_hc" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "rand_core 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "rand_hc" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "rand_core 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "rand_isaac" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "rand_core 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "rand_jitter" +version = "0.1.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "libc 0.2.58 (registry+https://github.com/rust-lang/crates.io-index)", + "rand_core 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)", + "winapi 0.3.7 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "rand_os" +version = "0.1.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "cloudabi 0.0.3 (registry+https://github.com/rust-lang/crates.io-index)", + "fuchsia-cprng 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)", + "libc 0.2.58 (registry+https://github.com/rust-lang/crates.io-index)", + "rand_core 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)", + "rdrand 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)", + "winapi 0.3.7 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "rand_pcg" +version = "0.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "autocfg 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)", + "rand_core 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "rand_xorshift" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "rand_core 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "rdrand" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "rand_core 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "redox_syscall" +version = "0.1.54" +source = "registry+https://github.com/rust-lang/crates.io-index" + +[[package]] +name = "redox_termios" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "redox_syscall 0.1.54 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "regex" +version = "1.1.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "aho-corasick 0.7.3 (registry+https://github.com/rust-lang/crates.io-index)", + "memchr 2.2.0 (registry+https://github.com/rust-lang/crates.io-index)", + "regex-syntax 0.6.7 (registry+https://github.com/rust-lang/crates.io-index)", + "thread_local 0.3.6 (registry+https://github.com/rust-lang/crates.io-index)", + "utf8-ranges 1.0.3 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "regex-automata" +version = "0.1.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "byteorder 1.3.2 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "regex-syntax" +version = "0.6.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "ucd-util 0.1.3 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "remove_dir_all" +version = "0.5.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "winapi 0.3.7 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "reqwest" +version = "0.9.18" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "base64 0.10.1 (registry+https://github.com/rust-lang/crates.io-index)", + "bytes 0.4.12 (registry+https://github.com/rust-lang/crates.io-index)", + "cookie 0.12.0 (registry+https://github.com/rust-lang/crates.io-index)", + "cookie_store 0.7.0 (registry+https://github.com/rust-lang/crates.io-index)", + "encoding_rs 0.8.17 (registry+https://github.com/rust-lang/crates.io-index)", + "flate2 1.0.9 (registry+https://github.com/rust-lang/crates.io-index)", + "futures 0.1.28 (registry+https://github.com/rust-lang/crates.io-index)", + "http 0.1.17 (registry+https://github.com/rust-lang/crates.io-index)", + "hyper 0.12.31 (registry+https://github.com/rust-lang/crates.io-index)", + "hyper-tls 0.3.2 (registry+https://github.com/rust-lang/crates.io-index)", + "log 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)", + "mime 0.3.13 (registry+https://github.com/rust-lang/crates.io-index)", + "mime_guess 2.0.0-alpha.6 (registry+https://github.com/rust-lang/crates.io-index)", + "native-tls 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)", + "serde 1.0.94 (registry+https://github.com/rust-lang/crates.io-index)", + "serde_json 1.0.40 (registry+https://github.com/rust-lang/crates.io-index)", + "serde_urlencoded 0.5.5 (registry+https://github.com/rust-lang/crates.io-index)", + "time 0.1.42 (registry+https://github.com/rust-lang/crates.io-index)", + "tokio 0.1.22 (registry+https://github.com/rust-lang/crates.io-index)", + "tokio-executor 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)", + "tokio-io 0.1.12 (registry+https://github.com/rust-lang/crates.io-index)", + "tokio-threadpool 0.1.15 (registry+https://github.com/rust-lang/crates.io-index)", + "tokio-timer 0.2.11 (registry+https://github.com/rust-lang/crates.io-index)", + "url 1.7.2 (registry+https://github.com/rust-lang/crates.io-index)", + "uuid 0.7.4 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "rstar" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "itertools 0.8.0 (registry+https://github.com/rust-lang/crates.io-index)", + "num-traits 0.2.8 (registry+https://github.com/rust-lang/crates.io-index)", + "pdqselect 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "rustc-demangle" +version = "0.1.15" +source = "registry+https://github.com/rust-lang/crates.io-index" + +[[package]] +name = "rustc_version" +version = "0.2.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "semver 0.9.0 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "ryu" +version = "1.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" + +[[package]] +name = "schannel" +version = "0.1.15" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "lazy_static 1.3.0 (registry+https://github.com/rust-lang/crates.io-index)", + "winapi 0.3.7 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "scopeguard" +version = "0.3.3" +source = "registry+https://github.com/rust-lang/crates.io-index" + +[[package]] +name = "scopeguard" +version = "1.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" + +[[package]] +name = "security-framework" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "core-foundation 0.6.4 (registry+https://github.com/rust-lang/crates.io-index)", + "core-foundation-sys 0.6.2 (registry+https://github.com/rust-lang/crates.io-index)", + "libc 0.2.58 (registry+https://github.com/rust-lang/crates.io-index)", + "security-framework-sys 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "security-framework-sys" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "core-foundation-sys 0.6.2 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "semver" +version = "0.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "semver-parser 0.7.0 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "semver-parser" +version = "0.7.0" +source = "registry+https://github.com/rust-lang/crates.io-index" + +[[package]] +name = "serde" +version = "1.0.94" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "serde_derive 1.0.94 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "serde_derive" +version = "1.0.94" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "proc-macro2 0.4.30 (registry+https://github.com/rust-lang/crates.io-index)", + "quote 0.6.12 (registry+https://github.com/rust-lang/crates.io-index)", + "syn 0.15.39 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "serde_json" +version = "1.0.40" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "itoa 0.4.4 (registry+https://github.com/rust-lang/crates.io-index)", + "ryu 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)", + "serde 1.0.94 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "serde_urlencoded" +version = "0.5.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "dtoa 0.4.4 (registry+https://github.com/rust-lang/crates.io-index)", + "itoa 0.4.4 (registry+https://github.com/rust-lang/crates.io-index)", + "serde 1.0.94 (registry+https://github.com/rust-lang/crates.io-index)", + "url 1.7.2 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "sha3" +version = "0.8.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "block-buffer 0.7.3 (registry+https://github.com/rust-lang/crates.io-index)", + "byte-tools 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)", + "digest 0.8.0 (registry+https://github.com/rust-lang/crates.io-index)", + "keccak 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)", + "opaque-debug 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "siphasher" +version = "0.2.3" +source = "registry+https://github.com/rust-lang/crates.io-index" + +[[package]] +name = "slab" +version = "0.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" + +[[package]] +name = "smallvec" +version = "0.6.10" +source = "registry+https://github.com/rust-lang/crates.io-index" + +[[package]] +name = "spin" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" + +[[package]] +name = "stable_deref_trait" +version = "1.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" + +[[package]] +name = "string" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "bytes 0.4.12 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "strsim" +version = "0.8.0" +source = "registry+https://github.com/rust-lang/crates.io-index" + +[[package]] +name = "structopt" +version = "0.2.18" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "clap 2.33.0 (registry+https://github.com/rust-lang/crates.io-index)", + "structopt-derive 0.2.18 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "structopt-derive" +version = "0.2.18" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "heck 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)", + "proc-macro2 0.4.30 (registry+https://github.com/rust-lang/crates.io-index)", + "quote 0.6.12 (registry+https://github.com/rust-lang/crates.io-index)", + "syn 0.15.39 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "syn" +version = "0.15.39" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "proc-macro2 0.4.30 (registry+https://github.com/rust-lang/crates.io-index)", + "quote 0.6.12 (registry+https://github.com/rust-lang/crates.io-index)", + "unicode-xid 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "synstructure" +version = "0.10.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "proc-macro2 0.4.30 (registry+https://github.com/rust-lang/crates.io-index)", + "quote 0.6.12 (registry+https://github.com/rust-lang/crates.io-index)", + "syn 0.15.39 (registry+https://github.com/rust-lang/crates.io-index)", + "unicode-xid 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "tempfile" +version = "3.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "cfg-if 0.1.9 (registry+https://github.com/rust-lang/crates.io-index)", + "libc 0.2.58 (registry+https://github.com/rust-lang/crates.io-index)", + "rand 0.7.0 (registry+https://github.com/rust-lang/crates.io-index)", + "redox_syscall 0.1.54 (registry+https://github.com/rust-lang/crates.io-index)", + "remove_dir_all 0.5.2 (registry+https://github.com/rust-lang/crates.io-index)", + "winapi 0.3.7 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "termion" +version = "1.5.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "libc 0.2.58 (registry+https://github.com/rust-lang/crates.io-index)", + "numtoa 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)", + "redox_syscall 0.1.54 (registry+https://github.com/rust-lang/crates.io-index)", + "redox_termios 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "termios" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "libc 0.2.58 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "textwrap" +version = "0.11.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "unicode-width 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "thread_local" +version = "0.3.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "lazy_static 1.3.0 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "time" +version = "0.1.42" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "libc 0.2.58 (registry+https://github.com/rust-lang/crates.io-index)", + "redox_syscall 0.1.54 (registry+https://github.com/rust-lang/crates.io-index)", + "winapi 0.3.7 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "tokio" +version = "0.1.22" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "bytes 0.4.12 (registry+https://github.com/rust-lang/crates.io-index)", + "futures 0.1.28 (registry+https://github.com/rust-lang/crates.io-index)", + "mio 0.6.19 (registry+https://github.com/rust-lang/crates.io-index)", + "num_cpus 1.10.1 (registry+https://github.com/rust-lang/crates.io-index)", + "tokio-current-thread 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)", + "tokio-executor 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)", + "tokio-io 0.1.12 (registry+https://github.com/rust-lang/crates.io-index)", + "tokio-reactor 0.1.9 (registry+https://github.com/rust-lang/crates.io-index)", + "tokio-tcp 0.1.3 (registry+https://github.com/rust-lang/crates.io-index)", + "tokio-threadpool 0.1.15 (registry+https://github.com/rust-lang/crates.io-index)", + "tokio-timer 0.2.11 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "tokio-buf" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "bytes 0.4.12 (registry+https://github.com/rust-lang/crates.io-index)", + "either 1.5.2 (registry+https://github.com/rust-lang/crates.io-index)", + "futures 0.1.28 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "tokio-current-thread" +version = "0.1.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "futures 0.1.28 (registry+https://github.com/rust-lang/crates.io-index)", + "tokio-executor 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "tokio-executor" +version = "0.1.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "crossbeam-utils 0.6.5 (registry+https://github.com/rust-lang/crates.io-index)", + "futures 0.1.28 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "tokio-io" +version = "0.1.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "bytes 0.4.12 (registry+https://github.com/rust-lang/crates.io-index)", + "futures 0.1.28 (registry+https://github.com/rust-lang/crates.io-index)", + "log 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "tokio-reactor" +version = "0.1.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "crossbeam-utils 0.6.5 (registry+https://github.com/rust-lang/crates.io-index)", + "futures 0.1.28 (registry+https://github.com/rust-lang/crates.io-index)", + "lazy_static 1.3.0 (registry+https://github.com/rust-lang/crates.io-index)", + "log 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)", + "mio 0.6.19 (registry+https://github.com/rust-lang/crates.io-index)", + "num_cpus 1.10.1 (registry+https://github.com/rust-lang/crates.io-index)", + "parking_lot 0.7.1 (registry+https://github.com/rust-lang/crates.io-index)", + "slab 0.4.2 (registry+https://github.com/rust-lang/crates.io-index)", + "tokio-executor 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)", + "tokio-io 0.1.12 (registry+https://github.com/rust-lang/crates.io-index)", + "tokio-sync 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "tokio-sync" +version = "0.1.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "fnv 1.0.6 (registry+https://github.com/rust-lang/crates.io-index)", + "futures 0.1.28 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "tokio-tcp" +version = "0.1.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "bytes 0.4.12 (registry+https://github.com/rust-lang/crates.io-index)", + "futures 0.1.28 (registry+https://github.com/rust-lang/crates.io-index)", + "iovec 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)", + "mio 0.6.19 (registry+https://github.com/rust-lang/crates.io-index)", + "tokio-io 0.1.12 (registry+https://github.com/rust-lang/crates.io-index)", + "tokio-reactor 0.1.9 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "tokio-threadpool" +version = "0.1.15" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "crossbeam-deque 0.7.1 (registry+https://github.com/rust-lang/crates.io-index)", + "crossbeam-queue 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)", + "crossbeam-utils 0.6.5 (registry+https://github.com/rust-lang/crates.io-index)", + "futures 0.1.28 (registry+https://github.com/rust-lang/crates.io-index)", + "log 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)", + "num_cpus 1.10.1 (registry+https://github.com/rust-lang/crates.io-index)", + "rand 0.6.5 (registry+https://github.com/rust-lang/crates.io-index)", + "slab 0.4.2 (registry+https://github.com/rust-lang/crates.io-index)", + "tokio-executor 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "tokio-timer" +version = "0.2.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "crossbeam-utils 0.6.5 (registry+https://github.com/rust-lang/crates.io-index)", + "futures 0.1.28 (registry+https://github.com/rust-lang/crates.io-index)", + "slab 0.4.2 (registry+https://github.com/rust-lang/crates.io-index)", + "tokio-executor 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "try-lock" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" + +[[package]] +name = "try_from" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "cfg-if 0.1.9 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "typenum" +version = "1.10.0" +source = "registry+https://github.com/rust-lang/crates.io-index" + +[[package]] +name = "ucd-util" +version = "0.1.3" +source = "registry+https://github.com/rust-lang/crates.io-index" + +[[package]] +name = "unicase" +version = "1.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "version_check 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "unicase" +version = "2.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "version_check 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "unicode-bidi" +version = "0.3.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "matches 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "unicode-normalization" +version = "0.1.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "smallvec 0.6.10 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "unicode-segmentation" +version = "1.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" + +[[package]] +name = "unicode-width" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" + +[[package]] +name = "unicode-xid" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" + +[[package]] +name = "url" +version = "1.7.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "idna 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)", + "matches 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)", + "percent-encoding 1.0.1 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "utf8-ranges" +version = "1.0.3" +source = "registry+https://github.com/rust-lang/crates.io-index" + +[[package]] +name = "uuid" +version = "0.7.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "rand 0.6.5 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "vcpkg" +version = "0.2.7" +source = "registry+https://github.com/rust-lang/crates.io-index" + +[[package]] +name = "vec_map" +version = "0.8.1" +source = "registry+https://github.com/rust-lang/crates.io-index" + +[[package]] +name = "version_check" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" + +[[package]] +name = "want" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "futures 0.1.28 (registry+https://github.com/rust-lang/crates.io-index)", + "log 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)", + "try-lock 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "winapi" +version = "0.2.8" +source = "registry+https://github.com/rust-lang/crates.io-index" + +[[package]] +name = "winapi" +version = "0.3.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "winapi-i686-pc-windows-gnu 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)", + "winapi-x86_64-pc-windows-gnu 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[[package]] +name = "winapi-build" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" + +[[package]] +name = "winapi-i686-pc-windows-gnu" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" + +[[package]] +name = "winapi-x86_64-pc-windows-gnu" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" + +[[package]] +name = "ws2_32-sys" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +dependencies = [ + "winapi 0.2.8 (registry+https://github.com/rust-lang/crates.io-index)", + "winapi-build 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)", +] + +[metadata] +"checksum adler32 1.0.3 (registry+https://github.com/rust-lang/crates.io-index)" = "7e522997b529f05601e05166c07ed17789691f562762c7f3b987263d2dedee5c" +"checksum aho-corasick 0.7.3 (registry+https://github.com/rust-lang/crates.io-index)" = "e6f484ae0c99fec2e858eb6134949117399f222608d84cadb3f58c1f97c2364c" +"checksum ansi_term 0.11.0 (registry+https://github.com/rust-lang/crates.io-index)" = "ee49baf6cb617b853aa8d93bf420db2383fab46d314482ca2803b40d5fde979b" +"checksum arrayvec 0.4.10 (registry+https://github.com/rust-lang/crates.io-index)" = "92c7fb76bc8826a8b33b4ee5bb07a247a81e76764ab4d55e8f73e3a4d8808c71" +"checksum atty 0.2.11 (registry+https://github.com/rust-lang/crates.io-index)" = "9a7d5b8723950951411ee34d271d99dddcc2035a16ab25310ea2c8cfd4369652" +"checksum autocfg 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)" = "0e49efa51329a5fd37e7c79db4621af617cd4e3e5bc224939808d076077077bf" +"checksum backtrace 0.3.32 (registry+https://github.com/rust-lang/crates.io-index)" = "18b50f5258d1a9ad8396d2d345827875de4261b158124d4c819d9b351454fae5" +"checksum backtrace-sys 0.1.30 (registry+https://github.com/rust-lang/crates.io-index)" = "5b3a000b9c543553af61bc01cbfc403b04b5caa9e421033866f2e98061eb3e61" +"checksum base64 0.10.1 (registry+https://github.com/rust-lang/crates.io-index)" = "0b25d992356d2eb0ed82172f5248873db5560c4721f564b13cb5193bda5e668e" +"checksum bincode 1.1.4 (registry+https://github.com/rust-lang/crates.io-index)" = "9f04a5e50dc80b3d5d35320889053637d15011aed5e66b66b37ae798c65da6f7" +"checksum bitflags 1.1.0 (registry+https://github.com/rust-lang/crates.io-index)" = "3d155346769a6855b86399e9bc3814ab343cd3d62c7e985113d46a0ec3c281fd" +"checksum block-buffer 0.7.3 (registry+https://github.com/rust-lang/crates.io-index)" = "c0940dc441f31689269e10ac70eb1002a3a1d3ad1390e030043662eb7fe4688b" +"checksum block-padding 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)" = "6d4dc3af3ee2e12f3e5d224e5e1e3d73668abbeb69e566d361f7d5563a4fdf09" +"checksum bstr 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)" = "6cc0572e02f76cb335f309b19e0a0d585b4f62788f7d26de2a13a836a637385f" +"checksum byte-tools 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)" = "e3b5ca7a04898ad4bcd41c90c5285445ff5b791899bb1b0abdd2a2aa791211d7" +"checksum byteorder 1.3.2 (registry+https://github.com/rust-lang/crates.io-index)" = "a7c3dd8985a7111efc5c80b44e23ecdd8c007de8ade3b96595387e812b957cf5" +"checksum bytes 0.4.12 (registry+https://github.com/rust-lang/crates.io-index)" = "206fdffcfa2df7cbe15601ef46c813fce0965eb3286db6b56c583b814b51c81c" +"checksum c2-chacha 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)" = "7d64d04786e0f528460fc884753cf8dddcc466be308f6026f8e355c41a0e4101" +"checksum cc 1.0.37 (registry+https://github.com/rust-lang/crates.io-index)" = "39f75544d7bbaf57560d2168f28fd649ff9c76153874db88bdbdfd839b1a7e7d" +"checksum cfg-if 0.1.9 (registry+https://github.com/rust-lang/crates.io-index)" = "b486ce3ccf7ffd79fdeb678eac06a9e6c09fc88d33836340becb8fffe87c5e33" +"checksum clap 2.33.0 (registry+https://github.com/rust-lang/crates.io-index)" = "5067f5bb2d80ef5d68b4c87db81601f0b75bca627bc2ef76b141d7b846a3c6d9" +"checksum clicolors-control 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)" = "73abfd4c73d003a674ce5d2933fca6ce6c42480ea84a5ffe0a2dc39ed56300f9" +"checksum cloudabi 0.0.3 (registry+https://github.com/rust-lang/crates.io-index)" = "ddfc5b9aa5d4507acaf872de71051dfd0e309860e88966e1051e462a077aac4f" +"checksum console 0.7.7 (registry+https://github.com/rust-lang/crates.io-index)" = "8ca57c2c14b8a2bf3105bc9d15574aad80babf6a9c44b1058034cdf8bd169628" +"checksum cookie 0.12.0 (registry+https://github.com/rust-lang/crates.io-index)" = "888604f00b3db336d2af898ec3c1d5d0ddf5e6d462220f2ededc33a87ac4bbd5" +"checksum cookie_store 0.7.0 (registry+https://github.com/rust-lang/crates.io-index)" = "46750b3f362965f197996c4448e4a0935e791bf7d6631bfce9ee0af3d24c919c" +"checksum core-foundation 0.6.4 (registry+https://github.com/rust-lang/crates.io-index)" = "25b9e03f145fd4f2bf705e07b900cd41fc636598fe5dc452fd0db1441c3f496d" +"checksum core-foundation-sys 0.6.2 (registry+https://github.com/rust-lang/crates.io-index)" = "e7ca8a5221364ef15ce201e8ed2f609fc312682a8f4e0e3d4aa5879764e0fa3b" +"checksum crc32fast 1.2.0 (registry+https://github.com/rust-lang/crates.io-index)" = "ba125de2af0df55319f41944744ad91c71113bf74a4646efff39afe1f6842db1" +"checksum crossbeam-deque 0.7.1 (registry+https://github.com/rust-lang/crates.io-index)" = "b18cd2e169ad86297e6bc0ad9aa679aee9daa4f19e8163860faf7c164e4f5a71" +"checksum crossbeam-epoch 0.7.1 (registry+https://github.com/rust-lang/crates.io-index)" = "04c9e3102cc2d69cd681412141b390abd55a362afc1540965dad0ad4d34280b4" +"checksum crossbeam-queue 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)" = "7c979cd6cfe72335896575c6b5688da489e420d36a27a0b9eb0c73db574b4a4b" +"checksum crossbeam-utils 0.6.5 (registry+https://github.com/rust-lang/crates.io-index)" = "f8306fcef4a7b563b76b7dd949ca48f52bc1141aa067d2ea09565f3e2652aa5c" +"checksum csv 1.1.1 (registry+https://github.com/rust-lang/crates.io-index)" = "37519ccdfd73a75821cac9319d4fce15a81b9fcf75f951df5b9988aa3a0af87d" +"checksum csv-core 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)" = "9b5cadb6b25c77aeff80ba701712494213f4a8418fcda2ee11b6560c3ad0bf4c" +"checksum ctor 0.1.9 (registry+https://github.com/rust-lang/crates.io-index)" = "3b4c17619643c1252b5f690084b82639dd7fac141c57c8e77a00e0148132092c" +"checksum digest 0.8.0 (registry+https://github.com/rust-lang/crates.io-index)" = "05f47366984d3ad862010e22c7ce81a7dbcaebbdfb37241a620f8b6596ee135c" +"checksum dtoa 0.4.4 (registry+https://github.com/rust-lang/crates.io-index)" = "ea57b42383d091c85abcc2706240b94ab2a8fa1fc81c10ff23c4de06e2a90b5e" +"checksum either 1.5.2 (registry+https://github.com/rust-lang/crates.io-index)" = "5527cfe0d098f36e3f8839852688e63c8fff1c90b2b405aef730615f9a7bcf7b" +"checksum encode_unicode 0.3.5 (registry+https://github.com/rust-lang/crates.io-index)" = "90b2c9496c001e8cb61827acdefad780795c42264c137744cae6f7d9e3450abd" +"checksum encoding_rs 0.8.17 (registry+https://github.com/rust-lang/crates.io-index)" = "4155785c79f2f6701f185eb2e6b4caf0555ec03477cb4c70db67b465311620ed" +"checksum error-chain 0.12.1 (registry+https://github.com/rust-lang/crates.io-index)" = "3ab49e9dcb602294bc42f9a7dfc9bc6e936fca4418ea300dbfb84fe16de0b7d9" +"checksum failure 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)" = "795bd83d3abeb9220f257e597aa0080a508b27533824adf336529648f6abf7e2" +"checksum failure_derive 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)" = "ea1063915fd7ef4309e222a5a07cf9c319fb9c7836b1f89b85458672dbb127e1" +"checksum flate2 1.0.9 (registry+https://github.com/rust-lang/crates.io-index)" = "550934ad4808d5d39365e5d61727309bf18b3b02c6c56b729cb92e7dd84bc3d8" +"checksum fnv 1.0.6 (registry+https://github.com/rust-lang/crates.io-index)" = "2fad85553e09a6f881f739c29f0b00b0f01357c743266d478b68951ce23285f3" +"checksum foreign-types 0.3.2 (registry+https://github.com/rust-lang/crates.io-index)" = "f6f339eb8adc052cd2ca78910fda869aefa38d22d5cb648e6485e4d3fc06f3b1" +"checksum foreign-types-shared 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)" = "00b0228411908ca8685dba7fc2cdd70ec9990a6e753e89b6ac91a84c40fbaf4b" +"checksum fuchsia-cprng 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)" = "a06f77d526c1a601b7c4cdd98f54b5eaabffc14d5f2f0296febdc7f357c6d3ba" +"checksum fuchsia-zircon 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)" = "2e9763c69ebaae630ba35f74888db465e49e259ba1bc0eda7d06f4a067615d82" +"checksum fuchsia-zircon-sys 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)" = "3dcaa9ae7725d12cdb85b3ad99a434db70b468c09ded17e012d86b5c1010f7a7" +"checksum futures 0.1.28 (registry+https://github.com/rust-lang/crates.io-index)" = "45dc39533a6cae6da2b56da48edae506bb767ec07370f86f70fc062e9d435869" +"checksum futures-cpupool 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)" = "ab90cde24b3319636588d0c35fe03b1333857621051837ed769faefb4c2162e4" +"checksum generic-array 0.12.3 (registry+https://github.com/rust-lang/crates.io-index)" = "c68f0274ae0e023facc3c97b2e00f076be70e254bc851d972503b328db79b2ec" +"checksum getrandom 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)" = "e65cce4e5084b14874c4e7097f38cab54f47ee554f9194673456ea379dcc4c55" +"checksum ghost 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)" = "5297b71943dc9fea26a3241b178c140ee215798b7f79f7773fd61683e25bca74" +"checksum h2 0.1.25 (registry+https://github.com/rust-lang/crates.io-index)" = "a539b63339fbbb00e081e84b6e11bd1d9634a82d91da2984a18ac74a8823f392" +"checksum heck 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)" = "20564e78d53d2bb135c343b3f47714a56af2061f1c928fdb541dc7b9fdd94205" +"checksum http 0.1.17 (registry+https://github.com/rust-lang/crates.io-index)" = "eed324f0f0daf6ec10c474f150505af2c143f251722bf9dbd1261bd1f2ee2c1a" +"checksum http-body 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)" = "6741c859c1b2463a423a1dbce98d418e6c3c3fc720fb0d45528657320920292d" +"checksum httparse 1.3.4 (registry+https://github.com/rust-lang/crates.io-index)" = "cd179ae861f0c2e53da70d892f5f3029f9594be0c41dc5269cd371691b1dc2f9" +"checksum humantime 1.2.0 (registry+https://github.com/rust-lang/crates.io-index)" = "3ca7e5f2e110db35f93b837c81797f3714500b81d517bf20c431b16d3ca4f114" +"checksum hyper 0.12.31 (registry+https://github.com/rust-lang/crates.io-index)" = "6481fff8269772d4463253ca83c788104a7305cb3fb9136bc651a6211e46e03f" +"checksum hyper-tls 0.3.2 (registry+https://github.com/rust-lang/crates.io-index)" = "3a800d6aa50af4b5850b2b0f659625ce9504df908e9733b635720483be26174f" +"checksum idna 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)" = "38f09e0f0b1fb55fdee1f17470ad800da77af5186a1a76c026b679358b7e844e" +"checksum indexmap 1.0.2 (registry+https://github.com/rust-lang/crates.io-index)" = "7e81a7c05f79578dbc15793d8b619db9ba32b4577003ef3af1a91c416798c58d" +"checksum indicatif 0.11.0 (registry+https://github.com/rust-lang/crates.io-index)" = "2c60da1c9abea75996b70a931bba6c750730399005b61ccd853cee50ef3d0d0c" +"checksum inventory 0.1.3 (registry+https://github.com/rust-lang/crates.io-index)" = "21df85981fe094480bc2267723d3dc0fd1ae0d1f136affc659b7398be615d922" +"checksum inventory-impl 0.1.3 (registry+https://github.com/rust-lang/crates.io-index)" = "8a877ae8bce77402d5e9ed870730939e097aad827b2a932b361958fa9d6e75aa" +"checksum iovec 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)" = "dbe6e417e7d0975db6512b90796e8ce223145ac4e33c377e4a42882a0e88bb08" +"checksum itertools 0.8.0 (registry+https://github.com/rust-lang/crates.io-index)" = "5b8467d9c1cebe26feb08c640139247fac215782d35371ade9a2136ed6085358" +"checksum itoa 0.4.4 (registry+https://github.com/rust-lang/crates.io-index)" = "501266b7edd0174f8530248f87f99c88fbe60ca4ef3dd486835b8d8d53136f7f" +"checksum keccak 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)" = "67c21572b4949434e4fc1e1978b99c5f77064153c59d998bf13ecd96fb5ecba7" +"checksum kernel32-sys 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)" = "7507624b29483431c0ba2d82aece8ca6cdba9382bff4ddd0f7490560c056098d" +"checksum lazy_static 1.3.0 (registry+https://github.com/rust-lang/crates.io-index)" = "bc5729f27f159ddd61f4df6228e827e86643d4d3e7c32183cb30a1c08f604a14" +"checksum libc 0.2.58 (registry+https://github.com/rust-lang/crates.io-index)" = "6281b86796ba5e4366000be6e9e18bf35580adf9e63fbe2294aadb587613a319" +"checksum lock_api 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)" = "62ebf1391f6acad60e5c8b43706dde4582df75c06698ab44511d15016bc2442c" +"checksum lock_api 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)" = "ed946d4529956a20f2d63ebe1b69996d5a2137c91913fe3ebbeff957f5bca7ff" +"checksum log 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)" = "c84ec4b527950aa83a329754b01dbe3f58361d1c5efacd1f6d68c494d08a17c6" +"checksum mashup 0.1.9 (registry+https://github.com/rust-lang/crates.io-index)" = "f2d82b34c7fb11bb41719465c060589e291d505ca4735ea30016a91f6fc79c3b" +"checksum mashup-impl 0.1.9 (registry+https://github.com/rust-lang/crates.io-index)" = "aa607bfb674b4efb310512527d64266b065de3f894fc52f84efcbf7eaa5965fb" +"checksum matches 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)" = "7ffc5c5338469d4d3ea17d269fa8ea3512ad247247c30bd2df69e68309ed0a08" +"checksum memchr 2.2.0 (registry+https://github.com/rust-lang/crates.io-index)" = "2efc7bc57c883d4a4d6e3246905283d8dae951bb3bd32f49d6ef297f546e1c39" +"checksum memoffset 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)" = "0f9dc261e2b62d7a622bf416ea3c5245cdd5d9a7fcc428c0d06804dfce1775b3" +"checksum mime 0.3.13 (registry+https://github.com/rust-lang/crates.io-index)" = "3e27ca21f40a310bd06d9031785f4801710d566c184a6e15bad4f1d9b65f9425" +"checksum mime_guess 2.0.0-alpha.6 (registry+https://github.com/rust-lang/crates.io-index)" = "30de2e4613efcba1ec63d8133f344076952090c122992a903359be5a4f99c3ed" +"checksum miniz_oxide 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)" = "b6c3756d66cf286314d5f7ebe74886188a9a92f5eee68b06f31ac2b4f314c99d" +"checksum miniz_oxide_c_api 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)" = "5b78ca5446dd9fe0dab00e058731b6b08a8c1d2b9cdb8efb10876e24e9ae2494" +"checksum mio 0.6.19 (registry+https://github.com/rust-lang/crates.io-index)" = "83f51996a3ed004ef184e16818edc51fadffe8e7ca68be67f9dee67d84d0ff23" +"checksum miow 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)" = "8c1f2f3b1cf331de6896aabf6e9d55dca90356cc9960cca7eaaf408a355ae919" +"checksum native-tls 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)" = "4b2df1a4c22fd44a62147fd8f13dd0f95c9d8ca7b2610299b2a2f9cf8964274e" +"checksum net2 0.2.33 (registry+https://github.com/rust-lang/crates.io-index)" = "42550d9fb7b6684a6d404d9fa7250c2eb2646df731d1c06afc06dcee9e1bcf88" +"checksum nodrop 0.1.13 (registry+https://github.com/rust-lang/crates.io-index)" = "2f9667ddcc6cc8a43afc9b7917599d7216aa09c463919ea32c59ed6cac8bc945" +"checksum num-traits 0.2.8 (registry+https://github.com/rust-lang/crates.io-index)" = "6ba9a427cfca2be13aa6f6403b0b7e7368fe982bfa16fccc450ce74c46cd9b32" +"checksum num_cpus 1.10.1 (registry+https://github.com/rust-lang/crates.io-index)" = "bcef43580c035376c0705c42792c294b66974abbfd2789b511784023f71f3273" +"checksum number_prefix 0.2.8 (registry+https://github.com/rust-lang/crates.io-index)" = "dbf9993e59c894e3c08aa1c2712914e9e6bf1fcbfc6bef283e2183df345a4fee" +"checksum numtoa 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)" = "b8f8bdf33df195859076e54ab11ee78a1b208382d3a26ec40d142ffc1ecc49ef" +"checksum opaque-debug 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)" = "93f5bb2e8e8dec81642920ccff6b61f1eb94fa3020c5a325c9851ff604152409" +"checksum openssl 0.10.23 (registry+https://github.com/rust-lang/crates.io-index)" = "97c140cbb82f3b3468193dd14c1b88def39f341f68257f8a7fe8ed9ed3f628a5" +"checksum openssl-probe 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)" = "77af24da69f9d9341038eba93a073b1fdaaa1b788221b00a69bce9e762cb32de" +"checksum openssl-sys 0.9.47 (registry+https://github.com/rust-lang/crates.io-index)" = "75bdd6dbbb4958d38e47a1d2348847ad1eb4dc205dc5d37473ae504391865acc" +"checksum owning_ref 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)" = "49a4b8ea2179e6a2e27411d3bca09ca6dd630821cf6894c6c7c8467a8ee7ef13" +"checksum parking_lot 0.7.1 (registry+https://github.com/rust-lang/crates.io-index)" = "ab41b4aed082705d1056416ae4468b6ea99d52599ecf3169b00088d43113e337" +"checksum parking_lot 0.8.0 (registry+https://github.com/rust-lang/crates.io-index)" = "fa7767817701cce701d5585b9c4db3cdd02086398322c1d7e8bf5094a96a2ce7" +"checksum parking_lot_core 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)" = "94c8c7923936b28d546dfd14d4472eaf34c99b14e1c973a32b3e6d4eb04298c9" +"checksum parking_lot_core 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)" = "cb88cb1cb3790baa6776844f968fea3be44956cf184fa1be5a03341f5491278c" +"checksum pdqselect 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)" = "4ec91767ecc0a0bbe558ce8c9da33c068066c57ecc8bb8477ef8c1ad3ef77c27" +"checksum percent-encoding 1.0.1 (registry+https://github.com/rust-lang/crates.io-index)" = "31010dd2e1ac33d5b46a5b413495239882813e0369f8ed8a5e266f173602f831" +"checksum permutohedron 0.2.4 (registry+https://github.com/rust-lang/crates.io-index)" = "b687ff7b5da449d39e418ad391e5e08da53ec334903ddbb921db208908fc372c" +"checksum phf 0.7.24 (registry+https://github.com/rust-lang/crates.io-index)" = "b3da44b85f8e8dfaec21adae67f95d93244b2ecf6ad2a692320598dcc8e6dd18" +"checksum phf_codegen 0.7.24 (registry+https://github.com/rust-lang/crates.io-index)" = "b03e85129e324ad4166b06b2c7491ae27fe3ec353af72e72cd1654c7225d517e" +"checksum phf_generator 0.7.24 (registry+https://github.com/rust-lang/crates.io-index)" = "09364cc93c159b8b06b1f4dd8a4398984503483891b0c26b867cf431fb132662" +"checksum phf_shared 0.7.24 (registry+https://github.com/rust-lang/crates.io-index)" = "234f71a15de2288bcb7e3b6515828d22af7ec8598ee6d24c3b526fa0a80b67a0" +"checksum pkg-config 0.3.14 (registry+https://github.com/rust-lang/crates.io-index)" = "676e8eb2b1b4c9043511a9b7bea0915320d7e502b0a079fb03f9635a5252b18c" +"checksum ppv-lite86 0.2.5 (registry+https://github.com/rust-lang/crates.io-index)" = "e3cbf9f658cdb5000fcf6f362b8ea2ba154b9f146a61c7a20d647034c6b6561b" +"checksum proc-macro-hack 0.4.1 (registry+https://github.com/rust-lang/crates.io-index)" = "2c725b36c99df7af7bf9324e9c999b9e37d92c8f8caf106d82e1d7953218d2d8" +"checksum proc-macro-hack-impl 0.4.1 (registry+https://github.com/rust-lang/crates.io-index)" = "2b753ad9ed99dd8efeaa7d2fb8453c8f6bc3e54b97966d35f1bc77ca6865254a" +"checksum proc-macro2 0.4.30 (registry+https://github.com/rust-lang/crates.io-index)" = "cf3d2011ab5c909338f7887f4fc896d35932e29146c12c8d01da6b22a80ba759" +"checksum publicsuffix 1.5.2 (registry+https://github.com/rust-lang/crates.io-index)" = "5afecba86dcf1e4fd610246f89899d1924fe12e1e89f555eb7c7f710f3c5ad1d" +"checksum pyo3 0.7.0 (registry+https://github.com/rust-lang/crates.io-index)" = "d09e6e2d3fa5ae1a8af694f865e03e763e730768b16e3097851ff0b7f2276086" +"checksum pyo3-derive-backend 0.7.0 (registry+https://github.com/rust-lang/crates.io-index)" = "d9d7ae8ab3017515cd7c82d88ce49b55e12a56c602dc69993e123da45c91b186" +"checksum pyo3cls 0.7.0 (registry+https://github.com/rust-lang/crates.io-index)" = "c494f8161f5b73096cc50f00fbb90fe670f476cde5e59c1decff39b546d54f40" +"checksum quick-error 1.2.2 (registry+https://github.com/rust-lang/crates.io-index)" = "9274b940887ce9addde99c4eee6b5c44cc494b182b97e73dc8ffdcb3397fd3f0" +"checksum quote 0.6.12 (registry+https://github.com/rust-lang/crates.io-index)" = "faf4799c5d274f3868a4aae320a0a182cbd2baee377b378f080e16a23e9d80db" +"checksum rand 0.6.5 (registry+https://github.com/rust-lang/crates.io-index)" = "6d71dacdc3c88c1fde3885a3be3fbab9f35724e6ce99467f7d9c5026132184ca" +"checksum rand 0.7.0 (registry+https://github.com/rust-lang/crates.io-index)" = "d47eab0e83d9693d40f825f86948aa16eff6750ead4bdffc4ab95b8b3a7f052c" +"checksum rand_chacha 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)" = "556d3a1ca6600bfcbab7c7c91ccb085ac7fbbcd70e008a98742e7847f4f7bcef" +"checksum rand_chacha 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)" = "e193067942ef6f485a349a113329140d0ab9e2168ce92274499bb0e9a4190d9d" +"checksum rand_core 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)" = "7a6fdeb83b075e8266dcc8762c22776f6877a63111121f5f8c7411e5be7eed4b" +"checksum rand_core 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)" = "d0e7a549d590831370895ab7ba4ea0c1b6b011d106b5ff2da6eee112615e6dc0" +"checksum rand_core 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)" = "615e683324e75af5d43d8f7a39ffe3ee4a9dc42c5c701167a71dc59c3a493aca" +"checksum rand_hc 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)" = "7b40677c7be09ae76218dc623efbf7b18e34bced3f38883af07bb75630a21bc4" +"checksum rand_hc 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)" = "ca3129af7b92a17112d59ad498c6f81eaf463253766b90396d39ea7a39d6613c" +"checksum rand_isaac 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)" = "ded997c9d5f13925be2a6fd7e66bf1872597f759fd9dd93513dd7e92e5a5ee08" +"checksum rand_jitter 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)" = "1166d5c91dc97b88d1decc3285bb0a99ed84b05cfd0bc2341bdf2d43fc41e39b" +"checksum rand_os 0.1.3 (registry+https://github.com/rust-lang/crates.io-index)" = "7b75f676a1e053fc562eafbb47838d67c84801e38fc1ba459e8f180deabd5071" +"checksum rand_pcg 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)" = "abf9b09b01790cfe0364f52bf32995ea3c39f4d2dd011eac241d2914146d0b44" +"checksum rand_xorshift 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)" = "cbf7e9e623549b0e21f6e97cf8ecf247c1a8fd2e8a992ae265314300b2455d5c" +"checksum rdrand 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)" = "678054eb77286b51581ba43620cc911abf02758c91f93f479767aed0f90458b2" +"checksum redox_syscall 0.1.54 (registry+https://github.com/rust-lang/crates.io-index)" = "12229c14a0f65c4f1cb046a3b52047cdd9da1f4b30f8a39c5063c8bae515e252" +"checksum redox_termios 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)" = "7e891cfe48e9100a70a3b6eb652fef28920c117d366339687bd5576160db0f76" +"checksum regex 1.1.7 (registry+https://github.com/rust-lang/crates.io-index)" = "0b2f0808e7d7e4fb1cb07feb6ff2f4bc827938f24f8c2e6a3beb7370af544bdd" +"checksum regex-automata 0.1.7 (registry+https://github.com/rust-lang/crates.io-index)" = "3ed09217220c272b29ef237a974ad58515bde75f194e3ffa7e6d0bf0f3b01f86" +"checksum regex-syntax 0.6.7 (registry+https://github.com/rust-lang/crates.io-index)" = "9d76410686f9e3a17f06128962e0ecc5755870bb890c34820c7af7f1db2e1d48" +"checksum remove_dir_all 0.5.2 (registry+https://github.com/rust-lang/crates.io-index)" = "4a83fa3702a688b9359eccba92d153ac33fd2e8462f9e0e3fdf155239ea7792e" +"checksum reqwest 0.9.18 (registry+https://github.com/rust-lang/crates.io-index)" = "00eb63f212df0e358b427f0f40aa13aaea010b470be642ad422bcbca2feff2e4" +"checksum rstar 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)" = "dd08ae4f9661517777346592956ea6cdbba2895a28037af7daa600382f4b4001" +"checksum rustc-demangle 0.1.15 (registry+https://github.com/rust-lang/crates.io-index)" = "a7f4dccf6f4891ebcc0c39f9b6eb1a83b9bf5d747cb439ec6fba4f3b977038af" +"checksum rustc_version 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)" = "138e3e0acb6c9fb258b19b67cb8abd63c00679d2851805ea151465464fe9030a" +"checksum ryu 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)" = "c92464b447c0ee8c4fb3824ecc8383b81717b9f1e74ba2e72540aef7b9f82997" +"checksum schannel 0.1.15 (registry+https://github.com/rust-lang/crates.io-index)" = "f2f6abf258d99c3c1c5c2131d99d064e94b7b3dd5f416483057f308fea253339" +"checksum scopeguard 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)" = "94258f53601af11e6a49f722422f6e3425c52b06245a5cf9bc09908b174f5e27" +"checksum scopeguard 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)" = "b42e15e59b18a828bbf5c58ea01debb36b9b096346de35d941dcb89009f24a0d" +"checksum security-framework 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)" = "eee63d0f4a9ec776eeb30e220f0bc1e092c3ad744b2a379e3993070364d3adc2" +"checksum security-framework-sys 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)" = "9636f8989cbf61385ae4824b98c1aaa54c994d7d8b41f11c601ed799f0549a56" +"checksum semver 0.9.0 (registry+https://github.com/rust-lang/crates.io-index)" = "1d7eb9ef2c18661902cc47e535f9bc51b78acd254da71d375c2f6720d9a40403" +"checksum semver-parser 0.7.0 (registry+https://github.com/rust-lang/crates.io-index)" = "388a1df253eca08550bef6c72392cfe7c30914bf41df5269b68cbd6ff8f570a3" +"checksum serde 1.0.94 (registry+https://github.com/rust-lang/crates.io-index)" = "076a696fdea89c19d3baed462576b8f6d663064414b5c793642da8dfeb99475b" +"checksum serde_derive 1.0.94 (registry+https://github.com/rust-lang/crates.io-index)" = "ef45eb79d6463b22f5f9e16d283798b7c0175ba6050bc25c1a946c122727fe7b" +"checksum serde_json 1.0.40 (registry+https://github.com/rust-lang/crates.io-index)" = "051c49229f282f7c6f3813f8286cc1e3323e8051823fce42c7ea80fe13521704" +"checksum serde_urlencoded 0.5.5 (registry+https://github.com/rust-lang/crates.io-index)" = "642dd69105886af2efd227f75a520ec9b44a820d65bc133a9131f7d229fd165a" +"checksum sha3 0.8.2 (registry+https://github.com/rust-lang/crates.io-index)" = "dd26bc0e7a2e3a7c959bc494caf58b72ee0c71d67704e9520f736ca7e4853ecf" +"checksum siphasher 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)" = "0b8de496cf83d4ed58b6be86c3a275b8602f6ffe98d3024a869e124147a9a3ac" +"checksum slab 0.4.2 (registry+https://github.com/rust-lang/crates.io-index)" = "c111b5bd5695e56cffe5129854aa230b39c93a305372fdbb2668ca2394eea9f8" +"checksum smallvec 0.6.10 (registry+https://github.com/rust-lang/crates.io-index)" = "ab606a9c5e214920bb66c458cd7be8ef094f813f20fe77a54cc7dbfff220d4b7" +"checksum spin 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)" = "44363f6f51401c34e7be73db0db371c04705d35efbe9f7d6082e03a921a32c55" +"checksum stable_deref_trait 1.1.1 (registry+https://github.com/rust-lang/crates.io-index)" = "dba1a27d3efae4351c8051072d619e3ade2820635c3958d826bfea39d59b54c8" +"checksum string 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)" = "d24114bfcceb867ca7f71a0d3fe45d45619ec47a6fbfa98cb14e14250bfa5d6d" +"checksum strsim 0.8.0 (registry+https://github.com/rust-lang/crates.io-index)" = "8ea5119cdb4c55b55d432abb513a0429384878c15dde60cc77b1c99de1a95a6a" +"checksum structopt 0.2.18 (registry+https://github.com/rust-lang/crates.io-index)" = "16c2cdbf9cc375f15d1b4141bc48aeef444806655cd0e904207edc8d68d86ed7" +"checksum structopt-derive 0.2.18 (registry+https://github.com/rust-lang/crates.io-index)" = "53010261a84b37689f9ed7d395165029f9cc7abb9f56bbfe86bee2597ed25107" +"checksum syn 0.15.39 (registry+https://github.com/rust-lang/crates.io-index)" = "b4d960b829a55e56db167e861ddb43602c003c7be0bee1d345021703fac2fb7c" +"checksum synstructure 0.10.2 (registry+https://github.com/rust-lang/crates.io-index)" = "02353edf96d6e4dc81aea2d8490a7e9db177bf8acb0e951c24940bf866cb313f" +"checksum tempfile 3.1.0 (registry+https://github.com/rust-lang/crates.io-index)" = "7a6e24d9338a0a5be79593e2fa15a648add6138caa803e2d5bc782c371732ca9" +"checksum termion 1.5.3 (registry+https://github.com/rust-lang/crates.io-index)" = "6a8fb22f7cde82c8220e5aeacb3258ed7ce996142c77cba193f203515e26c330" +"checksum termios 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)" = "72b620c5ea021d75a735c943269bb07d30c9b77d6ac6b236bc8b5c496ef05625" +"checksum textwrap 0.11.0 (registry+https://github.com/rust-lang/crates.io-index)" = "d326610f408c7a4eb6f51c37c330e496b08506c9457c9d34287ecc38809fb060" +"checksum thread_local 0.3.6 (registry+https://github.com/rust-lang/crates.io-index)" = "c6b53e329000edc2b34dbe8545fd20e55a333362d0a321909685a19bd28c3f1b" +"checksum time 0.1.42 (registry+https://github.com/rust-lang/crates.io-index)" = "db8dcfca086c1143c9270ac42a2bbd8a7ee477b78ac8e45b19abfb0cbede4b6f" +"checksum tokio 0.1.22 (registry+https://github.com/rust-lang/crates.io-index)" = "5a09c0b5bb588872ab2f09afa13ee6e9dac11e10a0ec9e8e3ba39a5a5d530af6" +"checksum tokio-buf 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)" = "8fb220f46c53859a4b7ec083e41dec9778ff0b1851c0942b211edb89e0ccdc46" +"checksum tokio-current-thread 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)" = "d16217cad7f1b840c5a97dfb3c43b0c871fef423a6e8d2118c604e843662a443" +"checksum tokio-executor 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)" = "0f27ee0e6db01c5f0b2973824547ce7e637b2ed79b891a9677b0de9bd532b6ac" +"checksum tokio-io 0.1.12 (registry+https://github.com/rust-lang/crates.io-index)" = "5090db468dad16e1a7a54c8c67280c5e4b544f3d3e018f0b913b400261f85926" +"checksum tokio-reactor 0.1.9 (registry+https://github.com/rust-lang/crates.io-index)" = "6af16bfac7e112bea8b0442542161bfc41cbfa4466b580bdda7d18cb88b911ce" +"checksum tokio-sync 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)" = "2162248ff317e2bc713b261f242b69dbb838b85248ed20bb21df56d60ea4cae7" +"checksum tokio-tcp 0.1.3 (registry+https://github.com/rust-lang/crates.io-index)" = "1d14b10654be682ac43efee27401d792507e30fd8d26389e1da3b185de2e4119" +"checksum tokio-threadpool 0.1.15 (registry+https://github.com/rust-lang/crates.io-index)" = "90ca01319dea1e376a001e8dc192d42ebde6dd532532a5bad988ac37db365b19" +"checksum tokio-timer 0.2.11 (registry+https://github.com/rust-lang/crates.io-index)" = "f2106812d500ed25a4f38235b9cae8f78a09edf43203e16e59c3b769a342a60e" +"checksum try-lock 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)" = "e604eb7b43c06650e854be16a2a03155743d3752dd1c943f6829e26b7a36e382" +"checksum try_from 0.3.2 (registry+https://github.com/rust-lang/crates.io-index)" = "283d3b89e1368717881a9d51dad843cc435380d8109c9e47d38780a324698d8b" +"checksum typenum 1.10.0 (registry+https://github.com/rust-lang/crates.io-index)" = "612d636f949607bdf9b123b4a6f6d966dedf3ff669f7f045890d3a4a73948169" +"checksum ucd-util 0.1.3 (registry+https://github.com/rust-lang/crates.io-index)" = "535c204ee4d8434478593480b8f86ab45ec9aae0e83c568ca81abf0fd0e88f86" +"checksum unicase 1.4.2 (registry+https://github.com/rust-lang/crates.io-index)" = "7f4765f83163b74f957c797ad9253caf97f103fb064d3999aea9568d09fc8a33" +"checksum unicase 2.4.0 (registry+https://github.com/rust-lang/crates.io-index)" = "a84e5511b2a947f3ae965dcb29b13b7b1691b6e7332cf5dbc1744138d5acb7f6" +"checksum unicode-bidi 0.3.4 (registry+https://github.com/rust-lang/crates.io-index)" = "49f2bd0c6468a8230e1db229cff8029217cf623c767ea5d60bfbd42729ea54d5" +"checksum unicode-normalization 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)" = "141339a08b982d942be2ca06ff8b076563cbe223d1befd5450716790d44e2426" +"checksum unicode-segmentation 1.3.0 (registry+https://github.com/rust-lang/crates.io-index)" = "1967f4cdfc355b37fd76d2a954fb2ed3871034eb4f26d60537d88795cfc332a9" +"checksum unicode-width 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)" = "882386231c45df4700b275c7ff55b6f3698780a650026380e72dabe76fa46526" +"checksum unicode-xid 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)" = "fc72304796d0818e357ead4e000d19c9c174ab23dc11093ac919054d20a6a7fc" +"checksum url 1.7.2 (registry+https://github.com/rust-lang/crates.io-index)" = "dd4e7c0d531266369519a4aa4f399d748bd37043b00bde1e4ff1f60a120b355a" +"checksum utf8-ranges 1.0.3 (registry+https://github.com/rust-lang/crates.io-index)" = "9d50aa7650df78abf942826607c62468ce18d9019673d4a2ebe1865dbb96ffde" +"checksum uuid 0.7.4 (registry+https://github.com/rust-lang/crates.io-index)" = "90dbc611eb48397705a6b0f6e917da23ae517e4d127123d2cf7674206627d32a" +"checksum vcpkg 0.2.7 (registry+https://github.com/rust-lang/crates.io-index)" = "33dd455d0f96e90a75803cfeb7f948768c08d70a6de9a8d2362461935698bf95" +"checksum vec_map 0.8.1 (registry+https://github.com/rust-lang/crates.io-index)" = "05c78687fb1a80548ae3250346c3db86a80a7cdd77bda190189f2d0a0987c81a" +"checksum version_check 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)" = "914b1a6776c4c929a602fafd8bc742e06365d4bcbe48c30f9cca5824f70dc9dd" +"checksum want 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)" = "b6395efa4784b027708f7451087e647ec73cc74f5d9bc2e418404248d679a230" +"checksum winapi 0.2.8 (registry+https://github.com/rust-lang/crates.io-index)" = "167dc9d6949a9b857f3451275e911c3f44255842c1f7a76f33c55103a909087a" +"checksum winapi 0.3.7 (registry+https://github.com/rust-lang/crates.io-index)" = "f10e386af2b13e47c89e7236a7a14a086791a2b88ebad6df9bf42040195cf770" +"checksum winapi-build 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)" = "2d315eee3b34aca4797b2da6b13ed88266e6d612562a0c46390af8299fc699bc" +"checksum winapi-i686-pc-windows-gnu 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)" = "ac3b87c63620426dd9b991e5ce0329eff545bccbbb34f3be09ff6fb6ab51b7b6" +"checksum winapi-x86_64-pc-windows-gnu 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)" = "712e227841d057c1ee1cd2fb22fa7e5a5461ae8e48fa2ca79ec42cfc1931183f" +"checksum ws2_32-sys 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)" = "d59cefebd0c892fa2dd6de581e937301d8552cb44489cdff035c6187cb63fa5e" diff --git a/rust/Cargo.toml b/rust/Cargo.toml new file mode 100644 index 0000000..132a70d --- /dev/null +++ b/rust/Cargo.toml @@ -0,0 +1,34 @@ +[package] +name = "ed_lrr" +version = "0.1.0" +authors = ["Daniel Seiller "] +edition = "2018" +repository = "https://gitlab.com/Earthnuker/ed_lrr.git" +license = "WTFPL" + + +[lib] +crate-type = ["cdylib"] + +[profile.release] +# debug=true + +[dependencies] +csv = "1.1.1" +serde = "1.0.94" +serde_derive = "1.0.94" +rstar = {version="0.4.0"} +humantime = "1.2.0" +structopt = "0.2.18" +permutohedron = "0.2.4" +serde_json = "1.0.40" +indicatif = "0.11.0" +fnv = "1.0.6" +bincode = "1.1.4" +sha3 = "0.8.2" +byteorder = "1.3.2" +reqwest = "0.9.18" + +[dependencies.pyo3] +version = "0.7.0" +features = ["extension-module"] diff --git a/rust/src/common.rs b/rust/src/common.rs new file mode 100644 index 0000000..922aafd --- /dev/null +++ b/rust/src/common.rs @@ -0,0 +1,38 @@ +use serde::{Deserialize, Serialize}; +#[derive(Debug, Clone, Serialize, Deserialize)] +pub struct SystemSerde { + pub id: u32, + pub star_type: String, + pub system: String, + pub body: String, + pub mult: f32, + pub distance: u32, + pub x: f32, + pub y: f32, + pub z: f32, +} + +impl SystemSerde { + pub fn build(&self) -> System { + System { + id: self.id, + star_type: self.star_type.clone(), + system: self.system.clone(), + body: self.body.clone(), + mult: self.mult, + distance: self.distance, + pos: [self.x, self.y, self.z], + } + } +} + +#[derive(Debug, Clone, Deserialize, Serialize)] +pub struct System { + pub id: u32, + pub star_type: String, + pub system: String, + pub body: String, + pub mult: f32, + pub distance: u32, + pub pos: [f32; 3], +} diff --git a/rust/src/download.rs b/rust/src/download.rs new file mode 100644 index 0000000..57ceaa8 --- /dev/null +++ b/rust/src/download.rs @@ -0,0 +1,63 @@ +use indicatif::{MultiProgress, ProgressBar, ProgressStyle}; +use std::fs::File; +use std::io; +use std::path::PathBuf; +use structopt::StructOpt; + +#[derive(Debug, StructOpt, Clone)] +pub struct DownloadOpts { + #[structopt( + long = "bodies", + default_value = "https://www.edsm.net/dump/bodies.json" + )] + /// Url to bodies.json + bodies_url: String, + #[structopt( + long = "systems", + default_value = "https://www.edsm.net/dump/systemsWithCoordinates.json" + )] + /// Url to systemsWithCoordinates.json + systems_url: String, +} + +fn fetch_url(url: &str, prog_bar: &ProgressBar) -> std::io::Result<()> { + let outfile = url.split('/').last().unwrap(); + let template = format!("{} {}", "[{elapsed_precise}] {binary_bytes}", outfile); + prog_bar.set_style(ProgressStyle::default_bar().template(&template)); + + let client = reqwest::Client::builder().gzip(true).build().unwrap(); + let resp = client.get(url).send().unwrap(); + let target_path = PathBuf::from(format!("dumps/{}", outfile)); + if target_path.exists() { + eprintln!("Error: Target {} exists!", outfile); + return Ok(()); + } + let mut target = File::create(target_path)?; + io::copy(&mut prog_bar.wrap_read(resp), &mut target).unwrap(); + prog_bar.finish(); + Ok(()) +} + +pub fn download(opts: DownloadOpts) -> std::io::Result<()> { + let mut threads = Vec::new(); + let m = MultiProgress::new(); + { + let opts = opts.clone(); + let pb = m.add(ProgressBar::new(0)); + threads.push(std::thread::spawn(move || { + fetch_url(&opts.bodies_url, &pb).unwrap(); + })); + }; + { + let opts = opts.clone(); + let pb = m.add(ProgressBar::new(0)); + threads.push(std::thread::spawn(move || { + fetch_url(&opts.systems_url, &pb).unwrap(); + })); + } + m.join_and_clear().unwrap(); + for th in threads { + th.join().unwrap(); + } + Ok(()) +} diff --git a/rust/src/lib.rs b/rust/src/lib.rs new file mode 100644 index 0000000..3d65b7d --- /dev/null +++ b/rust/src/lib.rs @@ -0,0 +1,66 @@ +mod common; +mod download; +mod preprocess; +mod route; +use std::collections::HashMap; +use pyo3::prelude::*; +use pyo3::types::PyDict; +use std::path::PathBuf; + +#[pymodule] +pub fn _ed_lrr(py: Python, m: &PyModule) -> PyResult<()> { + /// Test + #[pyfn(m,"test")] + fn test(py:Python,o:PyObject) -> PyResult<()> { + println!("OBJ: {:?}",o); + return Ok(()); + } + + /// download(systems_url,systems_file, bodies_url, bodies_file, callback) + /// -- + /// + /// Download bodies.json and systemsWithCoordinates.json + #[pyfn(m, "download")] + fn download(py: Python, systems_url: String, systems_file: String, bodies_url:String,bodies_file:String,callback: PyObject) -> PyResult { + let state = PyDict::new(py); + state.set_item("systems_url", systems_url)?; + state.set_item("systems_file", systems_file)?; + state.set_item("bodies_url", bodies_url)?; + state.set_item("bodies_file", bodies_file)?; + state.set_item("callback", callback)?; + return Ok(state.to_object(py)); + } + + /// preprocess(infile_systems, infile_bodies, outfile, callback) + /// -- + /// + /// Preprocess bodies.json and systemsWithCoordinates.json into stars.csv + #[pyfn(m, "preprocess")] + fn preprocess(py: Python, infile_systems: String, infile_bodies: String, outfile:String,callback: PyObject) -> PyResult { + let state = PyDict::new(py); + state.set_item("infile_systems", infile_systems)?; + state.set_item("infile_bodies", infile_bodies)?; + state.set_item("outfile", outfile)?; + state.set_item("callback", callback)?; + return Ok(state.to_object(py)); + } + + /// route(infile, source, dest, range, mode, greedyness, precomp, callback) + /// -- + /// + /// Compute a Route using the suplied parameters + #[pyfn(m, "route")] + fn route(py: Python, infile: String, source: String, dest:String, range: f32, mode: String,greedyness: Option, precomp: Option,callback: PyObject) -> PyResult { + let state = PyDict::new(py); + state.set_item("infile", infile)?; + state.set_item("source", source)?; + state.set_item("dest", dest)?; + state.set_item("range", range)?; + state.set_item("mode", mode)?; + state.set_item("greedyness", greedyness)?; + state.set_item("precomp", precomp)?; + state.set_item("callback", callback)?; + return Ok(state.to_object(py)); + } + Ok(()) +} \ No newline at end of file diff --git a/rust/src/preprocess.rs b/rust/src/preprocess.rs new file mode 100644 index 0000000..c564ea8 --- /dev/null +++ b/rust/src/preprocess.rs @@ -0,0 +1,220 @@ +use crate::common::SystemSerde; +use fnv::FnvHashMap; +use humantime::format_duration; +use indicatif::{ProgressBar, ProgressStyle}; +use serde::Deserialize; +use serde_json::Result; +use std::fs::File; +use std::io::Seek; +use std::io::{BufRead, BufReader, BufWriter, SeekFrom}; +use std::path::PathBuf; +use std::str; +use std::time::Instant; +use structopt::StructOpt; + +#[derive(Debug, StructOpt)] +pub struct PreprocessOpts { + #[structopt(short, long = "bodies", default_value = "dumps/bodies.json")] + /// Path to bodies.json + pub bodies: PathBuf, + #[structopt( + short, + long = "systems", + default_value = "dumps/systemsWithCoordinates.json" + )] + /// Path to systemsWithCoordinates.json + pub systems: PathBuf, + #[structopt(default_value = "stars")] + /// outfile prefix + pub prefix: String, +} + +#[derive(Debug, Deserialize)] +#[allow(non_snake_case)] +struct Body { + name: String, + subType: String, + #[serde(rename = "type")] + body_type: String, + systemId: i32, + systemId64: i64, + #[serde(rename = "distanceToArrival")] + distance: u32, +} + +#[derive(Debug, Deserialize)] +struct Coords { + x: f32, + y: f32, + z: f32, +} + +#[derive(Debug, Deserialize)] +struct System { + id: i32, + id64: i64, + name: String, + coords: Coords, + date: String, +} + +#[derive(Debug, StructOpt)] +#[structopt( + name = "ed_lrr_pp", + about = "Preprocessor for Elite: Dangerous Long-Range Router", + rename_all = "snake_case" +)] +/// Preprocess data for ed_lrr +struct Opt { + #[structopt(short, long = "bodies")] + /// Path to bodies.json + bodies: PathBuf, + #[structopt(short, long = "systems")] + /// Path to systemsWithCoordinates.json + systems: PathBuf, + #[structopt(default_value = "stars")] + /// outfile prefix + prefix: String, +} + +fn get_mult(star_type: &str) -> f32 { + if star_type.contains("White Dwarf") { + return 1.5; + } + if star_type.contains("Neutron") { + return 4.0; + } + 1.0 +} + +fn process(path: &PathBuf, func: &mut dyn for<'r> FnMut(&'r str) -> ()) -> std::io::Result<()> { + let mut cnt = 0; + let mut buffer = String::new(); + let t_start = Instant::now(); + let fh = File::open(path)?; + let prog_bar = ProgressBar::new(fh.metadata()?.len()); + prog_bar.set_style( + ProgressStyle::default_bar() + .template( + "[{elapsed_precise}/{eta_precise}]{spinner} [{wide_bar}] {binary_bytes}/{binary_total_bytes} ({percent}%)", + ) + .progress_chars("#9876543210 ") + .tick_chars("/-\\|"), + ); + prog_bar.set_draw_delta(1024 * 1024); + let mut reader = BufReader::new(fh); + println!("Loading {} ...", path.to_str().unwrap()); + while let Ok(n) = reader.read_line(&mut buffer) { + if n == 0 { + break; + } + buffer = buffer.trim_end().trim_end_matches(|c| c == ',').to_string(); + if !buffer.is_empty() { + func(&buffer); + } + prog_bar.set_position(reader.seek(SeekFrom::Current(0)).unwrap()); + cnt += 1; + buffer.clear(); + } + prog_bar.finish_and_clear(); + println!( + "Processed {} lines in {} ...", + cnt, + format_duration(t_start.elapsed()) + ); + Ok(()) +} + +fn process_systems(path: &PathBuf) -> FnvHashMap { + let mut ret = FnvHashMap::default(); + process(path, &mut |line| { + let sys_res: Result = serde_json::from_str(&line); + if let Ok(sys) = sys_res { + ret.insert(sys.id, sys); + } else { + eprintln!("\nError parsing: {}\n\t{:?}\n", line, sys_res.unwrap_err()); + } + }) + .unwrap(); + ret +} + +fn build_index(path: &PathBuf) -> std::io::Result<()> { + let mut wtr = BufWriter::new(File::create(path.with_extension("idx"))?); + let mut idx: Vec = Vec::new(); + let mut records = (csv::Reader::from_path(path)?).into_deserialize::(); + loop { + idx.push(records.reader().position().byte()); + if records.next().is_none() { + break; + } + } + bincode::serialize_into(&mut wtr, &idx).unwrap(); + Ok(()) +} + +fn process_bodies( + path: &PathBuf, + out_prefix: &str, + systems: &mut FnvHashMap, +) -> std::io::Result<()> { + let out_path = PathBuf::from(format!("{}.csv", out_prefix)); + println!( + "Processing {} into {} ...", + path.to_str().unwrap(), + out_path.to_str().unwrap(), + ); + let mut n: u32 = 0; + let mut wtr = csv::Writer::from_path(out_path)?; + process(path, &mut |line| { + if !line.contains("Star") { + return; + } + let body_res: Result = serde_json::from_str(&line); + if let Ok(body) = body_res { + if !body.body_type.contains("Star") { + return; + } + if let Some(sys) = systems.get(&body.systemId) { + let sub_type = body.subType; + let mult = get_mult(&sub_type); + let sys_name = sys.name.clone(); + let rec = SystemSerde { + id: n, + star_type: sub_type, + system: sys_name, + body: body.name, + mult, + distance: body.distance, + x: sys.coords.x, + y: sys.coords.y, + z: sys.coords.z, + }; + wtr.serialize(rec).unwrap(); + n += 1; + }; + } else { + eprintln!("\nError parsing: {}\n\t{:?}\n", line, body_res.unwrap_err()); + } + }) + .unwrap(); + println!("Total Systems: {}", n); + systems.clear(); + Ok(()) +} + +pub fn preprocess_files(opts: PreprocessOpts) -> std::io::Result<()> { + let out_path = PathBuf::from(format!("{}.csv", &opts.prefix)); + if !out_path.exists() { + let mut systems = process_systems(&opts.systems); + process_bodies(&opts.bodies, &opts.prefix, &mut systems)?; + } else { + println!( + "File '{}' exists, not overwriting it", + out_path.to_str().unwrap() + ); + } + println!("Building index..."); + println!("Index result: {:?}", build_index(&out_path)); + Ok(()) +} diff --git a/rust/src/route.rs b/rust/src/route.rs new file mode 100644 index 0000000..dd11596 --- /dev/null +++ b/rust/src/route.rs @@ -0,0 +1,879 @@ +use core::cmp::Ordering; +use csv::StringRecord; +use fnv::{FnvHashMap, FnvHashSet}; +use humantime::format_duration; +use permutohedron::LexicalPermutation; +use rstar::{PointDistance, RTree, RTreeObject, AABB}; +use sha3::{Digest, Sha3_256}; +use std::collections::VecDeque; +use std::fs::File; +use std::hash::{Hash, Hasher}; +use std::io::Seek; +use std::io::{BufRead, BufReader, BufWriter, Write}; +use std::path::PathBuf; +use std::str::FromStr; +use std::time::Instant; +use structopt::StructOpt; + +use crate::common::{System, SystemSerde}; + +#[derive(Debug)] +pub struct SearchState { + pub mode: String, + pub depth: usize, + pub queue_size: usize, + pub d_rem: f64, + pub prc_done: f64, + pub n_seen: usize, + pub prc_seen: f64 +} + + +#[derive(Debug)] +pub struct RouteOpts { + pub range: Option, + pub file_path: PathBuf, + pub precomp_file: Option, + pub precompute: bool, + pub permute: bool, + pub primary: bool, + pub full_permute: bool, + pub factor: Option, + pub mode: Mode, + pub systems: Vec, +} + +#[derive(Debug)] +pub enum Mode { + BFS, + Greedy, + AStar, +} + +impl FromStr for Mode { + type Err = String; + fn from_str(s: &str) -> Result { + match s { + "bfs" => Ok(Mode::BFS), + "greedy" => Ok(Mode::Greedy), + "astar" => Ok(Mode::AStar), + _ => Err("Invalid Mode".to_string()), + } + } +} + +fn dist2(p1: &[f32; 3], p2: &[f32; 3]) -> f32 { + let dx = p1[0] - p2[0]; + let dy = p1[1] - p2[1]; + let dz = p1[2] - p2[2]; + + dx * dx + dy * dy + dz * dz +} + +fn dist(p1: &[f32; 3], p2: &[f32; 3]) -> f32 { + dist2(p1, p2).sqrt() +} + +fn fcmp(a: f32, b: f32) -> Ordering { + match (a, b) { + (x, y) if x.is_nan() && y.is_nan() => Ordering::Equal, + (x, _) if x.is_nan() => Ordering::Greater, + (_, y) if y.is_nan() => Ordering::Less, + (..) => a.partial_cmp(&b).unwrap(), + } +} + +impl System { + pub fn dist2(&self, p: &[f32; 3]) -> f32 { + dist2(&self.pos, p) + } + pub fn distp(&self, p: &System) -> f32 { + dist(&self.pos, &p.pos) + } + pub fn distp2(&self, p: &System) -> f32 { + self.dist2(&p.pos) + } +} +impl PartialEq for System { + fn eq(&self, other: &Self) -> bool { + self.id == other.id + } +} + +impl Eq for System {} + +impl Hash for System { + fn hash(&self, state: &mut H) { + self.id.hash(state); + } +} + +impl RTreeObject for System { + type Envelope = AABB<[f32; 3]>; + + fn envelope(&self) -> Self::Envelope { + AABB::from_point(self.pos) + } +} + +impl PointDistance for System { + fn distance_2(&self, point: &[f32; 3]) -> f32 { + self.dist2(&point) + } +} + +fn hash_file(path: &PathBuf) -> Vec { + let mut hash_reader = BufReader::new(File::open(path).unwrap()); + let mut hasher = Sha3_256::new(); + std::io::copy(&mut hash_reader, &mut hasher).unwrap(); + hasher.result().iter().copied().collect() +} + +struct LineCache { + cache: Vec, + file: BufReader, + header: Option, +} + +impl LineCache { + pub fn new(path: &PathBuf) -> Option { + let idx_path = path.with_extension("idx"); + let t_load = Instant::now(); + println!("Loading Index from {}", idx_path.to_str().unwrap()); + let cache = + bincode::deserialize_from(&mut BufReader::new(File::open(idx_path).ok()?)).ok()?; + let mut reader = BufReader::new(File::open(path).ok()?); + let header = Self::read_record(&mut reader); + let ret = Self { + file: reader, + cache, + header, + }; + println!("Done in {}!", format_duration(t_load.elapsed())); + Some(ret) + } + fn read_record(reader: &mut BufReader) -> Option { + let mut line = String::new(); + reader.read_line(&mut line).ok()?; + let v: Vec<_> = line.trim_end().split(',').collect(); + let rec = StringRecord::from(v); + Some(rec) + } + pub fn get(&mut self, id: u32) -> Option { + let pos = self.cache[id as usize]; + self.file.seek(std::io::SeekFrom::Start(pos)).unwrap(); + let rec = Self::read_record(&mut self.file).unwrap(); + let sys: SystemSerde = rec.deserialize(self.header.as_ref()).unwrap(); + Some(sys.build()) + } +} + +pub struct Router { + tree: RTree, + scoopable: FnvHashSet, + pub route_tree: Option>, + cache: Option, + range: f32, + primary_only: bool, + path: PathBuf, + callback: Box ()>, +} + +impl Router { + pub fn new(path: &PathBuf, range: f32, primary_only: bool,callback: Box ()>) -> Self { + let mut scoopable = FnvHashSet::default(); + let mut reader = csv::ReaderBuilder::new() + .from_path(path) + .unwrap_or_else(|e| { + println!("Error opening {}: {}", path.to_str().unwrap(), e); + std::process::exit(1); + }); + let t_load = Instant::now(); + println!("Loading {}...", path.to_str().unwrap()); + let systems: Vec = reader + .deserialize::() + .map(|res| res.unwrap()) + .filter(|sys| { + if primary_only { + sys.distance == 0 + } else { + true + } + }) + .map(|sys| { + if sys.mult > 1.0f32 { + scoopable.insert(sys.id); + } else { + for c in "KGBFOAM".chars() { + if sys.star_type.starts_with(c) { + scoopable.insert(sys.id); + break; + } + } + } + sys.build() + }) + .collect(); + println!("Building RTree..."); + let ret = Self { + tree: RTree::bulk_load(systems), + scoopable, + route_tree: None, + range, + primary_only, + cache: LineCache::new(path), + path: path.clone(), + callback: callback, + }; + println!( + "{} Systems loaded in {}", + ret.tree.size(), + format_duration(t_load.elapsed()) + ); + ret + } + + pub fn from_file(filename: &PathBuf) -> (PathBuf, Self) { + let t_load = Instant::now(); + let mut reader = BufReader::new(File::open(&filename).unwrap()); + println!("Loading {}", filename.to_str().unwrap()); + let (primary, range, file_hash, path, route_tree): ( + bool, + f32, + Vec, + String, + FnvHashMap, + ) = bincode::deserialize_from(&mut reader).unwrap(); + let path = PathBuf::from(path); + println!("Done in {}!", format_duration(t_load.elapsed())); + if hash_file(&path) != file_hash { + panic!("File hash mismatch!") + } + let cache = LineCache::new(&path); + ( + path.clone(), + Self { + tree: RTree::default(), + scoopable: FnvHashSet::default(), + route_tree: Some(route_tree), + range, + cache, + primary_only: primary, + path, + callback: Box::new(|s| {}), + }, + ) + } + + fn closest(&self, point: &[f32; 3]) -> &System { + self.tree.nearest_neighbor(point).unwrap() + } + fn points_in_sphere(&self, center: &[f32; 3], radius: f32) -> impl Iterator { + self.tree.locate_within_distance(*center, radius * radius) + } + + fn neighbours(&self, sys: &System, r: f32) -> impl Iterator { + self.points_in_sphere(&sys.pos, sys.mult * r) + } + + fn valid(&self, sys: &System) -> bool { + self.scoopable.contains(&sys.id) + } + + pub fn best_name_multiroute( + &self, + waypoints: &[String], + range: f32, + full: bool, + mode: Mode, + factor: f32, + ) -> Vec { + let mut best_score: f32 = std::f32::MAX; + let mut waypoints = waypoints.to_owned(); + let mut best_permutation_waypoints = waypoints.to_owned(); + let first = waypoints.first().cloned(); + let last = waypoints.last().cloned(); + let t_start = Instant::now(); + println!("Finding best permutation of hops..."); + while waypoints.prev_permutation() {} + loop { + let c_first = waypoints.first().cloned(); + let c_last = waypoints.last().cloned(); + if full || ((c_first == first) && (c_last == last)) { + let mut total_d = 0.0; + for pair in waypoints.windows(2) { + match pair { + [src, dst] => { + let (mut src, dst) = + (self.name_to_systems(&src), self.name_to_systems(&dst)); + src.sort_by_key(|&p| (p.mult * 10.0) as u8); + let src = src.last().unwrap(); + let dst = dst.last().unwrap(); + total_d += src.distp2(dst); + } + _ => panic!("Invalid routing parameters!"), + } + } + if total_d < best_score { + best_score = total_d; + best_permutation_waypoints = waypoints.to_owned(); + } + } + if !waypoints.next_permutation() { + break; + } + } + + println!("Done in {}!", format_duration(t_start.elapsed())); + println!("Best permutation: {:?}", best_permutation_waypoints); + self.name_multiroute(&best_permutation_waypoints, range, mode, factor) + } + + pub fn name_multiroute( + &self, + waypoints: &[String], + range: f32, + mode: Mode, + factor: f32, + ) -> Vec { + let mut coords = Vec::new(); + for p_name in waypoints { + let mut p_l = self.name_to_systems(p_name); + p_l.sort_by_key(|&p| (p.mult * 10.0) as u8); + let p = p_l.last().unwrap(); + coords.push((p_name, p.pos)); + } + self.multiroute(coords.as_slice(), range, mode, factor) + } + pub fn multiroute( + &self, + waypoints: &[(&String, [f32; 3])], + range: f32, + mode: Mode, + factor: f32, + ) -> Vec { + let mut route: Vec = Vec::new(); + for pair in waypoints.windows(2) { + match *pair { + [src, dst] => { + let block = match mode { + Mode::BFS => self.route_bfs(&src, &dst, range), + Mode::Greedy => self.route_greedy(&src, &dst, range), + Mode::AStar => self.route_astar(&src, &dst, range, factor), + }; + if route.is_empty() { + for sys in block.iter() { + route.push(sys.clone()); + } + } else { + for sys in block.iter().skip(1) { + route.push(sys.clone()); + } + } + } + _ => panic!("Invalid routing parameters!"), + } + } + route + } + + fn name_to_systems(&self, name: &str) -> Vec<&System> { + for sys in &self.tree { + if sys.system == name { + return self.neighbours(&sys, 0.0).collect(); + } + } + eprintln!("System not found: \"{}\"", name); + std::process::exit(1); + } + + pub fn route_astar( + &self, + src: &(&String, [f32; 3]), + dst: &(&String, [f32; 3]), + range: f32, + factor: f32, + ) -> Vec { + if factor == 0.0 { + return self.route_bfs(src, dst, range); + } + println!("Running A-Star with greedy factor of {}", factor); + let (src_name, src) = src; + let (dst_name, dst) = dst; + let start_sys = self.closest(src); + let goal_sys = self.closest(dst); + { + let d = dist(src, dst); + println!("Plotting route from {} to {}...", src_name, dst_name); + println!( + "Jump Range: {} Ly, Distance: {} Ly, Theoretical Jumps: {}", + range, + d, + d / range + ); + } + let total = self.tree.size() as f32; + let mut prev = FnvHashMap::default(); + let mut seen = FnvHashSet::default(); + let t_start = Instant::now(); + let mut found = false; + let mut maxd = 0; + let mut queue: Vec<(usize, usize, &System)> = Vec::new(); + queue.push(( + 0, // depth + (start_sys.distp(goal_sys) / range) as usize, // h + &start_sys, + )); + seen.insert(start_sys.id); + + while !(queue.is_empty() || found) { + while let Some((depth, _, sys)) = queue.pop() { + if depth > maxd { + maxd = depth; + print!( + "[{}] Depth: {}, Queue: {}, Seen: {} ({:.02}%) \r", + format_duration(t_start.elapsed()), + depth, + queue.len(), + seen.len(), + ((seen.len() * 100) as f32) / total + ); + std::io::stdout().flush().unwrap(); + } + if sys.id == goal_sys.id { + found = true; + break; + } + queue.extend( + self.neighbours(&sys, range) + .filter(|&nb| (self.valid(nb) || (nb.id == goal_sys.id))) + .filter(|&nb| seen.insert(nb.id)) + .map(|nb| { + prev.insert(nb.id, sys); + let d_g = (nb.distp(goal_sys) / range) as usize; + (depth + 1, d_g, nb) + }), + ); + queue.sort_by(|b, a| { + let (a_0, a_1) = (a.0 as f32, a.1 as f32); + let (b_0, b_1) = (b.0 as f32, b.1 as f32); + let v_a = a_0 + a_1 * factor; + let v_b = b_0 + b_1 * factor; + fcmp(v_a, v_b) + }); + // queue.reverse(); + } + } + println!(); + + println!(); + if !found { + eprintln!("No route from {} to {} found!", src_name, dst_name); + return Vec::new(); + } + let mut v: Vec = Vec::new(); + let mut curr_sys = goal_sys; + loop { + v.push(curr_sys.clone()); + match prev.get(&curr_sys.id) { + Some(sys) => curr_sys = *sys, + None => { + break; + } + } + } + v.reverse(); + v + } + + pub fn route_greedy( + &self, + src: &(&String, [f32; 3]), + dst: &(&String, [f32; 3]), + range: f32, + ) -> Vec { + println!("Running Greedy-Search"); + let (src_name, src) = src; + let (dst_name, dst) = dst; + let start_sys = self.closest(src); + let goal_sys = self.closest(dst); + { + let d = dist(src, dst); + println!("Plotting route from {} to {}...", src_name, dst_name); + println!( + "Jump Range: {} Ly, Distance: {} Ly, Theoretical Jumps: {}", + range, + d, + d / range + ); + } + let total = self.tree.size() as f32; + let mut prev = FnvHashMap::default(); + let mut seen = FnvHashSet::default(); + let t_start = Instant::now(); + let mut found = false; + let mut maxd = 0; + let mut queue: Vec<(f32, f32, usize, &System)> = Vec::new(); + queue.push((-goal_sys.mult, start_sys.distp2(goal_sys), 0, &start_sys)); + seen.insert(start_sys.id); + while !(queue.is_empty() || found) { + while let Some((_, _, depth, sys)) = queue.pop() { + if depth > maxd { + maxd = depth; + print!( + "[{}] Depth: {}, Queue: {}, Seen: {} ({:.02}%) \r", + format_duration(t_start.elapsed()), + depth, + queue.len(), + seen.len(), + ((seen.len() * 100) as f32) / total + ); + std::io::stdout().flush().unwrap(); + } + if sys.id == goal_sys.id { + found = true; + break; + } + queue.extend( + self.neighbours(&sys, range) + .filter(|&nb| (self.valid(nb) || (nb.id == goal_sys.id))) + .filter(|&nb| seen.insert(nb.id)) + .map(|nb| { + prev.insert(nb.id, sys); + (-nb.mult, nb.distp2(goal_sys), depth + 1, nb) + }), + ); + queue.sort_by(|a, b| fcmp(a.0, b.0).then(fcmp(a.1, b.1))); + queue.reverse(); + } + } + println!(); + println!(); + if !found { + eprintln!("No route from {} to {} found!", src_name, dst_name); + return Vec::new(); + } + let mut v: Vec = Vec::new(); + let mut curr_sys = goal_sys; + loop { + v.push(curr_sys.clone()); + match prev.get(&curr_sys.id) { + Some(sys) => curr_sys = *sys, + None => { + break; + } + } + } + v.reverse(); + v + } + + pub fn precompute(&mut self, src: &str) { + let mut sys_l = self.name_to_systems(src); + sys_l.sort_by_key(|&sys| (sys.mult * 10.0) as u8); + let sys = sys_l.last().unwrap(); + println!("Precomputing routes starting at {} ...", sys.system); + let total = self.tree.size() as f32; + let mut prev = FnvHashMap::default(); + let mut seen = FnvHashSet::default(); + let t_start = Instant::now(); + let mut depth = 0; + let mut queue: VecDeque<(usize, &System)> = VecDeque::new(); + let mut queue_next: VecDeque<(usize, &System)> = VecDeque::new(); + queue.push_front((0, &sys)); + seen.insert(sys.id); + while !queue.is_empty() { + print!( + "[{}] Depth: {}, Queue: {}, Seen: {} ({:.02}%) \r", + format_duration(t_start.elapsed()), + depth, + queue.len(), + seen.len(), + ((seen.len() * 100) as f32) / total + ); + std::io::stdout().flush().unwrap(); + while let Some((d, sys)) = queue.pop_front() { + queue_next.extend( + self.neighbours(&sys, self.range) + // .filter(|&nb| self.valid(nb)) + .filter(|&nb| seen.insert(nb.id)) + .map(|nb| { + prev.insert(nb.id, sys.id); + (d + 1, nb) + }), + ); + } + std::mem::swap(&mut queue, &mut queue_next); + depth += 1; + } + self.route_tree = Some(prev); + let ofn = format!( + "{}_{}{}.router", + src.replace("*", "").replace(" ", "_"), + self.range, + if self.primary_only { "_primary" } else { "" } + ); + println!("\nSaving to {}", ofn); + let mut out_fh = BufWriter::new(File::create(&ofn).unwrap()); + // (range, path, route_tree) + let data = ( + self.primary_only, + self.range, + hash_file(&self.path), + String::from(self.path.to_str().unwrap()), + self.route_tree.as_ref().unwrap(), + ); + bincode::serialize_into(&mut out_fh, &data).unwrap(); + } + + fn get_systems_by_ids(&mut self, path: &PathBuf, ids: &[u32]) -> FnvHashMap { + println!("Processing {}", path.to_str().unwrap()); + let mut ret = FnvHashMap::default(); + if let Some(c) = &mut self.cache.as_mut() { + let mut missing = false; + for id in ids { + match c.get(*id) { + Some(sys) => { + ret.insert(*id, sys); + } + None => { + println!("ID {} not found in cache", id); + missing = true; + break; + } + } + } + if !missing { + return ret; + } + } + let mut reader = csv::ReaderBuilder::new() + .from_path(path) + .unwrap_or_else(|e| { + println!("Error opening {}: {}", path.to_str().unwrap(), e); + std::process::exit(1); + }); + reader + .deserialize::() + .map(|res| res.unwrap()) + .filter(|sys| ids.contains(&sys.id)) + .map(|sys| { + ret.insert(sys.id, sys.build()); + }) + .last() + .unwrap_or_else(|| { + eprintln!("Error: No systems matching {:?} found!", ids); + std::process::exit(1); + }); + ret + } + + fn get_system_by_name(path: &PathBuf, name: &str) -> System { + let mut reader = csv::ReaderBuilder::new() + .from_path(path) + .unwrap_or_else(|e| { + eprintln!("Error opening {}: {}", path.to_str().unwrap(), e); + std::process::exit(1); + }); + let sys = reader + .deserialize::() + .map(|res| res.unwrap()) + .find(|sys| sys.system == name) + .unwrap_or_else(|| { + eprintln!("Error: System '{}' not found!", name); + std::process::exit(1); + }); + sys.build() + } + + pub fn route_to(&mut self, dst: &str, systems_path: &PathBuf) -> Vec { + let prev = self.route_tree.as_ref().unwrap(); + let dst = Self::get_system_by_name(&systems_path, dst); + if !prev.contains_key(&dst.id) { + eprintln!("System-ID {} not found", dst.id); + std::process::exit(1); + }; + let mut v_ids: Vec = Vec::new(); + let mut v: Vec = Vec::new(); + let mut curr_sys: u32 = dst.id; + loop { + v_ids.push(curr_sys); + match prev.get(&curr_sys) { + Some(sys_id) => curr_sys = *sys_id, + None => { + break; + } + } + } + v_ids.reverse(); + let id_map = self.get_systems_by_ids(&systems_path, &v_ids); + for sys_id in v_ids { + let sys = id_map.get(&sys_id).unwrap(); + v.push(sys.clone()) + } + v + } + + pub fn route_bfs( + &self, + src: &(&String, [f32; 3]), + dst: &(&String, [f32; 3]), + range: f32, + ) -> Vec { + println!("Running BFS"); + let (src_name, src) = src; + let (dst_name, dst) = dst; + let start_sys = self.closest(src); + let goal_sys = self.closest(dst); + let d_total = dist(src, dst); + { + println!("Plotting route from {} to {}...", src_name, dst_name); + println!( + "Jump Range: {} Ly, Distance: {} Ly, Estimated Jumps: {}", + range, + d_total, + d_total / range + ); + } + let total = self.tree.size() as f32; + let mut prev = FnvHashMap::default(); + let mut seen = FnvHashSet::default(); + let t_start = Instant::now(); + let mut depth = 0; + let mut found = false; + let mut queue: VecDeque<(usize, &System)> = VecDeque::new(); + let mut queue_next: VecDeque<(usize, &System)> = VecDeque::new(); + let mut d_rem = dist2(&start_sys.pos, &goal_sys.pos); + queue.push_front((0, &start_sys)); + seen.insert(start_sys.id); + while !(queue.is_empty() || found) { + print!( + "[{}] {:.02}% | Depth: {}, Queue: {}, Seen: {} ({:.02}%), Remaining Distance: {} \r", + format_duration(t_start.elapsed()), + (((d_total-d_rem.sqrt())*100f32)/d_total), + depth, + queue.len(), + seen.len(), + ((seen.len() * 100) as f32) / total, + d_rem.sqrt() + ); + std::io::stdout().flush().unwrap(); + while let Some((d, sys)) = queue.pop_front() { + if sys.id == goal_sys.id { + found = true; + break; + } + queue_next.extend( + self.neighbours(&sys, range) + .filter(|&nb| (self.valid(nb) || (nb.id == goal_sys.id))) + .filter(|&nb| seen.insert(nb.id)) + .map(|nb| { + prev.insert(nb.id, sys); + let dist = dist2(&nb.pos, &goal_sys.pos); + if dist < d_rem { + d_rem = dist; + } + (d + 1, nb) + }), + ); + } + std::mem::swap(&mut queue, &mut queue_next); + depth += 1; + } + println!(); + println!(); + if !found { + eprintln!("No route from {} to {} found!", src_name, dst_name); + return Vec::new(); + } + let mut v: Vec = Vec::new(); + let mut curr_sys = goal_sys; + loop { + v.push(curr_sys.clone()); + match prev.get(&curr_sys.id) { + Some(sys) => curr_sys = *sys, + None => { + break; + } + } + } + v.reverse(); + v + } +} +pub fn route(opts: RouteOpts) -> std::io::Result<()> { + if opts.systems.is_empty() { + if opts.precomp_file.is_some() { + eprintln!("Error: Please specify exatly one system"); + } else if opts.precompute { + eprintln!("Error: Please specify at least one system"); + } else { + eprintln!("Error: Please specify at least two systems"); + } + std::process::exit(1); + } + let mut path = opts.file_path; + let mut router: Router = if opts.precomp_file.is_some() { + let ret = Router::from_file(&opts.precomp_file.clone().unwrap()); + path = ret.0; + ret.1 + } else { + Router::new(&path, opts.range.unwrap(), opts.primary, Box::new(|state| { + println!("State: {:?}",state); + })) + }; + if opts.precompute { + for sys in opts.systems { + router.route_tree = None; + router.precompute(&sys); + } + std::process::exit(0); + } + let t_route = Instant::now(); + let route = if router.route_tree.is_some() { + router.route_to(opts.systems.first().unwrap(), &path) + } else if opts.permute || opts.full_permute { + router.best_name_multiroute( + &opts.systems, + opts.range.unwrap(), + opts.full_permute, + opts.mode, + opts.factor.unwrap_or(1.0), + ) + } else { + router.name_multiroute( + &opts.systems, + opts.range.unwrap(), + opts.mode, + opts.factor.unwrap_or(1.0), + ) + }; + println!("Route computed in {}\n", format_duration(t_route.elapsed())); + if route.is_empty() { + eprintln!("No route found!"); + return Ok(()); + } + let mut total: f32 = 0.0; + for (sys1, sys2) in route.iter().zip(route.iter().skip(1)) { + let dist = sys1.distp(sys2); + total += dist; + println!( + "{} ({}) [{}] ({},{},{}) [{} Ls]: {:.2} Ly", + sys1.body, + sys1.system, + sys1.star_type, + sys1.pos[0], + sys1.pos[1], + sys1.pos[2], + sys1.distance, + dist + ); + } + let sys = route.iter().last().unwrap(); + println!( + "{} ({}) [{}] ({},{},{}) [{} Ls]: {:.2} Ly", + sys.body, sys.system, sys.star_type, sys.pos[0], sys.pos[1], sys.pos[2], sys.distance, 0.0 + ); + println!("Total: {:.2} Ly ({} Jumps)", total, route.len()); + Ok(()) +} diff --git a/setup.py b/setup.py new file mode 100644 index 0000000..f6bccfe --- /dev/null +++ b/setup.py @@ -0,0 +1,23 @@ +from setuptools import setup +from setuptools_rust import Binding, RustExtension, Strip + +setup( + name="ed_lrr_gui", + version="0.1.0", + author="Daniel Seiller", + author_email="earthnuker@gmail.com", + url="none yet", + rust_extensions=[ + RustExtension( + "_ed_lrr", + path="rust/Cargo.toml", + binding=Binding.PyO3, + strip=Strip.All, + native=True, + ) + ], + packages=["ed_lrr_gui"], + entry_points={"console_scripts": ["ed_lrr_gui=ed_lrr_gui.__main__:main"]}, + install_requires=["PyQt5", "appdirs", "PyYAML"], + zip_safe=False, +)