codeplain 0.3.12.dev26__tar.gz → 0.3.13__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/.github/dependabot.yml +13 -2
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/.github/workflows/e2e.yml +4 -4
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/.github/workflows/lint-and-test.yml +5 -5
- codeplain-0.3.13/.github/workflows/notify-slack-on-main-merge.yml +37 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/.github/workflows/publish-dev-to-pypi.yml +55 -22
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/.github/workflows/publish-install-script.yml +37 -14
- codeplain-0.3.13/.github/workflows/publish-to-pypi.yml +241 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/PKG-INFO +8 -8
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/codeplain_REST_api.py +26 -32
- codeplain-0.3.13/concept_utils.py +3 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/file_utils.py +23 -107
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/module_renderer.py +2 -4
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/plain2code.py +39 -6
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/plain2code_arguments.py +30 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/plain2code_exceptions.py +12 -42
- codeplain-0.3.13/plain2code_nodes.py +3 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/plain2code_state.py +6 -2
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/plain2code_utils.py +1 -16
- codeplain-0.3.13/plain_file.py +3 -0
- codeplain-0.3.13/plain_spec.py +37 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/pyproject.toml +12 -9
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/render_machine/actions/exit_with_error.py +8 -7
- codeplain-0.3.13/render_machine/actions/fix_unit_tests.py +256 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/render_machine/actions/render_functional_requirement.py +10 -3
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/render_machine/actions/run_unit_tests.py +9 -0
- codeplain-0.3.13/render_machine/agent_tools.py +270 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/render_machine/code_renderer.py +0 -3
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/render_machine/render_context.py +10 -2
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/render_machine/render_types.py +54 -11
- codeplain-0.3.13/requirements.txt +23 -0
- codeplain-0.3.13/tests/test_agent_tools.py +166 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/tests/test_arg_provenance.py +20 -0
- codeplain-0.3.13/tests/test_file_utils.py +105 -0
- codeplain-0.3.13/tests/test_fix_unit_tests_action.py +239 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/tests/test_fix_unit_tests_conformance_context.py +120 -25
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/tests/test_plain2code_state.py +5 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/tests/test_render_finished_report.py +1 -0
- codeplain-0.3.13/tests/test_render_range.py +42 -0
- codeplain-0.3.13/tests/test_render_stop_reason.py +210 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/tests/test_terminal_attachment.py +1 -0
- codeplain-0.3.13/tests/test_user_error_message.py +36 -0
- codeplain-0.3.12.dev26/.github/workflows/nofity-slack-on-main-merge.yml +0 -22
- codeplain-0.3.12.dev26/.github/workflows/publish-to-pypi.yml +0 -159
- codeplain-0.3.12.dev26/concept_utils.py +0 -221
- codeplain-0.3.12.dev26/plain2code_nodes.py +0 -119
- codeplain-0.3.12.dev26/plain_file.py +0 -871
- codeplain-0.3.12.dev26/plain_spec.py +0 -441
- codeplain-0.3.12.dev26/render_machine/actions/fix_unit_tests.py +0 -79
- codeplain-0.3.12.dev26/requirements.txt +0 -20
- codeplain-0.3.12.dev26/tests/data/imports/circular_imports_1.plain +0 -8
- codeplain-0.3.12.dev26/tests/data/imports/circular_imports_2.plain +0 -8
- codeplain-0.3.12.dev26/tests/data/imports/circular_imports_main.plain +0 -12
- codeplain-0.3.12.dev26/tests/data/imports/diamond_import_1.plain +0 -16
- codeplain-0.3.12.dev26/tests/data/imports/diamond_import_2.plain +0 -16
- codeplain-0.3.12.dev26/tests/data/imports/diamond_import_common.plain +0 -11
- codeplain-0.3.12.dev26/tests/data/imports/diamond_imports_main.plain +0 -13
- codeplain-0.3.12.dev26/tests/data/imports/import_with_functionalities.plain +0 -7
- codeplain-0.3.12.dev26/tests/data/imports/imports_module_with_functionalities.plain +0 -12
- codeplain-0.3.12.dev26/tests/data/imports/non_existent_import.plain +0 -12
- codeplain-0.3.12.dev26/tests/data/plainfile/add_new_task_modal_specification.yaml +0 -1
- codeplain-0.3.12.dev26/tests/data/plainfile/duplicate_specification_heading.plain +0 -7
- codeplain-0.3.12.dev26/tests/data/plainfile/empty_functional_specs_section.plain +0 -4
- codeplain-0.3.12.dev26/tests/data/plainfile/invalid_specification_order.plain +0 -7
- codeplain-0.3.12.dev26/tests/data/plainfile/missing_non_functional_requirements.plain +0 -5
- codeplain-0.3.12.dev26/tests/data/plainfile/no_functional_specs_section.plain +0 -5
- codeplain-0.3.12.dev26/tests/data/plainfile/plain_source_with_absolute_link.plain +0 -9
- codeplain-0.3.12.dev26/tests/data/plainfile/plain_source_with_missing_link.plain +0 -9
- codeplain-0.3.12.dev26/tests/data/plainfile/plain_source_with_url_link.plain +0 -9
- codeplain-0.3.12.dev26/tests/data/plainfile/task_list_ui_specification.yaml +0 -1
- codeplain-0.3.12.dev26/tests/data/plainfile/task_manager_with_reference_links.plain +0 -40
- codeplain-0.3.12.dev26/tests/data/plainfile/without_non_functional_requirement.plain +0 -5
- codeplain-0.3.12.dev26/tests/data/plainfileparser/concept_validation_acceptance_tests.plain +0 -20
- codeplain-0.3.12.dev26/tests/data/plainfileparser/concept_validation_acceptance_tests_nondefined.plain +0 -20
- codeplain-0.3.12.dev26/tests/data/plainfileparser/concept_validation_defined_nondefined.plain +0 -18
- codeplain-0.3.12.dev26/tests/data/plainfileparser/concept_validation_defined_nondefined_2.plain +0 -18
- codeplain-0.3.12.dev26/tests/data/plainfileparser/concept_validation_definition.plain +0 -16
- codeplain-0.3.12.dev26/tests/data/plainfileparser/concept_validation_noconcepts.plain +0 -18
- codeplain-0.3.12.dev26/tests/data/plainfileparser/concept_validation_nonconcept.plain +0 -15
- codeplain-0.3.12.dev26/tests/data/plainfileparser/concept_validation_nondefined.plain +0 -18
- codeplain-0.3.12.dev26/tests/data/plainfileparser/concept_validation_redefinition.plain +0 -19
- codeplain-0.3.12.dev26/tests/data/plainfileparser/concept_validation_several_concepts.plain +0 -13
- codeplain-0.3.12.dev26/tests/data/plainfileparser/concept_validation_valid.plain +0 -16
- codeplain-0.3.12.dev26/tests/data/plainfileparser/cyclic_definitions.plain +0 -9
- codeplain-0.3.12.dev26/tests/data/plainfileparser/exported_concepts.plain +0 -13
- codeplain-0.3.12.dev26/tests/data/plainfileparser/exported_concepts_base.plain +0 -2
- codeplain-0.3.12.dev26/tests/data/plainfileparser/exported_concepts_defaults_exported.plain +0 -13
- codeplain-0.3.12.dev26/tests/data/plainfileparser/exported_concepts_example.plain +0 -13
- codeplain-0.3.12.dev26/tests/data/plainfileparser/exported_concepts_imported_exported.plain +0 -12
- codeplain-0.3.12.dev26/tests/data/plainfileparser/exported_concepts_inherited_reexported.plain +0 -15
- codeplain-0.3.12.dev26/tests/data/plainfileparser/exported_concepts_malformed.plain +0 -13
- codeplain-0.3.12.dev26/tests/data/plainfileparser/exported_concepts_missing_definition.plain +0 -14
- codeplain-0.3.12.dev26/tests/data/plainfileparser/exported_concepts_missing_definition_example.plain +0 -13
- codeplain-0.3.12.dev26/tests/data/plainfileparser/exported_concepts_multiple_per_bullet.plain +0 -14
- codeplain-0.3.12.dev26/tests/data/plainfileparser/exported_concepts_multiple_per_bullet_undefined.plain +0 -13
- codeplain-0.3.12.dev26/tests/data/plainfileparser/exported_concepts_nested.plain +0 -15
- codeplain-0.3.12.dev26/tests/data/plainfileparser/exported_concepts_nested_example.plain +0 -13
- codeplain-0.3.12.dev26/tests/data/plainfileparser/exported_concepts_no_definitions.plain +0 -10
- codeplain-0.3.12.dev26/tests/data/plainfileparser/exported_concepts_not_declared.plain +0 -8
- codeplain-0.3.12.dev26/tests/data/plainfileparser/exported_concepts_not_declared_example.plain +0 -13
- codeplain-0.3.12.dev26/tests/data/plainfileparser/exported_concepts_transitive_example.plain +0 -13
- codeplain-0.3.12.dev26/tests/data/plainfileparser/exported_concepts_transitive_l1.plain +0 -13
- codeplain-0.3.12.dev26/tests/data/plainfileparser/exported_concepts_transitive_l2.plain +0 -13
- codeplain-0.3.12.dev26/tests/data/plainfileparser/plain_file_parser_with_comments.plain +0 -8
- codeplain-0.3.12.dev26/tests/data/plainfileparser/plain_file_with_comments_indented.plain +0 -10
- codeplain-0.3.12.dev26/tests/data/plainfileparser/regular_plain_source.plain +0 -11
- codeplain-0.3.12.dev26/tests/data/plainfileparser/required_concepts.plain +0 -7
- codeplain-0.3.12.dev26/tests/data/plainfileparser/required_concepts_defs.plain +0 -2
- codeplain-0.3.12.dev26/tests/data/plainfileparser/required_concepts_example.plain +0 -13
- codeplain-0.3.12.dev26/tests/data/plainfileparser/required_concepts_l1.plain +0 -7
- codeplain-0.3.12.dev26/tests/data/plainfileparser/required_concepts_l2.plain +0 -5
- codeplain-0.3.12.dev26/tests/data/plainfileparser/required_concepts_missing.plain +0 -10
- codeplain-0.3.12.dev26/tests/data/plainfileparser/required_concepts_module.plain +0 -11
- codeplain-0.3.12.dev26/tests/data/plainfileparser/required_concepts_partial.plain +0 -13
- codeplain-0.3.12.dev26/tests/data/plainfileparser/required_concepts_partial_duplicate.plain +0 -14
- codeplain-0.3.12.dev26/tests/data/plainfileparser/requires_without_definitions_example.plain +0 -10
- codeplain-0.3.12.dev26/tests/data/plainfileparser/topological_sort.plain +0 -14
- codeplain-0.3.12.dev26/tests/data/plainfileparser/topological_sort_not_referenced.plain +0 -22
- codeplain-0.3.12.dev26/tests/data/requires/circular_requires_main.plain +0 -18
- codeplain-0.3.12.dev26/tests/data/requires/circular_requires_sub.plain +0 -12
- codeplain-0.3.12.dev26/tests/data/requires/diamond_requires_1.plain +0 -12
- codeplain-0.3.12.dev26/tests/data/requires/diamond_requires_2.plain +0 -12
- codeplain-0.3.12.dev26/tests/data/requires/diamond_requires_common.plain +0 -7
- codeplain-0.3.12.dev26/tests/data/requires/diamond_requires_main.plain +0 -19
- codeplain-0.3.12.dev26/tests/data/requires/independent_requires_1.plain +0 -7
- codeplain-0.3.12.dev26/tests/data/requires/independent_requires_2.plain +0 -7
- codeplain-0.3.12.dev26/tests/data/requires/independent_requires_main.plain +0 -19
- codeplain-0.3.12.dev26/tests/data/requires/non_existent_require.plain +0 -18
- codeplain-0.3.12.dev26/tests/data/requires/normal_requires_1.plain +0 -12
- codeplain-0.3.12.dev26/tests/data/requires/normal_requires_2.plain +0 -12
- codeplain-0.3.12.dev26/tests/data/requires/normal_requires_common.plain +0 -7
- codeplain-0.3.12.dev26/tests/data/requires/normal_requires_main.plain +0 -19
- codeplain-0.3.12.dev26/tests/data/sample_base64_image.txt +0 -1
- codeplain-0.3.12.dev26/tests/data/simple.plain +0 -7
- codeplain-0.3.12.dev26/tests/data/templates/block_level_include.plain +0 -12
- codeplain-0.3.12.dev26/tests/data/templates/code_variables.plain +0 -10
- codeplain-0.3.12.dev26/tests/data/templates/header.plain +0 -7
- codeplain-0.3.12.dev26/tests/data/templates/implement.plain +0 -3
- codeplain-0.3.12.dev26/tests/data/templates/implement_2.plain +0 -3
- codeplain-0.3.12.dev26/tests/data/templates/template_include.plain +0 -4
- codeplain-0.3.12.dev26/tests/data/templates/test_hardest_problem.plain +0 -2
- codeplain-0.3.12.dev26/tests/test_file_utils.py +0 -92
- codeplain-0.3.12.dev26/tests/test_imports.py +0 -53
- codeplain-0.3.12.dev26/tests/test_plainfile.py +0 -271
- codeplain-0.3.12.dev26/tests/test_plainfileparser.py +0 -775
- codeplain-0.3.12.dev26/tests/test_plainspec.py +0 -103
- codeplain-0.3.12.dev26/tests/test_requires.py +0 -28
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/.claude/settings.json +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/.flake8 +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/.github/workflows/lint-powershell.yml +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/.gitignore +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/.vscode/launch.json +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/.vscode/settings.json +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/CLAUDE.md +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/CONTRIBUTING.md +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/LICENSE +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/README.md +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/change_detection.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/cli_output/__init__.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/cli_output/dry_run.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/cli_output/render_summary.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/cli_output/status.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/config/__init__.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/config/system_config.yaml +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/conformance_fix_journal.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/diff_utils.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/docs/generate_cli.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/docs/plain2code_cli.md +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/docs/starting_a_plain_project_from_scratch.md +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/event_bus.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/examples/example_hello_world_golang/config.yaml +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/examples/example_hello_world_golang/harness_tests/hello_world_test.go +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/examples/example_hello_world_golang/hello_world_golang.plain +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/examples/example_hello_world_golang/run.sh +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/examples/example_hello_world_python/config.yaml +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/examples/example_hello_world_python/harness_tests/hello_world_display/test_hello_world.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/examples/example_hello_world_python/hello_world_python.plain +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/examples/example_hello_world_python/run.sh +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/examples/example_hello_world_react/config.yaml +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/examples/example_hello_world_react/harness_tests/hello_world_display/cypress/e2e/hello_world.cy.ts +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/examples/example_hello_world_react/harness_tests/hello_world_display/cypress/support/e2e.ts +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/examples/example_hello_world_react/harness_tests/hello_world_display/cypress.config.ts +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/examples/example_hello_world_react/harness_tests/hello_world_display/package.json +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/examples/example_hello_world_react/harness_tests/hello_world_display/tsconfig.json +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/examples/example_hello_world_react/hello_world_react.plain +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/examples/example_hello_world_react/run.sh +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/examples/run.sh +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/git_preflight.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/git_utils.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/install/bash/examples.sh +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/install/bash/install.sh +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/install/bash/walkthrough.sh +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/install/powershell/examples.ps1 +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/install/powershell/install.ps1 +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/install/powershell/walkthrough.ps1 +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/memory_management.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/metadata_utils.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/partial_rendering.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/path_resolution.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/plain2code_cli.md +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/plain2code_console.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/plain2code_events.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/plain2code_logger.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/plain2code_read_config.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/plain2code_telemetry.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/plain_modules.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/pytest.ini +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/render_machine/__init__.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/render_machine/actions/analyze_specification_ambiguity.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/render_machine/actions/base_action.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/render_machine/actions/commit_conformance_tests_changes.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/render_machine/actions/commit_implementation_code_changes.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/render_machine/actions/create_dist.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/render_machine/actions/distill_conformance_test_memory.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/render_machine/actions/finish_functional_requirement.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/render_machine/actions/fix_conformance_test.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/render_machine/actions/prepare_repositories.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/render_machine/actions/prepare_testing_environment.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/render_machine/actions/refactor_code.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/render_machine/actions/render_conformance_tests.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/render_machine/actions/run_conformance_tests.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/render_machine/actions/summarize_conformance_tests.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/render_machine/conformance_tests.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/render_machine/implementation_code_helpers.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/render_machine/render_utils.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/render_machine/state_machine_config.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/render_machine/states.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/render_machine/triggers.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/resources/codeplain_overview.png +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/resources/plain_example.png +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/standard_template_library/golang-console-app-template.plain +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/standard_template_library/python-console-app-template.plain +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/standard_template_library/typescript-react-app-boilerplate.plain +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/standard_template_library/typescript-react-app-template.plain +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/system_config.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/test_scripts/run_conformance_tests_cypress.ps1 +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/test_scripts/run_conformance_tests_cypress.sh +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/test_scripts/run_conformance_tests_golang.ps1 +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/test_scripts/run_conformance_tests_golang.sh +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/test_scripts/run_conformance_tests_python.ps1 +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/test_scripts/run_conformance_tests_python.sh +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/test_scripts/run_unittests_flutter.ps1 +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/test_scripts/run_unittests_flutter.sh +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/test_scripts/run_unittests_golang.ps1 +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/test_scripts/run_unittests_golang.sh +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/test_scripts/run_unittests_python.ps1 +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/test_scripts/run_unittests_python.sh +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/test_scripts/run_unittests_react.ps1 +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/test_scripts/run_unittests_react.sh +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/tests/__init__.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/tests/conftest.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/tests/data/acceptance_tests_warning/main_requiring_acceptance_tests.plain +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/tests/data/acceptance_tests_warning/required_with_acceptance_tests.plain +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/tests/data/partial_rendering/pr_code_var.plain +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/tests/data/partial_rendering/pr_implement.plain +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/tests/data/partial_rendering/pr_leaf.plain +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/tests/data/partial_rendering/pr_middle.plain +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/tests/data/partial_rendering/pr_root.plain +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/tests/data/partial_rendering/pr_solo.plain +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/tests/e2e/Dockerfile +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/tests/e2e/conftest.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/tests/e2e/test_hello_world_python.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/tests/e2e/test_hello_world_python_windows.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/tests/test_change_detection.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/tests/test_cli_output.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/tests/test_conformance_fix_journal.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/tests/test_console_log_styles.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/tests/test_distill_conformance_test_memory.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/tests/test_dry_run_link_validation.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/tests/test_folder_path_resolution.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/tests/test_git_preflight.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/tests/test_git_utils.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/tests/test_headless_logging.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/tests/test_log_file_name_resolution.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/tests/test_logging_config_path_resolution.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/tests/test_partial_rendering.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/tests/test_path_resolution.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/tests/test_plain2code.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/tests/test_plain2code_utils.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/tests/test_plain_modules.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/tests/test_prepare_repositories_layout.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/tests/test_resolve_config_file.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/tests/test_script_path_resolution.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/tests/test_system_config.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/tests/test_telemetry.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/tests/test_tui_components.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/tests/test_tui_usage.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/tests/test_usage_summary.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/tui/__init__.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/tui/components.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/tui/models.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/tui/plain2code_tui.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/tui/plain_module_render_choice_tui.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/tui/spinner.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/tui/state_handlers.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/tui/styles.css +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/tui/widget_helpers.py +0 -0
- {codeplain-0.3.12.dev26 → codeplain-0.3.13}/usage_summary.py +0 -0
|
@@ -4,11 +4,22 @@ updates:
|
|
|
4
4
|
directory: "/"
|
|
5
5
|
schedule:
|
|
6
6
|
interval: "weekly"
|
|
7
|
-
|
|
7
|
+
# Skip releases younger than two days. Security updates are never delayed.
|
|
8
|
+
cooldown:
|
|
9
|
+
default-days: 2
|
|
10
|
+
open-pull-requests-limit: 5
|
|
11
|
+
# "chore(deps): ..." — also applies to pip security update PRs.
|
|
8
12
|
commit-message:
|
|
9
|
-
prefix: "
|
|
13
|
+
prefix: "chore"
|
|
14
|
+
include: "scope"
|
|
10
15
|
labels:
|
|
11
16
|
- "dependencies"
|
|
17
|
+
# Routine bumps arrive as one weekly PR; majors stay separate.
|
|
18
|
+
groups:
|
|
19
|
+
pip-minor-and-patch:
|
|
20
|
+
update-types:
|
|
21
|
+
- "minor"
|
|
22
|
+
- "patch"
|
|
12
23
|
|
|
13
24
|
# Keeps the SHA-pinned actions in publish-to-pypi.yml patched.
|
|
14
25
|
- package-ecosystem: "github-actions"
|
|
@@ -13,17 +13,17 @@ jobs:
|
|
|
13
13
|
steps:
|
|
14
14
|
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
|
|
15
15
|
|
|
16
|
-
- uses: actions/setup-python@
|
|
16
|
+
- uses: actions/setup-python@6d4fd22b20465ccc0f7354476588e8df7c9ca0e0 # v7.1.0
|
|
17
17
|
with:
|
|
18
18
|
python-version: '3.12'
|
|
19
19
|
|
|
20
20
|
- run: pip install pytest
|
|
21
21
|
|
|
22
22
|
- name: Set up Docker Buildx
|
|
23
|
-
uses: docker/setup-buildx-action@
|
|
23
|
+
uses: docker/setup-buildx-action@f87e5991a6d7451dcb8d9637bfbc97413f497069 # v4.4.1
|
|
24
24
|
|
|
25
25
|
- name: Build E2E image (cached)
|
|
26
|
-
uses: docker/build-push-action@
|
|
26
|
+
uses: docker/build-push-action@c3c9e263c25d99ce0380d002d59b67737d91b0dc # v7.4.0
|
|
27
27
|
with:
|
|
28
28
|
context: .
|
|
29
29
|
file: tests/e2e/Dockerfile
|
|
@@ -50,7 +50,7 @@ jobs:
|
|
|
50
50
|
steps:
|
|
51
51
|
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
|
|
52
52
|
|
|
53
|
-
- uses: actions/setup-python@
|
|
53
|
+
- uses: actions/setup-python@6d4fd22b20465ccc0f7354476588e8df7c9ca0e0 # v7.1.0
|
|
54
54
|
with:
|
|
55
55
|
python-version: '3.12'
|
|
56
56
|
|
|
@@ -14,7 +14,7 @@ jobs:
|
|
|
14
14
|
steps:
|
|
15
15
|
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
|
|
16
16
|
- name: Set up Python
|
|
17
|
-
uses: actions/setup-python@
|
|
17
|
+
uses: actions/setup-python@6d4fd22b20465ccc0f7354476588e8df7c9ca0e0 # v7.1.0
|
|
18
18
|
with:
|
|
19
19
|
python-version: ${{ env.PYTHON_VERSION }}
|
|
20
20
|
- name: Cache pip
|
|
@@ -35,7 +35,7 @@ jobs:
|
|
|
35
35
|
steps:
|
|
36
36
|
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
|
|
37
37
|
- name: Set up Python
|
|
38
|
-
uses: actions/setup-python@
|
|
38
|
+
uses: actions/setup-python@6d4fd22b20465ccc0f7354476588e8df7c9ca0e0 # v7.1.0
|
|
39
39
|
with:
|
|
40
40
|
python-version: ${{ env.PYTHON_VERSION }}
|
|
41
41
|
- name: Cache pip
|
|
@@ -56,7 +56,7 @@ jobs:
|
|
|
56
56
|
steps:
|
|
57
57
|
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
|
|
58
58
|
- name: Set up Python
|
|
59
|
-
uses: actions/setup-python@
|
|
59
|
+
uses: actions/setup-python@6d4fd22b20465ccc0f7354476588e8df7c9ca0e0 # v7.1.0
|
|
60
60
|
with:
|
|
61
61
|
python-version: ${{ env.PYTHON_VERSION }}
|
|
62
62
|
- name: Cache pip
|
|
@@ -77,7 +77,7 @@ jobs:
|
|
|
77
77
|
steps:
|
|
78
78
|
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
|
|
79
79
|
- name: Set up Python
|
|
80
|
-
uses: actions/setup-python@
|
|
80
|
+
uses: actions/setup-python@6d4fd22b20465ccc0f7354476588e8df7c9ca0e0 # v7.1.0
|
|
81
81
|
with:
|
|
82
82
|
python-version: ${{ env.PYTHON_VERSION }}
|
|
83
83
|
- name: Cache pip
|
|
@@ -98,7 +98,7 @@ jobs:
|
|
|
98
98
|
steps:
|
|
99
99
|
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
|
|
100
100
|
- name: Set up Python
|
|
101
|
-
uses: actions/setup-python@
|
|
101
|
+
uses: actions/setup-python@6d4fd22b20465ccc0f7354476588e8df7c9ca0e0 # v7.1.0
|
|
102
102
|
with:
|
|
103
103
|
python-version: ${{ env.PYTHON_VERSION }}
|
|
104
104
|
- name: Configure git for tests
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
name: Notify Slack on Merge to Main
|
|
2
|
+
|
|
3
|
+
# pull_request_target runs this file from main with secrets, so merged PRs from
|
|
4
|
+
# forks post too. Nothing from the PR is checked out or run; the title only
|
|
5
|
+
# reaches the shell through an env var.
|
|
6
|
+
on:
|
|
7
|
+
pull_request_target:
|
|
8
|
+
types: [closed]
|
|
9
|
+
branches:
|
|
10
|
+
- main
|
|
11
|
+
|
|
12
|
+
permissions: {}
|
|
13
|
+
|
|
14
|
+
jobs:
|
|
15
|
+
notify:
|
|
16
|
+
runs-on: ubuntu-latest
|
|
17
|
+
if: github.event.pull_request.merged == true && vars.SLACK_CHANNEL_ID != ''
|
|
18
|
+
steps:
|
|
19
|
+
# Slack reads <, > and & as markup: escape them so a PR title cannot
|
|
20
|
+
# mention @channel or rewrite the link.
|
|
21
|
+
- name: Escape the PR title for Slack
|
|
22
|
+
id: pr
|
|
23
|
+
env:
|
|
24
|
+
TITLE: ${{ github.event.pull_request.title }}
|
|
25
|
+
run: |
|
|
26
|
+
printf 'title=%s\n' "$(printf '%s' "$TITLE" | tr '\r\n' ' ' | sed -e 's/&/\&/g' -e 's/</\</g' -e 's/>/\>/g')" >> "$GITHUB_OUTPUT"
|
|
27
|
+
|
|
28
|
+
- name: Send notification to Slack
|
|
29
|
+
uses: slackapi/slack-github-action@dcb1066f776dd043e64d0e8ba94ca15cc7e1875d # v4.0.0
|
|
30
|
+
with:
|
|
31
|
+
method: chat.postMessage
|
|
32
|
+
token: ${{ secrets.SLACK_BOT_TOKEN }}
|
|
33
|
+
errors: true
|
|
34
|
+
# toJSON quotes the title, so quotes and colons in it keep the payload valid.
|
|
35
|
+
payload: |
|
|
36
|
+
channel: ${{ vars.SLACK_CHANNEL_ID }}
|
|
37
|
+
text: ${{ toJSON(format('[Codeplain Client] PR <{0}|#{1}: {2}> was merged to main by `{3}`.', github.event.pull_request.html_url, github.event.pull_request.number, steps.pr.outputs.title, github.actor)) }}
|
|
@@ -33,7 +33,7 @@ jobs:
|
|
|
33
33
|
version: ${{ steps.version.outputs.version }}
|
|
34
34
|
|
|
35
35
|
steps:
|
|
36
|
-
- uses: actions/checkout@
|
|
36
|
+
- uses: actions/checkout@v7
|
|
37
37
|
with:
|
|
38
38
|
# hatch-vcs derives the version from git tags, so we need full history.
|
|
39
39
|
fetch-depth: 0
|
|
@@ -92,7 +92,7 @@ jobs:
|
|
|
92
92
|
|
|
93
93
|
- name: Store the distribution packages
|
|
94
94
|
if: steps.version.outputs.should-publish == 'true'
|
|
95
|
-
uses: actions/upload-artifact@
|
|
95
|
+
uses: actions/upload-artifact@v7
|
|
96
96
|
with:
|
|
97
97
|
name: dev-package-distributions
|
|
98
98
|
path: dist/
|
|
@@ -110,12 +110,9 @@ jobs:
|
|
|
110
110
|
# authenticate this run — no long-lived API token needed.
|
|
111
111
|
id-token: write
|
|
112
112
|
|
|
113
|
-
env:
|
|
114
|
-
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }}
|
|
115
|
-
|
|
116
113
|
steps:
|
|
117
114
|
- name: Download distribution packages
|
|
118
|
-
uses: actions/download-artifact@
|
|
115
|
+
uses: actions/download-artifact@v8
|
|
119
116
|
with:
|
|
120
117
|
name: dev-package-distributions
|
|
121
118
|
path: dist/
|
|
@@ -127,21 +124,57 @@ jobs:
|
|
|
127
124
|
# version should be a no-op, not a red build.
|
|
128
125
|
skip-existing: true
|
|
129
126
|
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
127
|
+
# End-of-run notices run in their own job: a failed Slack post fails only this
|
|
128
|
+
# job, not the publish or its GitHub deployment, and "Re-run failed jobs"
|
|
129
|
+
# re-posts without publishing again.
|
|
130
|
+
notify:
|
|
131
|
+
name: Notify Slack
|
|
132
|
+
needs: [build, publish-dev]
|
|
133
|
+
if: ${{ !cancelled() && vars.SLACK_CHANNEL_ID != '' }}
|
|
134
|
+
runs-on: ubuntu-latest
|
|
135
|
+
|
|
136
|
+
steps:
|
|
137
|
+
- name: Short SHA
|
|
138
|
+
run: echo "SHORT_SHA=${GITHUB_SHA:0:7}" >> "$GITHUB_ENV"
|
|
139
|
+
|
|
140
|
+
- name: Notify Slack (build failure)
|
|
141
|
+
if: ${{ needs.build.result == 'failure' }}
|
|
142
|
+
uses: slackapi/slack-github-action@dcb1066f776dd043e64d0e8ba94ca15cc7e1875d # v4.0.0
|
|
143
|
+
with:
|
|
144
|
+
method: chat.postMessage
|
|
145
|
+
token: ${{ secrets.SLACK_BOT_TOKEN }}
|
|
146
|
+
errors: true
|
|
147
|
+
payload: |
|
|
148
|
+
channel: ${{ vars.SLACK_CHANNEL_ID }}
|
|
149
|
+
text: >-
|
|
150
|
+
*Codeplain Client*: Building the dev build FAILED :x: (commit `${{ env.SHORT_SHA }}`). Nothing was published to PyPI.
|
|
151
|
+
See <${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}|the run log>.
|
|
141
152
|
|
|
142
153
|
- name: Notify Slack (failure)
|
|
143
|
-
if: ${{
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
154
|
+
if: ${{ needs.publish-dev.result == 'failure' }}
|
|
155
|
+
uses: slackapi/slack-github-action@dcb1066f776dd043e64d0e8ba94ca15cc7e1875d # v4.0.0
|
|
156
|
+
with:
|
|
157
|
+
method: chat.postMessage
|
|
158
|
+
token: ${{ secrets.SLACK_BOT_TOKEN }}
|
|
159
|
+
errors: true
|
|
160
|
+
payload: |
|
|
161
|
+
channel: ${{ vars.SLACK_CHANNEL_ID }}
|
|
162
|
+
text: >-
|
|
163
|
+
*Codeplain Client*: Publishing dev build to PyPI FAILED :x: (commit `${{ env.SHORT_SHA }}`).
|
|
164
|
+
See <${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}|the run log>.
|
|
165
|
+
|
|
166
|
+
# Spell out the --pre install: a plain "pip install codeplain" will
|
|
167
|
+
# NOT pick this up, which otherwise reads as a broken publish.
|
|
168
|
+
- name: Notify Slack (success)
|
|
169
|
+
if: ${{ needs.publish-dev.result == 'success' }}
|
|
170
|
+
uses: slackapi/slack-github-action@dcb1066f776dd043e64d0e8ba94ca15cc7e1875d # v4.0.0
|
|
171
|
+
with:
|
|
172
|
+
method: chat.postMessage
|
|
173
|
+
token: ${{ secrets.SLACK_BOT_TOKEN }}
|
|
174
|
+
errors: true
|
|
175
|
+
payload: |
|
|
176
|
+
channel: ${{ vars.SLACK_CHANNEL_ID }}
|
|
177
|
+
text: >-
|
|
178
|
+
*Codeplain Client*: dev build `${{ needs.build.outputs.version }}` published to PyPI :test_tube:.
|
|
179
|
+
Normal installs are unaffected — try it with `pip install --pre codeplain==${{ needs.build.outputs.version }}`.
|
|
180
|
+
Pre-release builds talk to `api.test.codeplain.ai` by default.
|
|
@@ -14,9 +14,6 @@ jobs:
|
|
|
14
14
|
name: Upload to Cloudflare R2
|
|
15
15
|
runs-on: ubuntu-latest
|
|
16
16
|
|
|
17
|
-
env:
|
|
18
|
-
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }}
|
|
19
|
-
|
|
20
17
|
steps:
|
|
21
18
|
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
|
|
22
19
|
|
|
@@ -57,17 +54,43 @@ jobs:
|
|
|
57
54
|
--content-type "text/plain"
|
|
58
55
|
echo "✓ examples.ps1 uploaded to R2"
|
|
59
56
|
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
57
|
+
# End-of-run notices run in their own job: a failed Slack post fails only this
|
|
58
|
+
# job, and "Re-run failed jobs" re-posts without uploading again.
|
|
59
|
+
notify:
|
|
60
|
+
name: Notify Slack
|
|
61
|
+
needs: publish
|
|
62
|
+
if: ${{ !cancelled() && vars.SLACK_CHANNEL_ID != '' }}
|
|
63
|
+
runs-on: ubuntu-latest
|
|
64
|
+
permissions: {}
|
|
65
|
+
|
|
66
|
+
steps:
|
|
67
|
+
- name: Short SHA
|
|
68
|
+
run: echo "SHORT_SHA=${GITHUB_SHA:0:7}" >> "$GITHUB_ENV"
|
|
66
69
|
|
|
67
70
|
- name: Notify Slack (failure)
|
|
68
|
-
if: ${{
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
71
|
+
if: ${{ needs.publish.result == 'failure' }}
|
|
72
|
+
uses: slackapi/slack-github-action@dcb1066f776dd043e64d0e8ba94ca15cc7e1875d # v4.0.0
|
|
73
|
+
with:
|
|
74
|
+
method: chat.postMessage
|
|
75
|
+
token: ${{ secrets.SLACK_BOT_TOKEN }}
|
|
76
|
+
errors: true
|
|
77
|
+
payload: |
|
|
78
|
+
channel: ${{ vars.SLACK_CHANNEL_ID }}
|
|
79
|
+
text: >-
|
|
80
|
+
*Codeplain Client*: Install script deploy to R2 FAILED :x: (`${{ env.SHORT_SHA }}`).
|
|
81
|
+
Users may be getting a stale installer.
|
|
82
|
+
See <${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}|the run log>.
|
|
83
|
+
|
|
84
|
+
- name: Notify Slack (success)
|
|
85
|
+
if: ${{ needs.publish.result == 'success' }}
|
|
86
|
+
uses: slackapi/slack-github-action@dcb1066f776dd043e64d0e8ba94ca15cc7e1875d # v4.0.0
|
|
87
|
+
with:
|
|
88
|
+
method: chat.postMessage
|
|
89
|
+
token: ${{ secrets.SLACK_BOT_TOKEN }}
|
|
90
|
+
errors: true
|
|
91
|
+
payload: |
|
|
92
|
+
channel: ${{ vars.SLACK_CHANNEL_ID }}
|
|
93
|
+
text: >-
|
|
94
|
+
*Codeplain Client*: Install scripts deployed to R2 :white_check_mark:
|
|
95
|
+
(`${{ env.SHORT_SHA }}`, by *${{ github.actor }}*).
|
|
73
96
|
|
|
@@ -0,0 +1,241 @@
|
|
|
1
|
+
name: Publish to PyPI
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
release:
|
|
5
|
+
types: [published]
|
|
6
|
+
|
|
7
|
+
# Least privilege by default: jobs get no GITHUB_TOKEN scopes unless they
|
|
8
|
+
# opt in below.
|
|
9
|
+
permissions: {}
|
|
10
|
+
|
|
11
|
+
jobs:
|
|
12
|
+
build:
|
|
13
|
+
name: Build distribution
|
|
14
|
+
runs-on: ubuntu-latest
|
|
15
|
+
permissions:
|
|
16
|
+
contents: write
|
|
17
|
+
outputs:
|
|
18
|
+
# The notify job replies in the start notice's thread.
|
|
19
|
+
slack-ts: ${{ steps.slack-start.outputs.ts }}
|
|
20
|
+
|
|
21
|
+
steps:
|
|
22
|
+
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
|
|
23
|
+
with:
|
|
24
|
+
# hatch-vcs derives the version from git tags, so we need full history.
|
|
25
|
+
fetch-depth: 0
|
|
26
|
+
|
|
27
|
+
# Non-fatal: Slack being down must not block the release.
|
|
28
|
+
- name: Notify Slack (start)
|
|
29
|
+
id: slack-start
|
|
30
|
+
if: ${{ vars.SLACK_CHANNEL_ID != '' }}
|
|
31
|
+
continue-on-error: true
|
|
32
|
+
uses: slackapi/slack-github-action@dcb1066f776dd043e64d0e8ba94ca15cc7e1875d # v4.0.0
|
|
33
|
+
with:
|
|
34
|
+
method: chat.postMessage
|
|
35
|
+
token: ${{ secrets.SLACK_BOT_TOKEN }}
|
|
36
|
+
errors: true
|
|
37
|
+
payload: |
|
|
38
|
+
channel: ${{ vars.SLACK_CHANNEL_ID }}
|
|
39
|
+
text: >-
|
|
40
|
+
*Codeplain Client*: Release `${{ github.ref_name }}` published by *${{ github.actor }}*
|
|
41
|
+
— building and publishing to PyPI...
|
|
42
|
+
|
|
43
|
+
- name: Install uv
|
|
44
|
+
# uv provisions its own Python (honoring requires-python), so no
|
|
45
|
+
# separate actions/setup-python step is needed.
|
|
46
|
+
run: |
|
|
47
|
+
curl -LsSf https://astral.sh/uv/install.sh | sh
|
|
48
|
+
echo "$HOME/.local/bin" >> $GITHUB_PATH
|
|
49
|
+
|
|
50
|
+
- name: Build package
|
|
51
|
+
# hatch-vcs reads the version straight from the release tag.
|
|
52
|
+
run: |
|
|
53
|
+
uv build
|
|
54
|
+
echo "Built distributions:"
|
|
55
|
+
ls -l dist/
|
|
56
|
+
|
|
57
|
+
- name: Store the distribution packages
|
|
58
|
+
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
|
|
59
|
+
with:
|
|
60
|
+
name: python-package-distributions
|
|
61
|
+
path: dist/
|
|
62
|
+
|
|
63
|
+
- name: Upload assets to GitHub Release
|
|
64
|
+
env:
|
|
65
|
+
GH_TOKEN: ${{ github.token }}
|
|
66
|
+
run: |
|
|
67
|
+
gh release upload ${{ github.ref_name }} dist/* --clobber
|
|
68
|
+
|
|
69
|
+
publish-to-pypi:
|
|
70
|
+
name: Publish to PyPI
|
|
71
|
+
needs: build
|
|
72
|
+
runs-on: ubuntu-latest
|
|
73
|
+
environment:
|
|
74
|
+
name: pypi
|
|
75
|
+
url: https://pypi.org/p/codeplain
|
|
76
|
+
permissions:
|
|
77
|
+
# Mint a short-lived OIDC token so PyPI Trusted Publishing can
|
|
78
|
+
# authenticate this run — no long-lived API token needed.
|
|
79
|
+
id-token: write
|
|
80
|
+
|
|
81
|
+
steps:
|
|
82
|
+
- name: Download distribution packages
|
|
83
|
+
uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v8.0.1
|
|
84
|
+
with:
|
|
85
|
+
name: python-package-distributions
|
|
86
|
+
path: dist/
|
|
87
|
+
|
|
88
|
+
- name: Publish to PyPI
|
|
89
|
+
uses: pypa/gh-action-pypi-publish@7245906fb61fa33a13554f9d5fb856fe61758086 # release/v1
|
|
90
|
+
|
|
91
|
+
# End-of-run notices run in their own job: a failed Slack post fails only this
|
|
92
|
+
# job, not the publish or its GitHub deployment, and "Re-run failed jobs"
|
|
93
|
+
# re-posts without publishing again.
|
|
94
|
+
notify:
|
|
95
|
+
name: Notify Slack
|
|
96
|
+
needs: [build, publish-to-pypi]
|
|
97
|
+
if: ${{ !cancelled() && vars.SLACK_CHANNEL_ID != '' }}
|
|
98
|
+
runs-on: ubuntu-latest
|
|
99
|
+
|
|
100
|
+
env:
|
|
101
|
+
# Notices reply in the start notice's thread, quoted so YAML keeps the ts a
|
|
102
|
+
# string. Without a start notice (its post failed or never ran) this is null,
|
|
103
|
+
# which the Slack client drops, and they post to the channel. Failures are
|
|
104
|
+
# also broadcast to the channel; success stays in the thread.
|
|
105
|
+
THREAD_TS: ${{ needs.build.outputs.slack-ts && format('"{0}"', needs.build.outputs.slack-ts) || 'null' }}
|
|
106
|
+
|
|
107
|
+
steps:
|
|
108
|
+
- name: Notify Slack (build failure)
|
|
109
|
+
if: ${{ needs.build.result == 'failure' }}
|
|
110
|
+
uses: slackapi/slack-github-action@dcb1066f776dd043e64d0e8ba94ca15cc7e1875d # v4.0.0
|
|
111
|
+
with:
|
|
112
|
+
method: chat.postMessage
|
|
113
|
+
token: ${{ secrets.SLACK_BOT_TOKEN }}
|
|
114
|
+
errors: true
|
|
115
|
+
payload: |
|
|
116
|
+
channel: ${{ vars.SLACK_CHANNEL_ID }}
|
|
117
|
+
thread_ts: ${{ env.THREAD_TS }}
|
|
118
|
+
reply_broadcast: ${{ env.THREAD_TS != 'null' }}
|
|
119
|
+
text: >-
|
|
120
|
+
*Codeplain Client*: Build of `${{ github.ref_name }}` FAILED :x:. Nothing was published to PyPI.
|
|
121
|
+
See <${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}|the run log>.
|
|
122
|
+
|
|
123
|
+
- name: Notify Slack (failure)
|
|
124
|
+
if: ${{ needs.publish-to-pypi.result == 'failure' }}
|
|
125
|
+
uses: slackapi/slack-github-action@dcb1066f776dd043e64d0e8ba94ca15cc7e1875d # v4.0.0
|
|
126
|
+
with:
|
|
127
|
+
method: chat.postMessage
|
|
128
|
+
token: ${{ secrets.SLACK_BOT_TOKEN }}
|
|
129
|
+
errors: true
|
|
130
|
+
payload: |
|
|
131
|
+
channel: ${{ vars.SLACK_CHANNEL_ID }}
|
|
132
|
+
thread_ts: ${{ env.THREAD_TS }}
|
|
133
|
+
reply_broadcast: ${{ env.THREAD_TS != 'null' }}
|
|
134
|
+
text: >-
|
|
135
|
+
*Codeplain Client*: Publishing `${{ github.ref_name }}` to PyPI FAILED :x:.
|
|
136
|
+
See <${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}|the run log>.
|
|
137
|
+
|
|
138
|
+
# The tag (v0.4.0rc1) without its "v", for the install command below.
|
|
139
|
+
- name: Version from tag
|
|
140
|
+
id: version
|
|
141
|
+
if: ${{ needs.publish-to-pypi.result == 'success' }}
|
|
142
|
+
env:
|
|
143
|
+
TAG: ${{ github.ref_name }}
|
|
144
|
+
run: echo "version=${TAG#v}" >> "$GITHUB_OUTPUT"
|
|
145
|
+
|
|
146
|
+
# GitHub marks the release itself as a pre-release; the tag (v0.4.0rc1)
|
|
147
|
+
# carries the same intent for PEP 440. pip and uv skip pre-releases by
|
|
148
|
+
# default, so "--upgrade" would NOT pick one up. Tell people the command
|
|
149
|
+
# that actually works.
|
|
150
|
+
- name: Notify Slack (pre-release published)
|
|
151
|
+
if: ${{ needs.publish-to-pypi.result == 'success' && github.event.release.prerelease }}
|
|
152
|
+
uses: slackapi/slack-github-action@dcb1066f776dd043e64d0e8ba94ca15cc7e1875d # v4.0.0
|
|
153
|
+
with:
|
|
154
|
+
method: chat.postMessage
|
|
155
|
+
token: ${{ secrets.SLACK_BOT_TOKEN }}
|
|
156
|
+
errors: true
|
|
157
|
+
payload: |
|
|
158
|
+
channel: ${{ vars.SLACK_CHANNEL_ID }}
|
|
159
|
+
thread_ts: ${{ env.THREAD_TS }}
|
|
160
|
+
text: >-
|
|
161
|
+
*Codeplain Client*: pre-release `${{ github.ref_name }}` published to PyPI :test_tube:.
|
|
162
|
+
Normal installs are unaffected — try it with `pip install --pre codeplain==${{ steps.version.outputs.version }}`.
|
|
163
|
+
|
|
164
|
+
- name: Notify Slack (release published)
|
|
165
|
+
if: ${{ needs.publish-to-pypi.result == 'success' && !github.event.release.prerelease }}
|
|
166
|
+
uses: slackapi/slack-github-action@dcb1066f776dd043e64d0e8ba94ca15cc7e1875d # v4.0.0
|
|
167
|
+
with:
|
|
168
|
+
method: chat.postMessage
|
|
169
|
+
token: ${{ secrets.SLACK_BOT_TOKEN }}
|
|
170
|
+
errors: true
|
|
171
|
+
payload: |
|
|
172
|
+
channel: ${{ vars.SLACK_CHANNEL_ID }}
|
|
173
|
+
thread_ts: ${{ env.THREAD_TS }}
|
|
174
|
+
text: >-
|
|
175
|
+
*Codeplain Client*: `${{ github.ref_name }}` published to PyPI :white_check_mark:.
|
|
176
|
+
Install with `pip install --upgrade codeplain`.
|
|
177
|
+
|
|
178
|
+
# Success also puts a ✅ on the start notice, so the result shows in the
|
|
179
|
+
# channel without another message. Needs the app's reactions:write scope.
|
|
180
|
+
# Non-fatal: the result is already posted, and a re-run gets already_reacted.
|
|
181
|
+
- name: Notify Slack (✅ on the start notice)
|
|
182
|
+
if: ${{ needs.publish-to-pypi.result == 'success' && env.THREAD_TS != 'null' }}
|
|
183
|
+
continue-on-error: true
|
|
184
|
+
uses: slackapi/slack-github-action@dcb1066f776dd043e64d0e8ba94ca15cc7e1875d # v4.0.0
|
|
185
|
+
with:
|
|
186
|
+
method: reactions.add
|
|
187
|
+
token: ${{ secrets.SLACK_BOT_TOKEN }}
|
|
188
|
+
errors: true
|
|
189
|
+
payload: |
|
|
190
|
+
channel: ${{ vars.SLACK_CHANNEL_ID }}
|
|
191
|
+
timestamp: ${{ env.THREAD_TS }}
|
|
192
|
+
name: white_check_mark
|
|
193
|
+
|
|
194
|
+
# Release pipelines to be turned on only after the rest of the infrastructure
|
|
195
|
+
# is ready.
|
|
196
|
+
#
|
|
197
|
+
# # Runs only after the package is on PyPI. Kept as its own job so the publish job
|
|
198
|
+
# # keeps its minimal permissions and no checkout.
|
|
199
|
+
# linear-release:
|
|
200
|
+
# name: Record release in Linear
|
|
201
|
+
# needs: [build, publish-to-pypi]
|
|
202
|
+
# runs-on: ubuntu-latest
|
|
203
|
+
#
|
|
204
|
+
# permissions:
|
|
205
|
+
# contents: read
|
|
206
|
+
#
|
|
207
|
+
# steps:
|
|
208
|
+
# - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
|
|
209
|
+
# with:
|
|
210
|
+
# # The scan needs full history.
|
|
211
|
+
# fetch-depth: 0
|
|
212
|
+
#
|
|
213
|
+
# # Non-fatal: the package is already published.
|
|
214
|
+
# - name: Record release in Linear
|
|
215
|
+
# id: linear
|
|
216
|
+
# continue-on-error: true
|
|
217
|
+
# uses: linear/linear-release-action@0a25abab892a91062ebf42260dbb2ce6277aa205 # v0.16.0
|
|
218
|
+
# with:
|
|
219
|
+
# access_key: ${{ secrets.LINEAR_ACCESS_KEY }}
|
|
220
|
+
# version: ${{ github.ref_name }}
|
|
221
|
+
# # Pin the CLI the action downloads, not just the action.
|
|
222
|
+
# cli_version: v0.16.0
|
|
223
|
+
#
|
|
224
|
+
# # continue-on-error keeps the job green, so this checks the step's own
|
|
225
|
+
# # outcome — `failure()` would never fire.
|
|
226
|
+
# - name: Notify Slack (release not recorded)
|
|
227
|
+
# if: ${{ steps.linear.outcome == 'failure' && vars.SLACK_CHANNEL_ID != '' }}
|
|
228
|
+
# env:
|
|
229
|
+
# # See the notify job.
|
|
230
|
+
# THREAD_TS: ${{ needs.build.outputs.slack-ts && format('"{0}"', needs.build.outputs.slack-ts) || 'null' }}
|
|
231
|
+
# uses: slackapi/slack-github-action@dcb1066f776dd043e64d0e8ba94ca15cc7e1875d # v4.0.0
|
|
232
|
+
# with:
|
|
233
|
+
# method: chat.postMessage
|
|
234
|
+
# token: ${{ secrets.SLACK_BOT_TOKEN }}
|
|
235
|
+
# errors: true
|
|
236
|
+
# payload: |
|
|
237
|
+
# channel: ${{ vars.SLACK_CHANNEL_ID }}
|
|
238
|
+
# thread_ts: ${{ env.THREAD_TS }}
|
|
239
|
+
# text: >-
|
|
240
|
+
# *Codeplain Client*: `${{ github.ref_name }}` is on PyPI, but recording it in Linear FAILED :warning:.
|
|
241
|
+
# See <${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}|the run log>.
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.5
|
|
2
2
|
Name: codeplain
|
|
3
|
-
Version: 0.3.
|
|
3
|
+
Version: 0.3.13
|
|
4
4
|
Summary: Transform plain language specifications into working code
|
|
5
5
|
License-File: LICENSE
|
|
6
6
|
Classifier: Environment :: Console
|
|
@@ -8,23 +8,23 @@ Classifier: Intended Audience :: Developers
|
|
|
8
8
|
Classifier: Operating System :: OS Independent
|
|
9
9
|
Classifier: Topic :: Software Development :: Code Generators
|
|
10
10
|
Requires-Python: ==3.11.*
|
|
11
|
-
Requires-Dist: gitpython==3.1
|
|
11
|
+
Requires-Dist: gitpython==3.2.1
|
|
12
12
|
Requires-Dist: mistletoe==1.6.0
|
|
13
|
-
Requires-Dist:
|
|
13
|
+
Requires-Dist: plain-parser==0.1.4
|
|
14
14
|
Requires-Dist: python-frontmatter==1.3.0
|
|
15
15
|
Requires-Dist: python-liquid2==0.4.0
|
|
16
16
|
Requires-Dist: pyyaml==6.0.3
|
|
17
17
|
Requires-Dist: requests==2.34.2
|
|
18
18
|
Requires-Dist: rich==15.0.0
|
|
19
|
-
Requires-Dist: sentry-sdk==2.
|
|
19
|
+
Requires-Dist: sentry-sdk==2.73.0
|
|
20
20
|
Requires-Dist: textual>=7.5.0
|
|
21
21
|
Requires-Dist: tiktoken==0.14.0
|
|
22
22
|
Requires-Dist: transitions==0.9.3
|
|
23
23
|
Provides-Extra: dev
|
|
24
|
-
Requires-Dist: black==26.
|
|
25
|
-
Requires-Dist: flake8==7.
|
|
26
|
-
Requires-Dist: isort==
|
|
27
|
-
Requires-Dist: mypy==2.
|
|
24
|
+
Requires-Dist: black==26.10.1; extra == 'dev'
|
|
25
|
+
Requires-Dist: flake8==7.4.1; extra == 'dev'
|
|
26
|
+
Requires-Dist: isort==9.0.2; extra == 'dev'
|
|
27
|
+
Requires-Dist: mypy==2.4.0; extra == 'dev'
|
|
28
28
|
Requires-Dist: pytest==9.1.1; extra == 'dev'
|
|
29
29
|
Description-Content-Type: text/markdown
|
|
30
30
|
|
|
@@ -308,38 +308,6 @@ class CodeplainAPI:
|
|
|
308
308
|
|
|
309
309
|
return self.post_request(endpoint_url, headers, payload, run_state)
|
|
310
310
|
|
|
311
|
-
def fix_unittests_issue(
|
|
312
|
-
self,
|
|
313
|
-
frid,
|
|
314
|
-
plain_source_tree,
|
|
315
|
-
linked_resources,
|
|
316
|
-
existing_files_content,
|
|
317
|
-
module_name: str,
|
|
318
|
-
required_modules,
|
|
319
|
-
unittests_issue,
|
|
320
|
-
run_state: RunState,
|
|
321
|
-
conformance_tests_fixes: list[dict] | None = None,
|
|
322
|
-
):
|
|
323
|
-
endpoint_url = f"{self.api_url}/fix_unittests_issue"
|
|
324
|
-
headers = {"X-API-Key": self.api_key, "Content-Type": "application/json"}
|
|
325
|
-
|
|
326
|
-
payload = {
|
|
327
|
-
"frid": frid,
|
|
328
|
-
"plain_source_tree": plain_source_tree,
|
|
329
|
-
"linked_resources": linked_resources,
|
|
330
|
-
"existing_files_content": existing_files_content,
|
|
331
|
-
"module_name": module_name,
|
|
332
|
-
"required_modules": required_modules,
|
|
333
|
-
"unittests_issue": unittests_issue,
|
|
334
|
-
"unittest_batch_id": run_state.unittest_batch_id,
|
|
335
|
-
}
|
|
336
|
-
# Implementation code changes made by the conformance tests fixer right before this unit tests run;
|
|
337
|
-
# only sent when unit tests are processed inside the conformance tests phase.
|
|
338
|
-
if conformance_tests_fixes is not None:
|
|
339
|
-
payload["conformance_tests_fixes"] = conformance_tests_fixes
|
|
340
|
-
|
|
341
|
-
return self.post_request(endpoint_url, headers, payload, run_state)
|
|
342
|
-
|
|
343
311
|
def distill_conformance_test_memory(
|
|
344
312
|
self,
|
|
345
313
|
frid,
|
|
@@ -613,3 +581,29 @@ class CodeplainAPI:
|
|
|
613
581
|
}
|
|
614
582
|
|
|
615
583
|
return self.post_request(endpoint_url, headers, payload, run_state)
|
|
584
|
+
|
|
585
|
+
def agent_start(self, task_type: str, task_params: dict, frid: str, module_name: str, run_state: RunState):
|
|
586
|
+
"""Start a server-side agent session; returns the first turn (tool calls or completion)."""
|
|
587
|
+
endpoint_url = f"{self.api_url}/agent/start"
|
|
588
|
+
headers = {"X-API-Key": self.api_key, "Content-Type": "application/json"}
|
|
589
|
+
payload = {
|
|
590
|
+
"task_type": task_type,
|
|
591
|
+
"task_params": task_params,
|
|
592
|
+
"frid": frid,
|
|
593
|
+
"module_name": module_name,
|
|
594
|
+
}
|
|
595
|
+
return self.post_request(endpoint_url, headers, payload, run_state)
|
|
596
|
+
|
|
597
|
+
def agent_continue(
|
|
598
|
+
self, session_id: str, tool_results: list[dict], frid: str, module_name: str, run_state: RunState
|
|
599
|
+
):
|
|
600
|
+
"""Feed tool results into an agent session and run its next turn."""
|
|
601
|
+
endpoint_url = f"{self.api_url}/agent/continue"
|
|
602
|
+
headers = {"X-API-Key": self.api_key, "Content-Type": "application/json"}
|
|
603
|
+
payload = {
|
|
604
|
+
"session_id": session_id,
|
|
605
|
+
"tool_results": tool_results,
|
|
606
|
+
"frid": frid,
|
|
607
|
+
"module_name": module_name,
|
|
608
|
+
}
|
|
609
|
+
return self.post_request(endpoint_url, headers, payload, run_state)
|