Skip to content

Commit

Permalink
Remove PudlTabl removal data and make assn table name sources alphabe…
Browse files Browse the repository at this point in the history
…tical
  • Loading branch information
bendnorman committed Nov 8, 2023
1 parent 85c6fe3 commit 479ec7f
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 13 deletions.
5 changes: 2 additions & 3 deletions docs/dev/naming_conventions.rst
Original file line number Diff line number Diff line change
Expand Up @@ -66,9 +66,8 @@ Naming convention: ``core_{source}__{asset_type}_{asset_name}``

* ``assn``: Association tables provide connections between entities. This data
can be manually compiled or extracted from data sources. If the asset associates
data from two sources, the source names should be included in the ``asset_name``.
The source names should appear in the same order for all assets that associate
the two sources. Examples:
data from two sources, the source names should be included in the ``asset_name``
in alphabetical order. Examples:

* ``core_pudl__assn_plants_eia`` associates EIA Plant IDs and manually assigned
PUDL Plant IDs.
Expand Down
7 changes: 3 additions & 4 deletions docs/release_notes.rst
Original file line number Diff line number Diff line change
Expand Up @@ -79,10 +79,9 @@ To help users migrate away from using ``PudlTabl`` and our temporary table names
we've created a `google sheet <https://docs.google.com/spreadsheets/d/1RBuKl_xKzRSLgRM7GIZbc5zUYieWFE20cXumWuv5njo/edit?usp=sharing>`__
that maps the old table names and ``PudlTabl`` methods to the new table names.

We plan to remove ``PudlTabl`` from the pudl package once our known users have
succesfully migrated to pulling data directly from ``pudl.sqlite``. We've added
deprecation warnings to the ``PudlTabl`` class. We expect to remove ``PudlTabl``
at the end of February 2024.
We've added deprecation warnings to the ``PudlTabl`` class. We plan to remove
``PudlTabl`` from the ``pudl`` package once our known users have
succesfully migrated to pulling data directly from ``pudl.sqlite``.

Data Coverage
^^^^^^^^^^^^^
Expand Down
12 changes: 6 additions & 6 deletions src/pudl/output/pudltabl.py
Original file line number Diff line number Diff line change
Expand Up @@ -90,10 +90,9 @@ def __init__(
individual generators to functional units. EXPERIMENTAL.
"""
logger.warning(
"PudlTabl is deprecated and will be removed from the pudl package"
"at the end of February 2024. To acccess the data returned by"
"this class, pull the desired table directly from the pudl.sqlite"
"database."
"PudlTabl is deprecated and will be removed from the pudl package "
"once known users have migrated to accessing the data directly from "
"pudl.sqlite. "
)
if not isinstance(pudl_engine, sa.engine.base.Engine):
raise TypeError(
Expand Down Expand Up @@ -303,8 +302,9 @@ def _get_table_from_db(
)
table_name = self._agg_table_name(table_name)
logger.warning(
"PudlTabl is deprecated and will be removed from the pudl package"
"at the end of February 2024. To access the data returned by this method,"
"PudlTabl is deprecated and will be removed from the pudl package "
"once known users have migrated to accessing the data directly from "
"pudl.sqlite. To access the data returned by this method, "
f"use the {table_name} table in the pudl.sqlite database."
)
resource = Resource.from_id(table_name)
Expand Down

0 comments on commit 479ec7f

Please sign in to comment.