Page MenuHomeDevCentral

D3700.id9575.diff
No OneTemporary

D3700.id9575.diff

diff --git a/tools/nasqueron-reports/src/nasqueron_reports/actions/reports.py b/tools/nasqueron-reports/src/nasqueron_reports/actions/reports.py
--- a/tools/nasqueron-reports/src/nasqueron_reports/actions/reports.py
+++ b/tools/nasqueron-reports/src/nasqueron_reports/actions/reports.py
@@ -51,7 +51,9 @@
def wire(report_config):
if "connector" not in report_config["service_options"]:
service_name = report_config["service"]
- raise NasqueronReportConfigError(f"Service connector missing in configuration for service {service_name}")
+ raise NasqueronReportConfigError(
+ f"Service connector missing in configuration for service {service_name}"
+ )
if "format" not in report_config:
raise NasqueronReportConfigError(f"Format missing in report configuration")
diff --git a/tools/nasqueron-reports/src/nasqueron_reports/config.py b/tools/nasqueron-reports/src/nasqueron_reports/config.py
--- a/tools/nasqueron-reports/src/nasqueron_reports/config.py
+++ b/tools/nasqueron-reports/src/nasqueron_reports/config.py
@@ -31,7 +31,7 @@
DEFAULT_SQL_PATHS = [
".",
"/usr/local/share/nasqueron-reports",
- "/usr/share/nasqueron-reports"
+ "/usr/share/nasqueron-reports",
]
@@ -61,7 +61,9 @@
config_path = get_config_path()
if not config_path:
- raise NasqueronReportConfigError("You need to create a reports.yaml config file")
+ raise NasqueronReportConfigError(
+ "You need to create a reports.yaml config file"
+ )
with open(config_path) as fd:
config = yaml.safe_load(fd)
@@ -90,7 +92,9 @@
)
if "credentials" in report_config["service_options"]:
- credentials = resolve_credentials(report_config["service_options"]["credentials"])
+ credentials = resolve_credentials(
+ config, report_config["service_options"]["credentials"]
+ )
else:
credentials = {}
diff --git a/tools/nasqueron-reports/src/nasqueron_reports/credentials/credentials.py b/tools/nasqueron-reports/src/nasqueron_reports/credentials/credentials.py
--- a/tools/nasqueron-reports/src/nasqueron_reports/credentials/credentials.py
+++ b/tools/nasqueron-reports/src/nasqueron_reports/credentials/credentials.py
@@ -35,4 +35,4 @@
def read_environment(variables):
- return {k:os.environ.get(v, "") for k, v in variables.items()}
+ return {k: os.environ.get(v, "") for k, v in variables.items()}

File Metadata

Mime Type
text/plain
Expires
Tue, Sep 23, 00:40 (18 h, 31 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
3006418
Default Alt Text
D3700.id9575.diff (2 KB)

Event Timeline