Repository: aeturrell/skimpy

Issue:
Explore switching docs to Quartodoc
https://github.com/machow/quartodoc

Main advantage is to remove hackyness of current solution.


Discussion:

Resolving patch:
diff --git a/noxfile.py b/noxfile.py
--- a/noxfile.py
+++ b/noxfile.py
@@ -19,7 +19,7 @@
 
 
 package = "skimpy"
-python_versions = ["3.10", "3.9", "3.8"]
+python_versions = ["3.11", "3.10", "3.9"]
 nox.needs_version = ">= 2021.6.6"
 nox.options.sessions = (
     "pre-commit",
diff --git a/src/skimpy/__init__.py b/src/skimpy/__init__.py
--- a/src/skimpy/__init__.py
+++ b/src/skimpy/__init__.py
@@ -638,14 +638,14 @@ def skim(
     --------
     Skim a dataframe
 
-    >>> df = pd.DataFrame(
-            {
-             'col1': ['Philip', 'Turanga', 'bob'],
-             'col2': [50, 100, 70],
-             'col3': [False, True, True]
-            })
-    >>> df["col1"] = df["col1"].astype("string")
-    >>> skim(df)
+        >>> df = pd.DataFrame(
+                {
+                'col1': ['Philip', 'Turanga', 'bob'],
+                'col2': [50, 100, 70],
+                'col3': [False, True, True]
+                })
+        >>> df["col1"] = df["col1"].astype("string")
+        >>> skim(df)
     """
     if hasattr(df_in, "name") and "name" not in df_in.columns:
         name = df_in.name
@@ -752,21 +752,21 @@ def clean_columns(
     replace: Optional[Dict[str, str]] = None,
     remove_accents: bool = True,
 ) -> pd.DataFrame:
-    """Clean messy column names of a pandas dataframe.
+    """Clean messy column names in a pandas dataframe.
 
     Args:
         df (pd.DataFrame): Dataframe from which column names are to be cleaned.
         case (str, optional): The desired case style of the column name. Defaults to "snake".
 
-                - 'snake': 'column_name'
-                - 'kebab': 'column-name'
-                - 'camel': 'columnName'
-                - 'pascal': 'ColumnName'
-                - 'const': 'COLUMN_NAME'
-                - 'sentence': 'Column name'
-                - 'title': 'Column Name'
-                - 'lower': 'column name'
-                - 'upper': 'COLUMN NAME'
+                - 'snake' produces 'column_name';
+                - 'kebab' produces 'column-name';
+                - 'camel' produces 'columnName';
+                - 'pascal' produces 'ColumnName';
+                - 'const' produces 'COLUMN_NAME';
+                - 'sentence' produces 'Column name';
+                - 'title' produces 'Column Name';
+                - 'lower' produces 'column name';
+                - 'upper' produces 'COLUMN NAME';
 
         replace (Optional[Dict[str, str]], optional): Values to replace in the column names. Defaults to None.
 
@@ -785,17 +785,17 @@ def clean_columns(
     Clean column names by converting the names to camel case style, removing accents,
     and correcting a mispelling.
 
-    >>> df = pd.DataFrame(
-                          {
-                           'FirstNom': ['Philip', 'Turanga'],
-                           'lastName': ['Fry', 'Leela'],
-                           'Téléphone': ['555-234-5678', '(604) 111-2335']
-                          })
-
-    >>> clean_columns(df, case='camel', replace={'Nom': 'Name'})
-      firstName lastName       telephone
-    0    Philip      Fry    555-234-5678
-    1   Turanga    Leela  (604) 111-2335
+        >>> df = pd.DataFrame(
+                            {
+                            'FirstNom': ['Philip', 'Turanga'],
+                            'lastName': ['Fry', 'Leela'],
+                            'Téléphone': ['555-234-5678', '(604) 111-2335']
+                            })
+
+        >>> clean_columns(df, case='camel', replace={'Nom': 'Name'})
+        firstName lastName       telephone
+        0    Philip      Fry    555-234-5678
+        1   Turanga    Leela  (604) 111-2335
     """
     if case not in CASE_STYLES:
         raise ValueError(
@@ -936,7 +936,7 @@ def _rename_duplicates(names: pd.Index | list[str], case: str) -> Any:
 
 @typechecked
 def generate_test_data() -> pd.DataFrame:
-    """Generate dataframe with several different datatypes.
+    """Generate a pandas dataframe with several different datatypes.
 
     For testing skimpy, it's convenient to have a dataset with many different
     data types. This function creates that dataframe.
@@ -948,7 +948,7 @@ def generate_test_data() -> pd.DataFrame:
     --------
     Generate test data to demonstrate how skimpy works.
 
-    >>> df = generate_test_data()
+        >>> df = generate_test_data()
     """
     seed = 34729
     rng = Generator(PCG64(seed))


Test patch:
diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml
--- a/.github/workflows/tests.yml
+++ b/.github/workflows/tests.yml
@@ -15,10 +15,10 @@ jobs:
           - { python-version: 3.9, os: ubuntu-latest, session: "pre-commit" }
           - { python-version: 3.9, os: ubuntu-latest, session: "safety" }
           - { python-version: 3.9, os: ubuntu-latest, session: "mypy" }
-          - { python-version: 3.8, os: ubuntu-latest, session: "mypy" }
+          - { python-version: "3.11", os: ubuntu-latest, session: "mypy" }
           - { python-version: "3.10", os: ubuntu-latest, session: "mypy" }
           - { python-version: 3.9, os: ubuntu-latest, session: "tests" }
-          - { python-version: 3.8, os: ubuntu-latest, session: "tests" }
+          - { python-version: "3.11", os: ubuntu-latest, session: "tests" }
           - { python-version: "3.10", os: ubuntu-latest, session: "tests" }
           - { python-version: 3.9, os: windows-latest, session: "tests" }
           - { python-version: 3.9, os: macos-latest, session: "tests" }