Skip to content

Commit

Permalink
Merge branch 'dev' into entity_matching
Browse files Browse the repository at this point in the history
  • Loading branch information
zaneselvans committed Dec 8, 2023
2 parents 9c6616f + 94bb8c5 commit 71347c9
Show file tree
Hide file tree
Showing 5 changed files with 27 additions and 16 deletions.
2 changes: 1 addition & 1 deletion .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ repos:
verbose: false
pass_filenames: false
always_run: true
entry: pytest --doctest-modules src/pudl test/unit
entry: pytest --doctest-modules src/pudl test/unit -m "not slow"

# Configuration for pre-commit.ci
ci:
Expand Down
31 changes: 17 additions & 14 deletions docs/release_notes.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,23 @@ PUDL Release Notes
=======================================================================================

---------------------------------------------------------------------------------------
v2023.XX.XX
v2023.12.XX
---------------------------------------------------------------------------------------
* The ``epacems_to_parquet`` and ``state_demand`` scripts have been retired in favor of
using the Dagster UI. See :issue:`3107` and :pr:`3086`. Visualizations of hourly
state-level electricity demand have been moved into our example notebooks which can
be found both `on Kaggle <https://www.kaggle.com/code/catalystcooperative/02-state-hourly-electricity-demand>`__
and `on GitHub <https://github.com/catalyst-cooperative/pudl-examples/>`__
* The ``pudl_setup`` script has been retired. All input/output locations are now set
using the ``$PUDL_INPUT`` and ``$PUDL_OUTPUT`` environment variables. See
:issue:`3107` and :pr:`3086`.
* The :func:`pudl.analysis.service_territory.pudl_service_territories` script has been
fixed, and can be used to generate `GeoParquet <https://geoparquet.org/>`__
outputs describing historical utility and balancing authority service territories. See
:issue:`1174` and :pr:`3086`.

---------------------------------------------------------------------------------------
v2023.12.01
---------------------------------------------------------------------------------------

Dagster Adoption
Expand Down Expand Up @@ -207,7 +223,6 @@ Data Coverage
centralized service companies. `FERC Form 60 will also be available on Datasette
<https://data.catalyst.coop/ferc6>`__.


Data Cleaning
^^^^^^^^^^^^^

Expand Down Expand Up @@ -274,10 +289,6 @@ Analysis
:ref:`compiled_geometry_utility_eia861`), and the estimated total hourly electricity
demand for each US state in :ref:`predicted_state_hourly_demand`. See :issue:`1973`
and :pr:`2550`.
* The :func:`pudl.analysis.service_territory.pudl_service_territories` script has been
fixed, and can be used to generate `GeoParquet <https://geoparquet.org/>`__
outputs describing historical utility and balancing authority service territories. See
:issue:`1174` and :pr:`3086`.

Deprecations
^^^^^^^^^^^^
Expand Down Expand Up @@ -316,14 +327,6 @@ Deprecations
:mod:`pudl.settings` no longer have table attributes because the ETL no longer
supports loading specific tables via settings. Use dagster to select subsets of
tables to process.
* The ``epacems_to_parquet`` and ``state_demand`` scripts have been retired in favor of
using the Dagster UI. See :issue:`3107` and :pr:`3086`. Visualizations of hourly
state-level electricity demand have been moved into our example notebooks which can
be found both `on Kaggle <https://www.kaggle.com/code/catalystcooperative/02-state-hourly-electricity-demand>`__
and `on GitHub <https://github.com/catalyst-cooperative/pudl-examples/>`__
* The ``pudl_setup`` script has been retired. All input/output locations are now set
using the ``$PUDL_INPUT`` and ``$PUDL_OUTPUT`` environment variables. See
:issue:`3107` and :pr:`3086`.

Miscellaneous
^^^^^^^^^^^^^
Expand Down
3 changes: 3 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -263,6 +263,9 @@ filterwarnings = [
"once:The behavior of DataFrame concatenation with empty or all-NA entries is deprecated.:FutureWarning",
]

markers = [
"slow: marks tests as slow (deselect with '-m \"not slow\"')",
]
# Oddly, despite the use of --cov-config=pyproject.toml here, pytest does not seem to
# pick up the source directories specified in the [tool.coverage.run] section below.
# (though it *does* pick up the omit parameters!). This means we need to specify the
Expand Down
6 changes: 5 additions & 1 deletion test/unit/io_managers_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -242,6 +242,7 @@ def test_pudl_sqlite_io_manager_delete_stmt(fake_pudl_sqlite_io_manager_fixture)
assert len(returned_df) == 1


@pytest.mark.slow
def test_migrations_match_metadata(tmp_path, monkeypatch):
"""If you create a `PudlSQLiteIOManager` that points at a non-existing
`pudl.sqlite` - it will initialize the DB based on the `package`.
Expand Down Expand Up @@ -422,7 +423,10 @@ def test_ferc_xbrl_sqlite_io_manager_dedupes(mocker, tmp_path):
)


@hypothesis.settings(print_blob=True, deadline=400)
# ridiculous deadline - dataframe generation is always slow and sometimes
# *very* slow
@pytest.mark.slow
@hypothesis.settings(print_blob=True, deadline=2_000)
@hypothesis.given(example_schema.strategy(size=3))
def test_filter_for_freshest_data(df):
# XBRL context is the identifying metadata for reported values
Expand Down
1 change: 1 addition & 0 deletions test/unit/settings_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -281,6 +281,7 @@ def test_partitions_with_json_normalize(pudl_etl_settings):
)


@pytest.mark.slow
def test_partitions_for_datasource_table(pudl_etl_settings):
"""Test whether or not we can make the datasource table."""
ds = Datastore(local_cache_path=PudlPaths().data_dir)
Expand Down

0 comments on commit 71347c9

Please sign in to comment.