spinetoolbox.project_items.importer.importer_worker

Contains importer_program script.

authors:
  1. Savolainen (VTT), P. Vennström (VTT), A. Soininen (VTT)
date:

10.6.2019

Module Contents

Classes

ImporterWorker
param checked_files:
 List of paths to checked source files
class spinetoolbox.project_items.importer.importer_worker.ImporterWorker(checked_files, all_import_settings, all_source_settings, urls_downstream, logs_dir, cancel_on_error, logger)[source]

Bases: PySide2.QtCore.QObject

Parameters:
  • checked_files (list(str)) – List of paths to checked source files
  • all_import_settings (dict) – Maps source file to setting for that file
  • all_source_settings (dict) – Maps source type to setting for that type
  • urls_downstream (list(str)) – List of urls to import data into
  • logs_dir (str) – path to the directory where logs should be written
  • cancel_on_error (bool) – whether or not to rollback and stop execution if errors
  • logger (LoggerInterface) – somewhere to log important messages
import_finished[source]

Emitted when work is finished with 0 if successful, -1 otherwise.

do_work(self)[source]

Does the work and emits import_finished when done.

_import(self, all_data, url)[source]