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

Demographics.py and build_and_test.yml #4

Merged
merged 2 commits into from
Oct 24, 2023

Conversation

rickecon
Copy link

@rickecon rickecon commented Oct 24, 2023

This PR:

  • Updates demographics.py. The first test test_get_pop_objs() in test_demographics.py was failing because the get_fert(), get_mort(), and get_imm_rates() functions were defaulting to producing the plots. And the plot functions are not working correctly right now (See this PR thread comment).
  • Inserts the Mambaforge build approach into the build section of build_and_test.yml. I think this should help the CI move past that spot.

All the pytest tests pass for me locally after this PR.

(ogusa-dev) richardevans@Richards-MacBook-Pro-2 OG-USA % pytest
/opt/anaconda3/envs/ogusa-dev/lib/python3.11/site-packages/pep8.py:110: FutureWarning: Possible nested set at position 1
  EXTRANEOUS_WHITESPACE_REGEX = re.compile(r'[[({] | []}),;:]')
============================= test session starts ==============================
platform darwin -- Python 3.11.6, pytest-7.4.2, pluggy-1.3.0
rootdir: /Users/richardevans/Docs/Economics/OSE/OG-USA
configfile: pytest.ini
testpaths: ogusa/tests
plugins: xdist-3.3.1, pep8-1.0.6
collected 45 items                                                             

ogusa/tests/test_calibrate.py ....                                       [  8%]
ogusa/tests/test_demographics.py ........                                [ 26%]
ogusa/tests/test_get_micro_data.py ..............                        [ 57%]
ogusa/tests/test_income.py ............                                  [ 84%]
ogusa/tests/test_psid_data_setup.py ...                                  [ 91%]
ogusa/tests/test_run_example.py .                                        [ 93%]
ogusa/tests/test_utils.py .                                              [ 95%]
ogusa/tests/test_wealth.py ..                                            [100%]
================= 45 passed, 95 warnings in 2599.10s (0:43:19) =================

cc: @jdebacker

@rickecon
Copy link
Author

@jdebacker. I can't get the documentation to build locally using the new ogusa-dev conda environment: jb build ./docs/book. These are the errors I get. Maybe things are not compiling anymore because I removed the default plotting functionality from those functions in demographics.py.

@jdebacker jdebacker merged commit c659d1d into jdebacker:update_calib Oct 24, 2023
2 of 8 checks passed
@rickecon rickecon deleted the jdebacker-update_calib branch October 24, 2023 16:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants