Skip to content

Commit f1eeff4

Browse files
committed
Make all deprecation warnings DeprecationWarnings
Signed-off-by: John Pennycook <john.pennycook@intel.com>
1 parent b86226c commit f1eeff4

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

bin/codebasin

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -174,6 +174,7 @@ def main():
174174
elif args.rootdir:
175175
warnings.warn(
176176
"--rootdir (-r) is deprecated. Use --source-dir (-S) instead.",
177+
DeprecationWarning,
177178
)
178179
rootpath = args.rootdir
179180
rootdir = os.path.realpath(rootpath)
@@ -210,7 +211,10 @@ def main():
210211
len(additional_platforms) == 0 and args.analysis_file is None
211212
)
212213
if config_file is None and config_required:
213-
warnings.warn("Implicitly defined configuration files are deprecated.")
214+
warnings.warn(
215+
"Implicitly defined configuration files are deprecated.",
216+
DeprecationWarning,
217+
)
214218
config_file = os.path.join(rootdir, "config.yaml")
215219
if not os.path.exists(config_file):
216220
raise RuntimeError(f"Could not find config file {config_file}")
@@ -230,6 +234,7 @@ def main():
230234
warnings.warn(
231235
"YAML configuration files are deprecated. "
232236
+ "Use TOML analysis files instead.",
237+
DeprecationWarning,
233238
)
234239
if not util.ensure_yaml(config_file):
235240
logging.getLogger("codebasin").error(

0 commit comments

Comments
 (0)