jschalk / jaar

Cross-cultural communication engine built on customizable economic systems. Produces personalized agendas, calendars, finance reports for users.
0 stars 1 forks source link

175 enable documentation process #347

Closed jschalk closed 1 month ago

jschalk commented 1 month ago

Summary by Sourcery

Refactor the codebase to replace 'amount' with 'quota' in the PurviewEpisode class and related tests. Update import paths to a consistent directory structure and refactor class names in the brick module to use CamelCase. Add new JSON configuration files for fiscal brick formats.

Enhancements:

Tests:

Chores:

sourcery-ai[bot] commented 1 month ago

Reviewer's Guide by Sourcery

This pull request implements several changes related to file organization, naming conventions, and data structure modifications. The changes primarily affect the project's directory structure, import statements, and some data model adjustments.

Updated class diagram for PurviewEpisode and PurviewLog

classDiagram
    class PurviewEpisode {
        +TimeLinePoint timestamp
        +FundNum quota
        +FundNum _magnitude
        +dict[AcctID, FundNum] _net_purviews
        +dict get_dict()
        +dict get_json()
    }

    class PurviewLog {
        +OwnerID owner_id
        +dict[TimeLinePoint, PurviewEpisode] episodes
        +FundNum _sum_purviewepisode_quota
        +int _sum_acct_purviews
        +TimeLinePoint _timestamp_min
        +TimeLinePoint _timestamp_max
        +void set_episode(PurviewEpisode)
        +void add_episode(TimeLinePoint, FundNum)
        +list get_2d_array()
        +list get_headers()
        +dict get_dict()
        +set get_timestamps()
        +TranBook get_tranbook(FiscalID)
    }

Updated class diagram for BrickColumn and BrickRef

classDiagram
    class BrickColumn {
        +str attribute_key
        +int column_order
        +int sort_order
    }

    class BrickRef {
        +str brick_name
        +str atom_categorys
        +dict[str, BrickColumn] _brickcolumns
        +void set_brickcolumn(BrickColumn)
        +list get_headers_list()
        +BrickColumn get_brickcolumn(str)
    }

File-Level Changes

Change Details Files
Reorganized project directory structure
  • Changed directory names from 'f0_instrument' to 'f00_instrument'
  • Changed directory names from 'f1_road' to 'f01_road'
  • Changed directory names from 'f2_bud' to 'f02_bud'
  • Changed directory names from 'f3_chrono' to 'f03_chrono'
  • Changed directory names from 'f4_gift' to 'f04_gift'
  • Changed directory names from 'f5_listen' to 'f05_listen'
  • Changed directory names from 'f6_keep' to 'f06_keep'
  • Changed directory names from 'f7_fiscal' to 'f07_fiscal'
  • Changed directory names from 'f8_brick' to 'f08_brick'
src/f01_road/finance_tran.py
src/f08_brick/brick_config.py
src/f08_brick/test_brick/test_brick_column.py
src/f02_bud/bud_tool.py
src/f04_gift/test_gift/test_gift_.py
src/f08_brick/test_brick/test_brick_format_config.py
src/f02_bud/examples/example_buds.py
src/f02_bud/test__item/test_item_.py
src/f02_bud/test__item/test_item_dict.py
src/f02_bud/test_bud_settle/test_z_tree_metrics.py
src/f04_gift/test_delta/test_delta_category_filter.py
src/f04_gift/test_delta/test_delta_legible_acct_membership.py
src/f04_gift/test_delta/test_delta_legible_acctunit.py
src/f04_gift/test_delta/test_delta_legible_budunit.py
src/f04_gift/test_delta/test_delta_legible_item_awardlink.py
src/f04_gift/test_delta/test_delta_legible_item_factunit.py
src/f04_gift/test_delta/test_delta_legible_item_healerlink.py
src/f04_gift/test_delta/test_delta_legible_item_reason_premiseunit.py
src/f04_gift/test_delta/test_delta_legible_item_reasonunit.py
src/f04_gift/test_delta/test_delta_legible_item_teamlink.py
src/f05_listen/examples/example_listen_deltas.py
src/f07_fiscal/test_fiscal_/test_fiscal_journal_sqlstr.py
src/f08_brick/test_brick/test_brick_format_generate_brick.py
src/f02_bud/test__item/test_item_active_status.py
src/f04_gift/examples/example_atoms.py
src/f04_gift/test_atom/test_atom_json.py
src/f04_gift/test_delta/test_delta_sift_delete.py
src/f04_gift/test_delta/test_delta_sift_insert.py
src/f06_keep/examples/example_credorledgers.py
src/f06_keep/test_keep/test_riverrun_crud_tax_due.py
src/f06_keep/test_keep/test_riverrun_crud_tax_yield.py
src/f02_bud/test_bud/test_bud_item_label_edit.py
src/f02_bud/test_bud_settle/test_tree_traverse_reason_item.py
src/f04_gift/examples/example_deltas.py
src/f04_gift/test_atom/test_atom_graphic.py
src/f04_gift/test_atom/test_atom_row.py
src/f04_gift/test_delta/test_delta_legible_itemunit.py
src/f05_listen/examples/listen_env.py
src/f08_brick/test_brick/test_brick_format_dataframes.py
src/f02_bud/test__item/test_item_road.py
src/f02_bud/test_bud_settle/test_tree_traverse_reason_team.py
src/f05_listen/examples/example_listen.py
src/f06_keep/test_keep/test_rivergrade.py
src/f06_keep/test_keep/test_riverrun_crud_grade.py
src/f08_brick/examples/brick_env.py
src/f08_brick/test_formatbuilder/test_brick_format_builder.py
src/f02_bud/test_/test_fact.py
src/f02_bud/test__item/test_item_attr_holder.py
src/f02_bud/test__item/test_items_calculated_float.py
src/f02_bud/test_bud/test_bud_accts_group.py
src/f02_bud/test_bud_settle/test_z_bud_range.py
src/f03_chrono/chrono.py
src/f04_gift/examples/gift_env.py
src/f04_gift/test_delta/test_delta_after_bud.py
src/f05_listen/basis_buds.py
src/f05_listen/examples/example_listen_atoms.py
src/f05_listen/examples/example_listen_buds.py
src/f05_listen/examples/example_listen_purviews.py
src/f06_keep/examples/example_keep_buds.py
src/f06_keep/test_keep/test_riverrun_.py
src/f06_keep/test_keep/test_riverrun_levy.py
src/f06_keep/test_keep/test_riverrun_metrics.py
src/f07_fiscal/test_fiscal_/test_fiscal_kpis.py
src/f08_brick/test_brick/test_brick_format_import.py
src/f01_road/finance.py
src/f01_road/jaar_config.py
src/f01_road/test/test_road.py
src/f02_bud/examples/bud_env.py
src/f02_bud/test_/test_healer.py
src/f02_bud/test_/test_origin.py
src/f02_bud/test_/test_tree_metrics.py
src/f02_bud/test_bud_settle/test_set_respect_ledgers.py
src/f03_chrono/examples/chrono_examples.py
src/f04_gift/atom_config.py
src/f04_gift/legible.py
src/f04_gift/test_atom/test_atom_core.py
src/f05_listen/hubunit.py
src/f05_listen/test_hubunit/test_hubunit__core.py
src/f06_keep/examples/keep_env.py
src/f07_fiscal/test_fiscal_/test_fiscal_journal_.py
src/f08_brick/formatbuilder.py
src/f08_brick/test_brick/test_env.py
Modified data model: renamed 'amount' to 'quota'
  • Changed 'amount' attribute to 'quota' in PurviewEpisode class
  • Updated references to 'amount' to use 'quota' instead
  • Modified test cases to use 'quota' instead of 'amount'
