fosslight-scanner 2.0.0__py3-none-any.whl → 2.1.0__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- fosslight_scanner/_help.py +2 -1
- fosslight_scanner/_run_compare.py +11 -9
- fosslight_scanner/cli.py +2 -2
- fosslight_scanner/fosslight_scanner.py +95 -49
- {fosslight_scanner-2.0.0.dist-info → fosslight_scanner-2.1.0.dist-info}/METADATA +6 -5
- fosslight_scanner-2.1.0.dist-info/RECORD +15 -0
- fosslight_scanner-2.0.0.dist-info/RECORD +0 -15
- {fosslight_scanner-2.0.0.dist-info → fosslight_scanner-2.1.0.dist-info}/LICENSE +0 -0
- {fosslight_scanner-2.0.0.dist-info → fosslight_scanner-2.1.0.dist-info}/WHEEL +0 -0
- {fosslight_scanner-2.0.0.dist-info → fosslight_scanner-2.1.0.dist-info}/entry_points.txt +0 -0
- {fosslight_scanner-2.0.0.dist-info → fosslight_scanner-2.1.0.dist-info}/top_level.txt +0 -0
fosslight_scanner/_help.py
CHANGED
|
@@ -25,8 +25,9 @@ _HELP_MESSAGE_SCANNER = """
|
|
|
25
25
|
* Compare mode input file: Two FOSSLight reports (supports excel, yaml)
|
|
26
26
|
(ex, -p {before_name}.xlsx {after_name}.xlsx)
|
|
27
27
|
-w <link>\t\t Link to be analyzed can be downloaded by wget or git clone
|
|
28
|
-
-f <format
|
|
28
|
+
-f <formats> [<format> ...]\t FOSSLight Report file format (excel, csv, opossum, yaml, spdx-tag, spdx-yaml, spdx-json, spdx-xml)
|
|
29
29
|
* Compare mode result file: supports excel, json, yaml, html
|
|
30
|
+
* Multiple formats can be specified separated by space.
|
|
30
31
|
-e <path>\t\t Path to exclude from analysis (ex, -e {dir} {file})
|
|
31
32
|
-o <output>\t\t Output directory or file
|
|
32
33
|
-c <number>\t\t Number of processes to analyze source
|
|
@@ -203,7 +203,7 @@ def write_compared_result(output_file, compared_result, file_ext, before_f='', a
|
|
|
203
203
|
def get_comparison_result_filename(output_path, output_file, output_extension, _start_time):
|
|
204
204
|
result_file = ""
|
|
205
205
|
compare_prefix = f"fosslight_compare_{_start_time}"
|
|
206
|
-
if output_file !=
|
|
206
|
+
if output_file != '':
|
|
207
207
|
result_file = f"{output_file}{output_extension}"
|
|
208
208
|
else:
|
|
209
209
|
if output_extension == XLSX_EXT or output_extension == "":
|
|
@@ -232,7 +232,7 @@ def count_compared_result(compared_result):
|
|
|
232
232
|
logger.info(f"Comparison result: {count_str}")
|
|
233
233
|
|
|
234
234
|
|
|
235
|
-
def run_compare(before_f, after_f, output_path,
|
|
235
|
+
def run_compare(before_f, after_f, output_path, output_files, file_ext, _start_time, _output_dir):
|
|
236
236
|
ret = False
|
|
237
237
|
before_yaml = ''
|
|
238
238
|
after_yaml = ''
|
|
@@ -254,8 +254,6 @@ def run_compare(before_f, after_f, output_path, output_file, file_ext, _start_ti
|
|
|
254
254
|
tmp_a_yaml = f'{os.path.basename(after_f).rstrip(XLSX_EXT)}{YAML_EXT}'
|
|
255
255
|
after_yaml = after_f if after_ext == YAML_EXT else os.path.join(_output_dir, tmp_a_yaml)
|
|
256
256
|
|
|
257
|
-
result_file = get_comparison_result_filename(output_path, output_file, file_ext, _start_time)
|
|
258
|
-
|
|
259
257
|
before_basepath = os.path.dirname(before_f)
|
|
260
258
|
after_basepath = os.path.dirname(after_f)
|
|
261
259
|
if XLSX_EXT == before_ext:
|
|
@@ -267,13 +265,17 @@ def run_compare(before_f, after_f, output_path, output_file, file_ext, _start_ti
|
|
|
267
265
|
elif YAML_EXT == after_ext:
|
|
268
266
|
after_fileitems, _, _ = parsing_yml(after_yaml, after_basepath)
|
|
269
267
|
|
|
268
|
+
if output_files:
|
|
269
|
+
output_file = output_files[0]
|
|
270
270
|
compared_result = compare_yaml(before_fileitems, after_fileitems)
|
|
271
271
|
if compared_result != '':
|
|
272
272
|
count_compared_result(compared_result)
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
273
|
+
for f_ext in file_ext:
|
|
274
|
+
result_file = get_comparison_result_filename(output_path, output_file, f_ext, _start_time)
|
|
275
|
+
ret, result_file = write_compared_result(result_file, compared_result, f_ext, before_yaml, after_yaml)
|
|
276
|
+
if ret:
|
|
277
|
+
logger.info(f"Output file: {result_file}")
|
|
278
|
+
else:
|
|
279
|
+
logger.error("Fail to write compared result file.")
|
|
278
280
|
|
|
279
281
|
return ret
|
fosslight_scanner/cli.py
CHANGED
|
@@ -74,9 +74,9 @@ def main():
|
|
|
74
74
|
dest='path', nargs='+', default="")
|
|
75
75
|
parser.add_argument('--wget', '-w', help='Link to be analyzed',
|
|
76
76
|
type=str, dest='link', default="")
|
|
77
|
-
parser.add_argument('--
|
|
77
|
+
parser.add_argument('--formats', '-f',
|
|
78
78
|
help='Scanner output file format (excel,yaml), Compare mode (excel,html,yaml,json)',
|
|
79
|
-
type=str, dest='format', default=
|
|
79
|
+
type=str, dest='format',nargs='*', default=[])
|
|
80
80
|
parser.add_argument('--output', '-o', help='Output directory or file',
|
|
81
81
|
type=str, dest='output', default="")
|
|
82
82
|
parser.add_argument('--dependency', '-d', help='Dependency arguments',
|
|
@@ -12,6 +12,7 @@ import yaml
|
|
|
12
12
|
import shutil
|
|
13
13
|
import shlex
|
|
14
14
|
import subprocess
|
|
15
|
+
import platform
|
|
15
16
|
from pathlib import Path
|
|
16
17
|
from datetime import datetime
|
|
17
18
|
|
|
@@ -23,7 +24,8 @@ from ._get_input import get_input_mode
|
|
|
23
24
|
from fosslight_util.set_log import init_log
|
|
24
25
|
from fosslight_util.timer_thread import TimerThread
|
|
25
26
|
import fosslight_util.constant as constant
|
|
26
|
-
from fosslight_util.output_format import
|
|
27
|
+
from fosslight_util.output_format import check_output_formats_v2
|
|
28
|
+
from fosslight_prechecker._precheck import run_lint as prechecker_lint
|
|
27
29
|
from fosslight_util.cover import CoverItem
|
|
28
30
|
from fosslight_util.oss_item import ScannerItem
|
|
29
31
|
from fosslight_util.output_format import write_output_file
|
|
@@ -50,12 +52,12 @@ _start_time = ""
|
|
|
50
52
|
_executed_path = ""
|
|
51
53
|
SRC_DIR_FROM_LINK_PREFIX = "fosslight_src_dir_"
|
|
52
54
|
SCANNER_MODE = [
|
|
53
|
-
"all", "compare", "binary",
|
|
55
|
+
"all", "compare", "reuse", "prechecker", "binary",
|
|
54
56
|
"bin", "src", "source", "dependency", "dep"
|
|
55
57
|
]
|
|
56
58
|
|
|
57
59
|
|
|
58
|
-
def run_dependency(path_to_analyze, output_file_with_path, params="", path_to_exclude=[]):
|
|
60
|
+
def run_dependency(path_to_analyze, output_file_with_path, params="", path_to_exclude=[], formats=[]):
|
|
59
61
|
result = []
|
|
60
62
|
|
|
61
63
|
package_manager = ""
|
|
@@ -98,7 +100,7 @@ def run_dependency(path_to_analyze, output_file_with_path, params="", path_to_ex
|
|
|
98
100
|
output_file_with_path,
|
|
99
101
|
pip_activate_cmd, pip_deactivate_cmd,
|
|
100
102
|
output_custom_dir, app_name,
|
|
101
|
-
github_token, path_to_exclude=path_to_exclude
|
|
103
|
+
github_token, formats, True, path_to_exclude=path_to_exclude
|
|
102
104
|
)
|
|
103
105
|
if success:
|
|
104
106
|
result = scan_item
|
|
@@ -113,33 +115,62 @@ def source_analysis_wrapper(*args, **kwargs):
|
|
|
113
115
|
source_write_json_file = kwargs.pop('source_write_json_file', False)
|
|
114
116
|
source_print_matched_text = kwargs.pop('source_print_matched_text', False)
|
|
115
117
|
source_time_out = kwargs.pop('source_time_out', 120)
|
|
118
|
+
formats = kwargs.pop('formats', [])
|
|
116
119
|
args = list(args)
|
|
117
120
|
args.insert(2, source_write_json_file)
|
|
118
121
|
args.insert(5, source_print_matched_text)
|
|
122
|
+
args.insert(6, formats)
|
|
119
123
|
|
|
120
124
|
return source_analysis(*args, selected_scanner=selected_scanner, time_out=source_time_out, **kwargs)
|
|
121
125
|
|
|
122
126
|
|
|
123
127
|
def run_scanner(src_path, dep_arguments, output_path, keep_raw_data=False,
|
|
124
128
|
run_src=True, run_bin=True, run_dep=True, run_prechecker=False,
|
|
125
|
-
remove_src_data=True, result_log={},
|
|
126
|
-
|
|
129
|
+
remove_src_data=True, result_log={}, output_files=[],
|
|
130
|
+
output_extensions=[], num_cores=-1, db_url="",
|
|
127
131
|
default_oss_name="", default_oss_version="", url="",
|
|
128
132
|
correct_mode=True, correct_fpath="", ui_mode=False, path_to_exclude=[],
|
|
129
133
|
selected_source_scanner="all", source_write_json_file=False, source_print_matched_text=False,
|
|
130
|
-
source_time_out=120, binary_simple=False):
|
|
134
|
+
source_time_out=120, binary_simple=False, formats=[]):
|
|
131
135
|
final_excel_dir = output_path
|
|
132
136
|
success = True
|
|
133
137
|
all_cover_items = []
|
|
134
138
|
all_scan_item = ScannerItem(PKG_NAME, _start_time)
|
|
139
|
+
_json_ext = '.json'
|
|
135
140
|
if not remove_src_data:
|
|
136
141
|
success, final_excel_dir, result_log = init(output_path)
|
|
137
142
|
|
|
138
|
-
if
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
+
if not output_files:
|
|
144
|
+
# If -o does not contains file name, set default name
|
|
145
|
+
while len(output_files) < len(output_extensions):
|
|
146
|
+
output_files.append(None)
|
|
147
|
+
to_remove = [] # elements of spdx format on windows that should be removed
|
|
148
|
+
for i, output_extension in enumerate(output_extensions):
|
|
149
|
+
if output_files[i] is None or output_files[i] == "":
|
|
150
|
+
if formats:
|
|
151
|
+
if formats[i].startswith('spdx'):
|
|
152
|
+
if platform.system() != 'Windows':
|
|
153
|
+
output_files[i] = f"fosslight_spdx_all_{_start_time}"
|
|
154
|
+
else:
|
|
155
|
+
logger.warning('spdx format is not supported on Windows. Please remove spdx from format.')
|
|
156
|
+
to_remove.append(i)
|
|
157
|
+
else:
|
|
158
|
+
if output_extension == _json_ext:
|
|
159
|
+
output_files[i] = f"fosslight_opossum_all_{_start_time}"
|
|
160
|
+
else:
|
|
161
|
+
output_files[i] = f"fosslight_report_all_{_start_time}"
|
|
162
|
+
else:
|
|
163
|
+
if output_extension == _json_ext:
|
|
164
|
+
output_files[i] = f"fosslight_opossum_all_{_start_time}"
|
|
165
|
+
else:
|
|
166
|
+
output_files[i] = f"fosslight_report_all_{_start_time}"
|
|
167
|
+
for index in sorted(to_remove, reverse=True):
|
|
168
|
+
# remove elements of spdx format on windows
|
|
169
|
+
del output_files[index]
|
|
170
|
+
del output_extensions[index]
|
|
171
|
+
del formats[index]
|
|
172
|
+
if len(output_extensions) < 1:
|
|
173
|
+
sys.exit(0)
|
|
143
174
|
|
|
144
175
|
if not correct_fpath:
|
|
145
176
|
correct_fpath = src_path
|
|
@@ -149,14 +180,16 @@ def run_scanner(src_path, dep_arguments, output_path, keep_raw_data=False,
|
|
|
149
180
|
abs_path = os.path.abspath(src_path)
|
|
150
181
|
|
|
151
182
|
if success:
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
183
|
+
if run_prechecker:
|
|
184
|
+
success, result = call_analysis_api(src_path, "Prechecker Lint",
|
|
185
|
+
-1, prechecker_lint,
|
|
186
|
+
abs_path, False, _output_dir,
|
|
187
|
+
exclude_path=path_to_exclude)
|
|
155
188
|
|
|
156
189
|
if run_src:
|
|
157
190
|
try:
|
|
158
191
|
if fosslight_source_installed:
|
|
159
|
-
src_output =
|
|
192
|
+
src_output = _output_dir
|
|
160
193
|
success, result = call_analysis_api(
|
|
161
194
|
src_path,
|
|
162
195
|
"Source Analysis",
|
|
@@ -169,17 +202,17 @@ def run_scanner(src_path, dep_arguments, output_path, keep_raw_data=False,
|
|
|
169
202
|
selected_scanner=selected_source_scanner,
|
|
170
203
|
source_write_json_file=source_write_json_file,
|
|
171
204
|
source_print_matched_text=source_print_matched_text,
|
|
172
|
-
source_time_out=source_time_out
|
|
205
|
+
source_time_out=source_time_out,
|
|
206
|
+
formats=formats
|
|
173
207
|
)
|
|
174
208
|
if success:
|
|
175
209
|
all_scan_item.file_items.update(result[2].file_items)
|
|
176
210
|
all_cover_items.append(result[2].cover)
|
|
177
211
|
|
|
178
212
|
else: # Run fosslight_source by using docker image
|
|
179
|
-
src_output = os.path.join("output", output_files["SRC"])
|
|
180
213
|
output_rel_path = os.path.relpath(abs_path, os.getcwd())
|
|
181
214
|
command = shlex.quote(f"docker run -it -v {_output_dir}:/app/output "
|
|
182
|
-
f"fosslight -p {output_rel_path} -o
|
|
215
|
+
f"fosslight -p {output_rel_path} -o output")
|
|
183
216
|
if path_to_exclude:
|
|
184
217
|
command += f" -e {' '.join(path_to_exclude)}"
|
|
185
218
|
command_result = subprocess.run(command, stdout=subprocess.PIPE, text=True)
|
|
@@ -192,8 +225,8 @@ def run_scanner(src_path, dep_arguments, output_path, keep_raw_data=False,
|
|
|
192
225
|
success, result = call_analysis_api(src_path, "Binary Analysis",
|
|
193
226
|
1, binary_analysis.find_binaries,
|
|
194
227
|
abs_path,
|
|
195
|
-
|
|
196
|
-
|
|
228
|
+
_output_dir,
|
|
229
|
+
formats, db_url, binary_simple,
|
|
197
230
|
correct_mode, correct_fpath,
|
|
198
231
|
path_to_exclude=path_to_exclude)
|
|
199
232
|
if success:
|
|
@@ -201,11 +234,10 @@ def run_scanner(src_path, dep_arguments, output_path, keep_raw_data=False,
|
|
|
201
234
|
all_cover_items.append(result.cover)
|
|
202
235
|
|
|
203
236
|
if run_dep:
|
|
204
|
-
dep_scanitem = run_dependency(src_path,
|
|
205
|
-
dep_arguments, path_to_exclude)
|
|
237
|
+
dep_scanitem = run_dependency(src_path, _output_dir,
|
|
238
|
+
dep_arguments, path_to_exclude, formats)
|
|
206
239
|
all_scan_item.file_items.update(dep_scanitem.file_items)
|
|
207
240
|
all_cover_items.append(dep_scanitem.cover)
|
|
208
|
-
|
|
209
241
|
else:
|
|
210
242
|
return
|
|
211
243
|
|
|
@@ -213,8 +245,6 @@ def run_scanner(src_path, dep_arguments, output_path, keep_raw_data=False,
|
|
|
213
245
|
logger.error(f"Scanning: {ex}")
|
|
214
246
|
|
|
215
247
|
try:
|
|
216
|
-
output_file_without_ext = os.path.join(final_excel_dir, output_file)
|
|
217
|
-
final_report = f"{output_file_without_ext}{output_extension}"
|
|
218
248
|
cover = CoverItem(tool_name=PKG_NAME,
|
|
219
249
|
start_time=_start_time,
|
|
220
250
|
input_path=abs_path,
|
|
@@ -231,17 +261,32 @@ def run_scanner(src_path, dep_arguments, output_path, keep_raw_data=False,
|
|
|
231
261
|
|
|
232
262
|
if remove_src_data:
|
|
233
263
|
all_scan_item = update_oss_item(all_scan_item, default_oss_name, default_oss_version, url)
|
|
234
|
-
|
|
264
|
+
|
|
265
|
+
combined_paths_and_files = [os.path.join(final_excel_dir, file) for file in output_files]
|
|
266
|
+
results = []
|
|
267
|
+
final_reports = []
|
|
268
|
+
for combined_path_and_file, output_extension, output_format in zip(combined_paths_and_files, output_extensions, formats):
|
|
269
|
+
results.append(write_output_file(combined_path_and_file, output_extension, all_scan_item, {}, {}, output_format))
|
|
270
|
+
for success, msg, result_file in results:
|
|
271
|
+
if success:
|
|
272
|
+
final_reports.append(result_file)
|
|
273
|
+
logger.info(f"Output file: {result_file}")
|
|
274
|
+
else:
|
|
275
|
+
logger.error(f"Fail to generate result file {result_file}. msg:({msg})")
|
|
276
|
+
|
|
235
277
|
if success:
|
|
236
|
-
if
|
|
237
|
-
logger.info(f'Generated the result file: {
|
|
238
|
-
result_log["Output File"] =
|
|
278
|
+
if final_reports:
|
|
279
|
+
logger.info(f'Generated the result file: {", ".join(final_reports)}')
|
|
280
|
+
result_log["Output File"] = ', '.join(final_reports)
|
|
239
281
|
else:
|
|
240
282
|
result_log["Output File"] = 'Nothing is detected from the scanner so output file is not generated.'
|
|
241
|
-
else:
|
|
242
|
-
logger.error(f"Fail to generate a result file({final_report}): {err_msg}")
|
|
243
283
|
|
|
244
284
|
if ui_mode:
|
|
285
|
+
if output_files:
|
|
286
|
+
output_file = output_files[0]
|
|
287
|
+
else:
|
|
288
|
+
output_file = OUTPUT_REPORT_PREFIX + _start_time
|
|
289
|
+
output_file_without_ext = os.path.join(final_excel_dir, output_file)
|
|
245
290
|
ui_mode_report = f"{output_file_without_ext}.json"
|
|
246
291
|
success, err_msg = create_scancodejson(all_scan_item, ui_mode_report, src_path)
|
|
247
292
|
if success and os.path.isfile(ui_mode_report):
|
|
@@ -320,7 +365,7 @@ def run_main(mode_list, path_arg, dep_arguments, output_file_or_dir, file_format
|
|
|
320
365
|
source_time_out=120, binary_simple=False):
|
|
321
366
|
global _executed_path, _start_time
|
|
322
367
|
|
|
323
|
-
|
|
368
|
+
output_files = []
|
|
324
369
|
default_oss_name = ""
|
|
325
370
|
default_oss_version = ""
|
|
326
371
|
src_path = ""
|
|
@@ -344,7 +389,7 @@ def run_main(mode_list, path_arg, dep_arguments, output_file_or_dir, file_format
|
|
|
344
389
|
logger.error("Enter two FOSSLight report file with 'p' option.")
|
|
345
390
|
return False
|
|
346
391
|
else:
|
|
347
|
-
CUSTOMIZED_FORMAT = {
|
|
392
|
+
CUSTOMIZED_FORMAT = {}
|
|
348
393
|
if isinstance(path_arg, list):
|
|
349
394
|
if len(path_arg) == 1:
|
|
350
395
|
src_path = path_arg[0]
|
|
@@ -362,10 +407,12 @@ def run_main(mode_list, path_arg, dep_arguments, output_file_or_dir, file_format
|
|
|
362
407
|
else:
|
|
363
408
|
logger.warning(f"Cannot analyze with multiple path: {path_arg}")
|
|
364
409
|
|
|
365
|
-
success, msg, output_path,
|
|
366
|
-
|
|
410
|
+
success, msg, output_path, output_files, output_extensions, formats = check_output_formats_v2(output_file_or_dir, file_format,
|
|
411
|
+
CUSTOMIZED_FORMAT)
|
|
367
412
|
if output_path == "":
|
|
368
413
|
output_path = _executed_path
|
|
414
|
+
else:
|
|
415
|
+
output_path = os.path.abspath(output_path)
|
|
369
416
|
|
|
370
417
|
if not success:
|
|
371
418
|
logger.error(msg)
|
|
@@ -384,18 +431,24 @@ def run_main(mode_list, path_arg, dep_arguments, output_file_or_dir, file_format
|
|
|
384
431
|
ret, final_excel_dir, result_log = init(output_path)
|
|
385
432
|
|
|
386
433
|
run_compare(os.path.join(_executed_path, before_comp_f), os.path.join(_executed_path, after_comp_f),
|
|
387
|
-
final_excel_dir,
|
|
434
|
+
final_excel_dir, output_files, output_extensions, _start_time, _output_dir)
|
|
388
435
|
else:
|
|
389
436
|
run_src = False
|
|
390
437
|
run_bin = False
|
|
391
438
|
run_dep = False
|
|
439
|
+
run_prechecker = False
|
|
392
440
|
remove_downloaded_source = False
|
|
393
441
|
|
|
394
442
|
if "all" in mode_list or (not mode_list):
|
|
395
443
|
run_src = True
|
|
396
444
|
run_bin = True
|
|
397
445
|
run_dep = True
|
|
446
|
+
run_prechecker = False
|
|
447
|
+
if "prechecker" in mode_list or "reuse" in mode_list:
|
|
448
|
+
run_prechecker = True
|
|
398
449
|
else:
|
|
450
|
+
if "prechecker" in mode_list or "reuse" in mode_list:
|
|
451
|
+
run_prechecker = True
|
|
399
452
|
if "binary" in mode_list or "bin" in mode_list:
|
|
400
453
|
run_bin = True
|
|
401
454
|
if "source" in mode_list or "src" in mode_list:
|
|
@@ -403,7 +456,7 @@ def run_main(mode_list, path_arg, dep_arguments, output_file_or_dir, file_format
|
|
|
403
456
|
if "dependency" in mode_list or "dep" in mode_list:
|
|
404
457
|
run_dep = True
|
|
405
458
|
|
|
406
|
-
if run_dep or run_src or run_bin:
|
|
459
|
+
if run_dep or run_src or run_bin or run_prechecker:
|
|
407
460
|
if src_path == "" and url_to_analyze == "":
|
|
408
461
|
src_path, dep_arguments, url_to_analyze = get_input_mode(_executed_path, mode_list)
|
|
409
462
|
|
|
@@ -416,22 +469,15 @@ def run_main(mode_list, path_arg, dep_arguments, output_file_or_dir, file_format
|
|
|
416
469
|
remove_downloaded_source = True
|
|
417
470
|
success, src_path, default_oss_name, default_oss_version = download_source(url_to_analyze, output_path)
|
|
418
471
|
|
|
419
|
-
if output_extension == ".yaml":
|
|
420
|
-
correct_mode = False
|
|
421
|
-
correct_fpath = ""
|
|
422
|
-
else:
|
|
423
|
-
if not correct_fpath:
|
|
424
|
-
correct_fpath = src_path
|
|
425
|
-
|
|
426
472
|
if src_path != "":
|
|
427
473
|
run_scanner(src_path, dep_arguments, output_path, keep_raw_data,
|
|
428
|
-
run_src, run_bin, run_dep,
|
|
429
|
-
remove_downloaded_source, {},
|
|
430
|
-
|
|
474
|
+
run_src, run_bin, run_dep, run_prechecker,
|
|
475
|
+
remove_downloaded_source, {}, output_files,
|
|
476
|
+
output_extensions, num_cores, db_url,
|
|
431
477
|
default_oss_name, default_oss_version, url_to_analyze,
|
|
432
478
|
correct_mode, correct_fpath, ui_mode, path_to_exclude,
|
|
433
479
|
selected_source_scanner, source_write_json_file, source_print_matched_text, source_time_out,
|
|
434
|
-
binary_simple)
|
|
480
|
+
binary_simple, formats)
|
|
435
481
|
|
|
436
482
|
if extract_folder:
|
|
437
483
|
shutil.rmtree(extract_folder)
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: fosslight-scanner
|
|
3
|
-
Version: 2.
|
|
3
|
+
Version: 2.1.0
|
|
4
4
|
Summary: FOSSLight Scanner
|
|
5
5
|
Home-page: https://github.com/fosslight/fosslight_scanner
|
|
6
6
|
Author: LG Electronics
|
|
@@ -21,10 +21,11 @@ Requires-Dist: openpyxl
|
|
|
21
21
|
Requires-Dist: progress
|
|
22
22
|
Requires-Dist: pyyaml
|
|
23
23
|
Requires-Dist: beautifulsoup4
|
|
24
|
-
Requires-Dist: fosslight-util
|
|
25
|
-
Requires-Dist: fosslight-source
|
|
26
|
-
Requires-Dist: fosslight-dependency
|
|
27
|
-
Requires-Dist: fosslight-binary
|
|
24
|
+
Requires-Dist: fosslight-util<3.0.0,>=2.1.0
|
|
25
|
+
Requires-Dist: fosslight-source<3.0.0,>=2.1.0
|
|
26
|
+
Requires-Dist: fosslight-dependency<5.0.0,>=4.1.0
|
|
27
|
+
Requires-Dist: fosslight-binary<6.0.0,>=5.1.0
|
|
28
|
+
Requires-Dist: fosslight-prechecker<5.0.0,>=4.0.0
|
|
28
29
|
|
|
29
30
|
<!--
|
|
30
31
|
Copyright (c) 2021 LG Electronics
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
fosslight_scanner/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
2
|
+
fosslight_scanner/_get_input.py,sha256=f78M57QU7Lhw1VfZJKvYXbGsUiYMViPz1---UDIbV9I,1396
|
|
3
|
+
fosslight_scanner/_help.py,sha256=-Dqgn1inH26614GjrIe8I5cdEziuAxTtwrUdtTkrpjQ,3084
|
|
4
|
+
fosslight_scanner/_parse_setting.py,sha256=SoIEoPGlFXAp6__eEFEMIPYPoKLvmqxXF5X_C_uFiVI,2468
|
|
5
|
+
fosslight_scanner/_run_compare.py,sha256=zmzX-FIvWCSkwPvEA3iHfVpyg6QDGUCpw3tJuGLdPWM,10657
|
|
6
|
+
fosslight_scanner/cli.py,sha256=C4YNPVJJ-Ezj_6xe8k9QbIrf5V44GXbHWCGzR2FMcV8,6547
|
|
7
|
+
fosslight_scanner/common.py,sha256=NOfIxdKrH7MS_ptOIwY56OZJHVR9S_hfs-L2a1H9N0g,8179
|
|
8
|
+
fosslight_scanner/fosslight_scanner.py,sha256=raa6IKCWrTSO1kbPazHrZmY5CXjDzI_2jEstG6g-OhQ,21142
|
|
9
|
+
fosslight_scanner/resources/bom_compare.html,sha256=VocJ9bDmQQOwfGyvXatPZ4W-QddO-IlsAvKdO0nZ7pA,2240
|
|
10
|
+
fosslight_scanner-2.1.0.dist-info/LICENSE,sha256=xx0jnfkXJvxRnG63LTGOxlggYnIysveWIZ6H3PNdCrQ,11357
|
|
11
|
+
fosslight_scanner-2.1.0.dist-info/METADATA,sha256=F4YFBxqXCaKE9lZKVdkBTfGnyP2rxvNwOjjRdUMF3j0,7872
|
|
12
|
+
fosslight_scanner-2.1.0.dist-info/WHEEL,sha256=eOLhNAGa2EW3wWl_TU484h7q1UNgy0JXjjoqKoxAAQc,92
|
|
13
|
+
fosslight_scanner-2.1.0.dist-info/entry_points.txt,sha256=0tBUtN9pKtAkuohQuhbzuohdHbeoI0-w95aWAR7J_RU,105
|
|
14
|
+
fosslight_scanner-2.1.0.dist-info/top_level.txt,sha256=43_xLb5KYpy8wOU1H2Wd2fEsWBY7Dg6ZEJJXkfT64Ak,18
|
|
15
|
+
fosslight_scanner-2.1.0.dist-info/RECORD,,
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
fosslight_scanner/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
2
|
-
fosslight_scanner/_get_input.py,sha256=f78M57QU7Lhw1VfZJKvYXbGsUiYMViPz1---UDIbV9I,1396
|
|
3
|
-
fosslight_scanner/_help.py,sha256=-77CZm1es2Ib-HuISCSd4mTPxYzuLJ9NjryDI0g4otM,2921
|
|
4
|
-
fosslight_scanner/_parse_setting.py,sha256=SoIEoPGlFXAp6__eEFEMIPYPoKLvmqxXF5X_C_uFiVI,2468
|
|
5
|
-
fosslight_scanner/_run_compare.py,sha256=ufx3zldtM7sUOyQOYSgs66TY5-Gt26yE2Irz5kdkmio,10566
|
|
6
|
-
fosslight_scanner/cli.py,sha256=K088vCNTBLaiOfxW2EDkrWRhrRs7IILmDfP1HSdSI2U,6536
|
|
7
|
-
fosslight_scanner/common.py,sha256=NOfIxdKrH7MS_ptOIwY56OZJHVR9S_hfs-L2a1H9N0g,8179
|
|
8
|
-
fosslight_scanner/fosslight_scanner.py,sha256=fIP4SJ3zN8E-QeChgmh5fNj4nO3eD-a5kVZ7SoAcz3s,18693
|
|
9
|
-
fosslight_scanner/resources/bom_compare.html,sha256=VocJ9bDmQQOwfGyvXatPZ4W-QddO-IlsAvKdO0nZ7pA,2240
|
|
10
|
-
fosslight_scanner-2.0.0.dist-info/LICENSE,sha256=xx0jnfkXJvxRnG63LTGOxlggYnIysveWIZ6H3PNdCrQ,11357
|
|
11
|
-
fosslight_scanner-2.0.0.dist-info/METADATA,sha256=SjHAGy0zLaC6FQxJDMsxHmcBopgW8VR4kp3fNj23yJ8,7794
|
|
12
|
-
fosslight_scanner-2.0.0.dist-info/WHEEL,sha256=eOLhNAGa2EW3wWl_TU484h7q1UNgy0JXjjoqKoxAAQc,92
|
|
13
|
-
fosslight_scanner-2.0.0.dist-info/entry_points.txt,sha256=0tBUtN9pKtAkuohQuhbzuohdHbeoI0-w95aWAR7J_RU,105
|
|
14
|
-
fosslight_scanner-2.0.0.dist-info/top_level.txt,sha256=43_xLb5KYpy8wOU1H2Wd2fEsWBY7Dg6ZEJJXkfT64Ak,18
|
|
15
|
-
fosslight_scanner-2.0.0.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|