Skip to content

Commit 87cbffd

Browse files
authored
Merge pull request #69 from Pennycook/fix-deprecation-warnings
Make all deprecation warnings DeprecationWarnings
2 parents e853423 + f1eeff4 commit 87cbffd

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
@@ -175,6 +175,7 @@ def main():
175175
elif args.rootdir:
176176
warnings.warn(
177177
"--rootdir (-r) is deprecated. Use --source-dir (-S) instead.",
178+
DeprecationWarning,
178179
)
179180
rootpath = args.rootdir
180181
rootdir = os.path.realpath(rootpath)
@@ -211,7 +212,10 @@ def main():
211212
len(additional_platforms) == 0 and args.analysis_file is None
212213
)
213214
if config_file is None and config_required:
214-
warnings.warn("Implicitly defined configuration files are deprecated.")
215+
warnings.warn(
216+
"Implicitly defined configuration files are deprecated.",
217+
DeprecationWarning,
218+
)
215219
config_file = os.path.join(rootdir, "config.yaml")
216220
if not os.path.exists(config_file):
217221
raise RuntimeError(f"Could not find config file {config_file}")
@@ -231,6 +235,7 @@ def main():
231235
warnings.warn(
232236
"YAML configuration files are deprecated. "
233237
+ "Use TOML analysis files instead.",
238+
DeprecationWarning,
234239
)
235240
if not util.ensure_yaml(config_file):
236241
logging.getLogger("codebasin").error(

0 commit comments

Comments
 (0)