Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix PR06 issues in docstrings #28724

Closed
LauraCollard opened this issue Oct 1, 2019 · 11 comments · Fixed by #43511
Closed

Fix PR06 issues in docstrings #28724

LauraCollard opened this issue Oct 1, 2019 · 11 comments · Fixed by #43511
Assignees
Milestone

Comments

@LauraCollard
Copy link
Contributor

Fix the docstrings where there is an error in a parameter format, eg string instead of str.
Current errors:

pandas.Series.to_json: Parameter "indent" type should use "int" instead of "integer"
pandas.Timestamp.ceil: Parameter "freq" type should use "str" instead of "string"
pandas.Timestamp.day_name: Parameter "locale" type should use "str" instead of "string"
pandas.Timestamp.floor: Parameter "freq" type should use "str" instead of "string"
pandas.Timestamp.month_name: Parameter "locale" type should use "str" instead of "string"
pandas.Timestamp.round: Parameter "freq" type should use "str" instead of "string"
pandas.Timedelta: Parameter "value" type should use "int" instead of "integer"
pandas.Timedelta: Parameter "value" type should use "str" instead of "string"
pandas.Timedelta.max: Parameter "value" type should use "int" instead of "integer"
pandas.Timedelta.max: Parameter "value" type should use "str" instead of "string"
pandas.Timedelta.min: Parameter "value" type should use "int" instead of "integer"
pandas.Timedelta.min: Parameter "value" type should use "str" instead of "string"
pandas.Timedelta.ceil: Parameter "freq" type should use "str" instead of "string"
pandas.Timedelta.floor: Parameter "freq" type should use "str" instead of "string"
pandas.Timedelta.round: Parameter "freq" type should use "str" instead of "string"
pandas.Period.asfreq: Parameter "freq" type should use "str" instead of "string"
pandas.Period.to_timestamp: Parameter "freq" type should use "str" instead of "string"
pandas.arrays.IntervalArray.from_arrays: Parameter "copy" type should use "bool" instead of "boolean"
pandas.arrays.IntervalArray.from_tuples: Parameter "copy" type should use "bool" instead of "boolean"
pandas.arrays.IntervalArray.from_breaks: Parameter "copy" type should use "bool" instead of "boolean"
pandas.arrays.IntervalArray.to_tuples: Parameter "na_tuple" type should use "bool" instead of "boolean"
pandas.Categorical.from_codes: Parameter "codes" type should use "int" instead of "integer"
pandas.Categorical.from_codes: Parameter "dtype" type should use "str" instead of "string"
pandas.SparseArray: Parameter "kind" type should use "int" instead of "integer"
pandas.read_table: Parameter "cache_dates" type should use "bool" instead of "boolean"
pandas.read_csv: Parameter "cache_dates" type should use "bool" instead of "boolean"
pandas.read_msgpack: Parameter "iterator" type should use "bool" instead of "boolean"
pandas.ExcelWriter: Parameter "path" type should use "str" instead of "string"
pandas.ExcelWriter: Parameter "engine" type should use "str" instead of "string"
pandas.ExcelWriter: Parameter "date_format" type should use "str" instead of "string"
pandas.ExcelWriter: Parameter "datetime_format" type should use "str" instead of "string"
pandas.read_json: Parameter "orient" type should use "str" instead of "string"
pandas.read_html: Parameter "flavor" type should use "str" instead of "string"
pandas.HDFStore.append: Parameter "append      " type should use "bool" instead of "boolean"
pandas.HDFStore.append: Parameter "min_itemsize" type should use "str" instead of "string"
pandas.HDFStore.append: Parameter "nan_rep     " type should use "str" instead of "string"
pandas.HDFStore.append: Parameter "encoding    " type should use "str" instead of "string"
pandas.HDFStore.append: Parameter "dropna      " type should use "bool" instead of "boolean"
pandas.read_spss: Parameter "path" type should use "str" instead of "string"
pandas.read_sql_query: Parameter "sql" type should use "str" instead of "string"
pandas.read_sql_query: Parameter "con" type should use "str" instead of "string"
pandas.read_sql_query: Parameter "index_col" type should use "str" instead of "string"
pandas.read_sql_query: Parameter "coerce_float" type should use "bool" instead of "boolean"
pandas.read_sql: Parameter "sql" type should use "str" instead of "string"
pandas.read_sql: Parameter "con" type should use "str" instead of "string"
pandas.read_sql: Parameter "index_col" type should use "str" instead of "string"
pandas.read_sql: Parameter "coerce_float" type should use "bool" instead of "boolean"
pandas.read_gbq: Parameter "reauth" type should use "bool" instead of "boolean"
pandas.read_gbq: Parameter "auth_local_webserver" type should use "bool" instead of "boolean"
pandas.read_stata: Parameter "convert_dates" type should use "bool" instead of "boolean"
pandas.read_stata: Parameter "convert_categoricals" type should use "bool" instead of "boolean"
pandas.read_stata: Parameter "encoding" type should use "str" instead of "string"
pandas.read_stata: Parameter "index_col" type should use "str" instead of "string"
pandas.read_stata: Parameter "convert_missing" type should use "bool" instead of "boolean"
pandas.read_stata: Parameter "preserve_dtypes" type should use "bool" instead of "boolean"
pandas.read_stata: Parameter "order_categoricals" type should use "bool" instead of "boolean"
pandas.read_stata: Parameter "iterator" type should use "bool" instead of "boolean"
pandas.io.stata.StataReader.data: Parameter "convert_dates" type should use "bool" instead of "boolean"
pandas.io.stata.StataReader.data: Parameter "convert_categoricals" type should use "bool" instead of "boolean"
pandas.io.stata.StataReader.data: Parameter "index_col" type should use "str" instead of "string"
pandas.io.stata.StataReader.data: Parameter "convert_missing" type should use "bool" instead of "boolean"
pandas.io.stata.StataReader.data: Parameter "preserve_dtypes" type should use "bool" instead of "boolean"
pandas.io.stata.StataReader.data: Parameter "order_categoricals" type should use "bool" instead of "boolean"
pandas.core.resample.Resampler.pipe: Parameter "func" type should use "str" instead of "string"
pandas.testing.assert_frame_equal: Parameter "check_index_type" type should use "str" instead of "string"
pandas.testing.assert_frame_equal: Parameter "check_column_type" type should use "str" instead of "string"
pandas.testing.assert_series_equal: Parameter "check_index_type" type should use "str" instead of "string"
pandas.testing.assert_index_equal: Parameter "exact" type should use "str" instead of "string"
pandas.api.types.union_categoricals: Parameter "sort_categories" type should use "bool" instead of "boolean"
pandas.api.types.union_categoricals: Parameter "ignore_order" type should use "bool" instead of "boolean"
pandas.api.types.is_list_like: Parameter "allow_sets" type should use "bool" instead of "boolean"
pandas.qcut: Parameter "q" type should use "int" instead of "integer"
pandas.qcut: Parameter "labels" type should use "bool" instead of "boolean"
pandas.merge_asof: Parameter "left_index" type should use "bool" instead of "boolean"
pandas.merge_asof: Parameter "right_index" type should use "bool" instead of "boolean"
pandas.merge_asof: Parameter "tolerance" type should use "int" instead of "integer"
pandas.merge_asof: Parameter "allow_exact_matches" type should use "bool" instead of "boolean"
pandas.to_numeric: Parameter "downcast" type should use "int" instead of "integer"
pandas.period_range: Parameter "start" type should use "str" instead of "string"
pandas.period_range: Parameter "end" type should use "str" instead of "string"
pandas.period_range: Parameter "periods" type should use "int" instead of "integer"
pandas.period_range: Parameter "freq" type should use "str" instead of "string"
pandas.period_range: Parameter "name" type should use "str" instead of "string"
pandas.timedelta_range: Parameter "start" type should use "str" instead of "string"
pandas.timedelta_range: Parameter "end" type should use "str" instead of "string"
pandas.timedelta_range: Parameter "periods" type should use "int" instead of "integer"
pandas.timedelta_range: Parameter "freq" type should use "str" instead of "string"
pandas.timedelta_range: Parameter "name" type should use "str" instead of "string"
pandas.timedelta_range: Parameter "closed" type should use "str" instead of "string"
pandas.infer_freq: Parameter "warn" type should use "bool" instead of "boolean"
pandas.interval_range: Parameter "periods" type should use "int" instead of "integer"
pandas.interval_range: Parameter "freq" type should use "str" instead of "string"
pandas.interval_range: Parameter "name" type should use "str" instead of "string"
pandas.eval: Parameter "parser" type should use "str" instead of "string"
pandas.eval: Parameter "engine" type should use "str" instead of "string"
pandas.util.hash_array: Parameter "encoding" type should use "str" instead of "string"
pandas.util.hash_array: Parameter "hash_key" type should use "str" instead of "string"
pandas.util.hash_pandas_object: Parameter "index" type should use "bool" instead of "boolean"
pandas.util.hash_pandas_object: Parameter "encoding" type should use "str" instead of "string"
pandas.util.hash_pandas_object: Parameter "hash_key" type should use "str" instead of "string"
pandas.Index.shift: Parameter "freq" type should use "str" instead of "string"
pandas.CategoricalIndex: Parameter "dtype" type should use "str" instead of "string"
pandas.IntervalIndex.from_arrays: Parameter "copy" type should use "bool" instead of "boolean"
pandas.IntervalIndex.from_tuples: Parameter "copy" type should use "bool" instead of "boolean"
pandas.IntervalIndex.from_breaks: Parameter "copy" type should use "bool" instead of "boolean"
pandas.IntervalIndex.to_tuples: Parameter "na_tuple" type should use "bool" instead of "boolean"
pandas.MultiIndex.to_frame: Parameter "index" type should use "bool" instead of "boolean"
pandas.MultiIndex.to_frame: Parameter "name" type should use "str" instead of "string"
pandas.MultiIndex.sortlevel: Parameter "ascending" type should use "bool" instead of "boolean"
pandas.DatetimeIndex.indexer_at_time: Parameter "time" type should use "str" instead of "string"
pandas.PeriodIndex: Parameter "data" type should use "int" instead of "integer"
pandas.PeriodIndex: Parameter "freq" type should use "str" instead of "string"
pandas.PeriodIndex.to_timestamp: Parameter "freq" type should use "str" instead of "string"
pandas.core.groupby.GroupBy.pipe: Parameter "func" type should use "str" instead of "string"
pandas.core.groupby.DataFrameGroupBy.idxmax: Parameter "skipna" type should use "bool" instead of "boolean"
pandas.core.groupby.DataFrameGroupBy.idxmin: Parameter "skipna" type should use "bool" instead of "boolean"
pandas.core.groupby.DataFrameGroupBy.nunique: Parameter "dropna" type should use "bool" instead of "boolean"
pandas.core.groupby.DataFrameGroupBy.shift: Parameter "freq" type should use "str" instead of "string"
pandas.io.formats.style.Styler.set_table_attributes: Parameter "attributes" type should use "str" instead of "string"
pandas.api.extensions.ExtensionArray._from_sequence: Parameter "copy" type should use "bool" instead of "boolean"
pandas.api.extensions.ExtensionArray._from_sequence_of_strings: Parameter "copy" type should use "bool" instead of "boolean"
pandas.api.extensions.ExtensionArray.take: Parameter "indices" type should use "int" instead of "integer"
pandas.DataFrame.idxmax: Parameter "skipna" type should use "bool" instead of "boolean"
pandas.DataFrame.idxmin: Parameter "skipna" type should use "bool" instead of "boolean"
pandas.DataFrame.unstack: Parameter "fill_value" type should use "str" instead of "string"
pandas.DataFrame.to_json: Parameter "indent" type should use "int" instead of "integer"
@LauraCollard
Copy link
Contributor Author

