Add code to disable pycache and fix imports
Changes:
- added cosmetic logging of YAML file path
- added code to disable pycache
- add manager_id default in ENV YAML
Tested:
- Ran on the local sandbox with the changes
Change-Id: I41874becb1d57966f9d61783187332319a415838
Signed-off-by: George Keishing <gkeishin@in.ibm.com>
diff --git a/ffdc/collect_ffdc.py b/ffdc/collect_ffdc.py
index 06c3e17..523373a 100644
--- a/ffdc/collect_ffdc.py
+++ b/ffdc/collect_ffdc.py
@@ -190,6 +190,8 @@
" \n\tERROR: Config file %s is not found. Please verify"
" path and filename." % config
)
+ else:
+ print(" \n\tLoading YAML File: %s" % config)
return all_options_ok
diff --git a/ffdc/ffdc_collector.py b/ffdc/ffdc_collector.py
index 7d51c7c..6cde65b 100644
--- a/ffdc/ffdc_collector.py
+++ b/ffdc/ffdc_collector.py
@@ -16,6 +16,9 @@
import yaml
+sys.dont_write_bytecode = True
+
+
script_dir = os.path.dirname(os.path.abspath(__file__))
sys.path.append(script_dir)
# Walk path and append to sys.path
diff --git a/ffdc/templates/env_vars_template.yaml b/ffdc/templates/env_vars_template.yaml
index c93515e..9453f88 100644
--- a/ffdc/templates/env_vars_template.yaml
+++ b/ffdc/templates/env_vars_template.yaml
@@ -8,3 +8,4 @@
var1: 1
var2: 2
var3: 3
+ manager_id: "bmc"