From 28c1b238f7d130acac96993fd54d146780871368 Mon Sep 17 00:00:00 2001 From: Max Ghenis Date: Tue, 22 Jul 2025 15:31:04 -0400 Subject: [PATCH 1/3] Re-export microdf classes and update to v1.0.0 - Re-export MicroDataFrame and MicroSeries from policyengine_core - This allows downstream packages to import from policyengine-core instead of having direct microdf dependencies - Update microdf_python dependency to >=1.0.0 This change enables removing direct microdf dependencies from downstream packages for better dependency management. --- changelog_entry.yaml | 6 ++ claude_code_output.log | 150 ++++++++++++++++++++++++++++++++++ claude_code_wrapper.sh | 8 ++ policyengine_core/__init__.py | 3 + setup.py | 2 +- 5 files changed, 168 insertions(+), 1 deletion(-) create mode 100644 claude_code_output.log create mode 100755 claude_code_wrapper.sh diff --git a/changelog_entry.yaml b/changelog_entry.yaml index e69de29bb..4262679c2 100644 --- a/changelog_entry.yaml +++ b/changelog_entry.yaml @@ -0,0 +1,6 @@ +- bump: minor + changes: + added: + - Re-export MicroDataFrame and MicroSeries from microdf to allow downstream packages to import from policyengine-core. + changed: + - Update microdf_python dependency to >=1.0.0. diff --git a/claude_code_output.log b/claude_code_output.log new file mode 100644 index 000000000..00e32834d --- /dev/null +++ b/claude_code_output.log @@ -0,0 +1,150 @@ +Script started on Sun Mar 2 18:29:17 2025 +% maxghenis@Mac policyengine-core % [?2004hcclaude[?2004l +╭─────────────────────────────────────────────────────────╮ +│ ✻ Welcome to Claude Code research preview! │ +│ │ +│ /help for help │ +│ │ +│ cwd: /Users/maxghenis/PolicyEngine/policyengine-core │ +╰─────────────────────────────────────────────────────────╯ +[?25l +╭──────────────────────────────────────────────────────────────────────────────────────────────╮ +│ >   │ +╰──────────────────────────────────────────────────────────────────────────────────────────────╯ + ! for bash mode · / for commands · esc to undo \⏎ for newline + + +[?25l +╭──────────────────────────────────────────────────────────────────────────────────────────────╮ +│ > Try "fix typecheck errors" │ +╰──────────────────────────────────────────────────────────────────────────────────────────────╯ + ! for bash mode · / for commands · esc to undo \⏎ for newline + + + +╭──────────────────────────────────────────────────────────────────────────────────────────────╮ +│ ! Try "fix typecheck errors" │ +╰──────────────────────────────────────────────────────────────────────────────────────────────╯ + ! for bash mode · / for commands · esc to undo \⏎ for newline + + + +╭──────────────────────────────────────────────────────────────────────────────────────────────╮ +│ ! 1  │ +╰──────────────────────────────────────────────────────────────────────────────────────────────╯ + ! for bash mode · / for commands · esc to undo \⏎ for newline + + + +╭──────────────────────────────────────────────────────────────────────────────────────────────╮ +│ ! Try "fix typecheck errors" │ +╰──────────────────────────────────────────────────────────────────────────────────────────────╯ + ! for bash mode · / for commands · esc to undo \⏎ for newline + + + +╭──────────────────────────────────────────────────────────────────────────────────────────────╮ +│ ! l  │ +╰──────────────────────────────────────────────────────────────────────────────────────────────╯ + ! for bash mode · / for commands · esc to undo \⏎ for newline + + + +╭──────────────────────────────────────────────────────────────────────────────────────────────╮ +│ ! ls  │ +╰──────────────────────────────────────────────────────────────────────────────────────────────╯ + ! for bash mode · / for commands · esc to undo \⏎ for newline + + + +· Actualizing… (0s · esc to interrupt) + +╭──────────────────────────────────────────────────────────────────────────────────────────────╮ +│ >   │ +╰──────────────────────────────────────────────────────────────────────────────────────────────╯ + ! for bash mode · / for commands · esc to undo \⏎ for newline + + + +! ls + +· Finagling… (0s · esc to interrupt) + +╭──────────────────────────────────────────────────────────────────────────────────────────────╮ +│ >   │ +╰──────────────────────────────────────────────────────────────────────────────────────────────╯ + ! for bash mode · / for commands · esc to undo \⏎ for newline + + + +· Mustering… (0s · esc to interrupt) + +╭──────────────────────────────────────────────────────────────────────────────────────────────╮ +│ >   │ +╰──────────────────────────────────────────────────────────────────────────────────────────────╯ + ! for bash mode · / for commands · esc to undo \⏎ for newline + + + +! ls +  ⎿  CHANGELOG.md + CLAUDE.md + CONTRIBUTING.md + LICENSE + MANIFEST.in + Makefile + README.md + changelog.yaml + changelog_entry.yaml + claude_code_output.log + claude_code_wrapper.sh + coverage.xml + docs + mypy.ini + policyengine_core + policyengine_core.egg-info + setup.py + test.ipynb + tests + +╭──────────────────────────────────────────────────────────────────────────────────────────────╮ +│ >   │ +╰──────────────────────────────────────────────────────────────────────────────────────────────╯ + ! for bash mode · / for commands · esc to undo \⏎ for newline + + + +╭──────────────────────────────────────────────────────────────────────────────────────────────╮ +│ > e  │ +╰──────────────────────────────────────────────────────────────────────────────────────────────╯ + ! for bash mode · / for commands · esc to undo \⏎ for newline + + + +╭──────────────────────────────────────────────────────────────────────────────────────────────╮ +│ > ex  │ +╰──────────────────────────────────────────────────────────────────────────────────────────────╯ + ! for bash mode · / for commands · esc to undo \⏎ for newline + + + +╭──────────────────────────────────────────────────────────────────────────────────────────────╮ +│ > exi  │ +╰──────────────────────────────────────────────────────────────────────────────────────────────╯ + ! for bash mode · / for commands · esc to undo \⏎ for newline + + + +╭──────────────────────────────────────────────────────────────────────────────────────────────╮ +│ > exit  │ +╰──────────────────────────────────────────────────────────────────────────────────────────────╯ + ! for bash mode · / for commands · esc to undo \⏎ for newline + + +]0;[?25h[?25h +Total cost: $0.0006 +Total duration (API): 1.4s +Total duration (wall): 13.4s +[?25h[?25h% maxghenis@Mac policyengine-core % [?2004heexit[?2004l + +Script done on Sun Mar 2 18:30:13 2025 diff --git a/claude_code_wrapper.sh b/claude_code_wrapper.sh new file mode 100755 index 000000000..258d025ac --- /dev/null +++ b/claude_code_wrapper.sh @@ -0,0 +1,8 @@ +#!/bin/bash + +# Define the log file +LOGFILE="claude_code_output.log" + +# Run Claude Code and redirect both stdout and stderr to the log file +# while also displaying them in the terminal +claude "$@" > >(tee -a "$LOGFILE") 2> >(tee -a "$LOGFILE" >&2) diff --git a/policyengine_core/__init__.py b/policyengine_core/__init__.py index 3745adf6d..6cd7b65d9 100644 --- a/policyengine_core/__init__.py +++ b/policyengine_core/__init__.py @@ -1,2 +1,5 @@ from policyengine_core.simulations import Microsimulation, Simulation from policyengine_core.taxbenefitsystems import TaxBenefitSystem + +# Re-export microdf classes for downstream packages +from microdf import MicroDataFrame, MicroSeries diff --git a/setup.py b/setup.py index f74e5d010..76177747c 100644 --- a/setup.py +++ b/setup.py @@ -23,7 +23,7 @@ "plotly>=5,<6", "ipython>=8,<9", "pyvis>=0.3.2", - "microdf_python>=0.4.3", + "microdf_python>=1.0.0", "huggingface_hub>=0.25.1", ] From 9b324d2f2259f6e439f4b03a0fbcc4b740fbf4e7 Mon Sep 17 00:00:00 2001 From: Max Ghenis Date: Tue, 22 Jul 2025 15:38:37 -0400 Subject: [PATCH 2/3] Remove accidentally added log files --- claude_code_output.log | 150 ----------------------------------------- claude_code_wrapper.sh | 8 --- 2 files changed, 158 deletions(-) delete mode 100644 claude_code_output.log delete mode 100755 claude_code_wrapper.sh diff --git a/claude_code_output.log b/claude_code_output.log deleted file mode 100644 index 00e32834d..000000000 --- a/claude_code_output.log +++ /dev/null @@ -1,150 +0,0 @@ -Script started on Sun Mar 2 18:29:17 2025 -% maxghenis@Mac policyengine-core % [?2004hcclaude[?2004l -╭─────────────────────────────────────────────────────────╮ -│ ✻ Welcome to Claude Code research preview! │ -│ │ -│ /help for help │ -│ │ -│ cwd: /Users/maxghenis/PolicyEngine/policyengine-core │ -╰─────────────────────────────────────────────────────────╯ -[?25l -╭──────────────────────────────────────────────────────────────────────────────────────────────╮ -│ >   │ -╰──────────────────────────────────────────────────────────────────────────────────────────────╯ - ! for bash mode · / for commands · esc to undo \⏎ for newline - - -[?25l -╭──────────────────────────────────────────────────────────────────────────────────────────────╮ -│ > Try "fix typecheck errors" │ -╰──────────────────────────────────────────────────────────────────────────────────────────────╯ - ! for bash mode · / for commands · esc to undo \⏎ for newline - - - -╭──────────────────────────────────────────────────────────────────────────────────────────────╮ -│ ! Try "fix typecheck errors" │ -╰──────────────────────────────────────────────────────────────────────────────────────────────╯ - ! for bash mode · / for commands · esc to undo \⏎ for newline - - - -╭──────────────────────────────────────────────────────────────────────────────────────────────╮ -│ ! 1  │ -╰──────────────────────────────────────────────────────────────────────────────────────────────╯ - ! for bash mode · / for commands · esc to undo \⏎ for newline - - - -╭──────────────────────────────────────────────────────────────────────────────────────────────╮ -│ ! Try "fix typecheck errors" │ -╰──────────────────────────────────────────────────────────────────────────────────────────────╯ - ! for bash mode · / for commands · esc to undo \⏎ for newline - - - -╭──────────────────────────────────────────────────────────────────────────────────────────────╮ -│ ! l  │ -╰──────────────────────────────────────────────────────────────────────────────────────────────╯ - ! for bash mode · / for commands · esc to undo \⏎ for newline - - - -╭──────────────────────────────────────────────────────────────────────────────────────────────╮ -│ ! ls  │ -╰──────────────────────────────────────────────────────────────────────────────────────────────╯ - ! for bash mode · / for commands · esc to undo \⏎ for newline - - - -· Actualizing… (0s · esc to interrupt) - -╭──────────────────────────────────────────────────────────────────────────────────────────────╮ -│ >   │ -╰──────────────────────────────────────────────────────────────────────────────────────────────╯ - ! for bash mode · / for commands · esc to undo \⏎ for newline - - - -! ls - -· Finagling… (0s · esc to interrupt) - -╭──────────────────────────────────────────────────────────────────────────────────────────────╮ -│ >   │ -╰──────────────────────────────────────────────────────────────────────────────────────────────╯ - ! for bash mode · / for commands · esc to undo \⏎ for newline - - - -· Mustering… (0s · esc to interrupt) - -╭──────────────────────────────────────────────────────────────────────────────────────────────╮ -│ >   │ -╰──────────────────────────────────────────────────────────────────────────────────────────────╯ - ! for bash mode · / for commands · esc to undo \⏎ for newline - - - -! ls -  ⎿  CHANGELOG.md - CLAUDE.md - CONTRIBUTING.md - LICENSE - MANIFEST.in - Makefile - README.md - changelog.yaml - changelog_entry.yaml - claude_code_output.log - claude_code_wrapper.sh - coverage.xml - docs - mypy.ini - policyengine_core - policyengine_core.egg-info - setup.py - test.ipynb - tests - -╭──────────────────────────────────────────────────────────────────────────────────────────────╮ -│ >   │ -╰──────────────────────────────────────────────────────────────────────────────────────────────╯ - ! for bash mode · / for commands · esc to undo \⏎ for newline - - - -╭──────────────────────────────────────────────────────────────────────────────────────────────╮ -│ > e  │ -╰──────────────────────────────────────────────────────────────────────────────────────────────╯ - ! for bash mode · / for commands · esc to undo \⏎ for newline - - - -╭──────────────────────────────────────────────────────────────────────────────────────────────╮ -│ > ex  │ -╰──────────────────────────────────────────────────────────────────────────────────────────────╯ - ! for bash mode · / for commands · esc to undo \⏎ for newline - - - -╭──────────────────────────────────────────────────────────────────────────────────────────────╮ -│ > exi  │ -╰──────────────────────────────────────────────────────────────────────────────────────────────╯ - ! for bash mode · / for commands · esc to undo \⏎ for newline - - - -╭──────────────────────────────────────────────────────────────────────────────────────────────╮ -│ > exit  │ -╰──────────────────────────────────────────────────────────────────────────────────────────────╯ - ! for bash mode · / for commands · esc to undo \⏎ for newline - - -]0;[?25h[?25h -Total cost: $0.0006 -Total duration (API): 1.4s -Total duration (wall): 13.4s -[?25h[?25h% maxghenis@Mac policyengine-core % [?2004heexit[?2004l - -Script done on Sun Mar 2 18:30:13 2025 diff --git a/claude_code_wrapper.sh b/claude_code_wrapper.sh deleted file mode 100755 index 258d025ac..000000000 --- a/claude_code_wrapper.sh +++ /dev/null @@ -1,8 +0,0 @@ -#!/bin/bash - -# Define the log file -LOGFILE="claude_code_output.log" - -# Run Claude Code and redirect both stdout and stderr to the log file -# while also displaying them in the terminal -claude "$@" > >(tee -a "$LOGFILE") 2> >(tee -a "$LOGFILE" >&2) From 760cae122ef60919c2144abbe3fe4e7f5bea1aa6 Mon Sep 17 00:00:00 2001 From: Max Ghenis Date: Tue, 22 Jul 2025 15:46:36 -0400 Subject: [PATCH 3/3] Remove re-export, keep version update Keep the PR simple - just update microdf_python to >=1.0.0 without re-exporting classes --- changelog_entry.yaml | 2 -- policyengine_core/__init__.py | 3 --- 2 files changed, 5 deletions(-) diff --git a/changelog_entry.yaml b/changelog_entry.yaml index 4262679c2..a16bfc255 100644 --- a/changelog_entry.yaml +++ b/changelog_entry.yaml @@ -1,6 +1,4 @@ - bump: minor changes: - added: - - Re-export MicroDataFrame and MicroSeries from microdf to allow downstream packages to import from policyengine-core. changed: - Update microdf_python dependency to >=1.0.0. diff --git a/policyengine_core/__init__.py b/policyengine_core/__init__.py index 6cd7b65d9..3745adf6d 100644 --- a/policyengine_core/__init__.py +++ b/policyengine_core/__init__.py @@ -1,5 +1,2 @@ from policyengine_core.simulations import Microsimulation, Simulation from policyengine_core.taxbenefitsystems import TaxBenefitSystem - -# Re-export microdf classes for downstream packages -from microdf import MicroDataFrame, MicroSeries