I'm working on issues in pandas.DataFrame, pandas.ExcelWriter, pandas.arrays.IntervalArray and pandas.timedelta_range.

@samyak-jn
Copy link
Contributor

Hey, I want to start contributing, can I take some from to leftover to get myself started?

@samyak-jn
Copy link
Contributor

I have worked on the issue pandas.interval_range, pandas.util.hash_array and pandas.util.hash_pandas_object.
Can someone please review and help me to correct if I'm wrong!

@jbrockmendel
Copy link
Member

Can we turn the list in the OP into checkboxes and update it so we can see what still needs to be done

@Varun270
Copy link
Contributor

Hey, Is this issue still open? I am a newbie to Open Source and want to contribute.

@Varun270
Copy link
Contributor

take

@Varun270
Copy link
Contributor

@LauraCollard I am unable to locate the folders in order to fix this issue, Can you please tell me how many of them are fixed and which ones require fixing. Maybe using checkboxes will be more efficient and easy to understand.

@Varun270
Copy link
Contributor

Varun270 commented Sep 7, 2021

@MarcoGorelli I have checked all the files and this issue has already been resolved. I think you should close this issue.

@MarcoGorelli
Copy link
Member

Thanks @Varun270 - if you add PR06 to

pandas/ci/code_checks.sh

Lines 92 to 93 in 73c473d

MSG='Validate docstrings (GL02, GL03, GL04, GL05, GL06, GL07, GL09, GL10, SS01, SS02, SS04, SS05, PR03, PR04, PR05, PR10, EX04, RT01, RT04, RT05, SA02, SA03)' ; echo $MSG
$BASE_DIR/scripts/validate_docstrings.py --format=actions --errors=GL02,GL03,GL04,GL05,GL06,GL07,GL09,GL10,SS02,SS04,SS05,PR03,PR04,PR05,PR10,EX04,RT01,RT04,RT05,SA02,SA03

then that'll close the issue

@Varun270
Copy link
Contributor

Varun270 commented Sep 9, 2021

Okay sure

@Varun270
Copy link
Contributor

Varun270 commented Sep 9, 2021

@MarcoGorelli Just a silly question - What should I name the PR? Updated code_checks.sh? or should I mention the issue number too?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

8 participants