Skip to content

Commit f459ed6

Browse files
authored
Improve the docstrings of the validate_output_table_type function (#3832)
1 parent d0296ef commit f459ed6

File tree

1 file changed

+5
-7
lines changed

1 file changed

+5
-7
lines changed

pygmt/helpers/validators.py

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -17,16 +17,15 @@ def validate_output_table_type(
1717
Parameters
1818
----------
1919
output_type
20-
Desired output type of tabular data. Valid values are ``"pandas"``,
21-
``"numpy"`` and ``"file"``.
20+
Desired output type of tabular data. Valid values are ``"pandas"``, ``"numpy"``,
21+
and ``"file"``.
2222
outfile
2323
File name for saving the result data. Required if ``output_type`` is ``"file"``.
2424
If specified, ``output_type`` will be forced to be ``"file"``.
2525
2626
Returns
2727
-------
28-
str
29-
The original or updated output type.
28+
The original or updated output type.
3029
3130
Examples
3231
--------
@@ -57,9 +56,8 @@ def validate_output_table_type(
5756
raise GMTInvalidInput(msg)
5857
if output_type != "file" and outfile is not None:
5958
msg = (
60-
f"Changing 'output_type' from '{output_type}' to 'file' "
61-
"since 'outfile' parameter is set. Please use output_type='file' "
62-
"to silence this warning."
59+
f"Changing 'output_type' from '{output_type}' to 'file' since 'outfile' "
60+
"parameter is set. Please use output_type='file' to suppress the warning."
6361
)
6462
warnings.warn(message=msg, category=RuntimeWarning, stacklevel=2)
6563
output_type = "file"

0 commit comments

Comments
 (0)