src/f01_road/finance_tran.py
src/f05_listen/test_hubunit/test_hubunit_timeline.py
src/f05_listen/examples/example_listen_purviews.py
src/f05_listen/hubunit.py
Added new brick format files
  • Added brick_format_00000_fiscalunit_v0_0_0.json
  • Added brick_format_00001_fiscal_purviewlog_v0_0_0.json
  • Added brick_format_00002_fiscal_purview_episode_v0_0_0.json
  • Added brick_format_00003_fiscal_cashbook_v0_0_0.json
  • Added brick_format_00004_fiscal_timeline_hour_v0_0_0.json
  • Added brick_format_00005_fiscal_timeline_month_v0_0_0.json
  • Added brick_format_00006_fiscal_timeline_weekday_v0_0_0.json
src/f08_brick/brick_formats/brick_format_00000_fiscalunit_v0_0_0.json
src/f08_brick/brick_formats/brick_format_00001_fiscal_purviewlog_v0_0_0.json
src/f08_brick/brick_formats/brick_format_00002_fiscal_purview_episode_v0_0_0.json
src/f08_brick/brick_formats/brick_format_00003_fiscal_cashbook_v0_0_0.json
src/f08_brick/brick_formats/brick_format_00004_fiscal_timeline_hour_v0_0_0.json
src/f08_brick/brick_formats/brick_format_00005_fiscal_timeline_month_v0_0_0.json
src/f08_brick/brick_formats/brick_format_00006_fiscal_timeline_weekday_v0_0_0.json
Updated brick format numbering
  • Changed brick_format_00003_itemunit_v0_0_0 to brick_format_00013_itemunit_v0_0_0
  • Updated references to the renamed brick format in various files
src/f08_brick/brick_config.py
src/f08_brick/test_brick/test_brick_format_config.py
src/f08_brick/test_brick/test_brick_format_generate_brick.py
src/f08_brick/test_brick/test_brick_format_dataframes.py
src/f08_brick/test_brick/test_brick_format_import.py

Tips and commands #### Interacting with Sourcery - **Trigger a new review:** Comment `@sourcery-ai review` on the pull request. - **Continue discussions:** Reply directly to Sourcery's review comments. - **Generate a GitHub issue from a review comment:** Ask Sourcery to create an issue from a review comment by replying to it. - **Generate a pull request title:** Write `@sourcery-ai` anywhere in the pull request title to generate a title at any time. - **Generate a pull request summary:** Write `@sourcery-ai summary` anywhere in the pull request body to generate a PR summary at any time. You can also use this command to specify where the summary should be inserted. #### Customizing Your Experience Access your [dashboard](https://app.sourcery.ai) to: - Enable or disable review features such as the Sourcery-generated pull request summary, the reviewer's guide, and others. - Change the review language. - Add, remove or edit custom review instructions. - Adjust other review settings. #### Getting Help - [Contact our support team](mailto:support@sourcery.ai) for questions or feedback. - Visit our [documentation](https://docs.sourcery.ai) for detailed guides and information. - Keep in touch with the Sourcery team by following us on [X/Twitter](https://x.com/SourceryAI), [LinkedIn](https://www.linkedin.com/company/sourcery-ai/) or [GitHub](https://github.com/sourcery-ai).