Skip to content

feat: 在 Noneflow 工作流评论处增设 Noneflow 运行历史#393

Merged
he0119 merged 13 commits intomainfrom
feat/history
May 27, 2025
Merged

feat: 在 Noneflow 工作流评论处增设 Noneflow 运行历史#393
he0119 merged 13 commits intomainfrom
feat/history

Conversation

@BigOrangeQWQ
Copy link
Copy Markdown
Member

@BigOrangeQWQ BigOrangeQWQ commented May 26, 2025

close #370

Copilot AI review requested due to automatic review settings May 26, 2025 09:54
@github-actions github-actions Bot added the enhancement New feature or request label May 26, 2025
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR adds functionality to display Noneflow run history in workflow comments. Key changes include removing unused fields from snapshot comparisons in tests, refactoring comment APIs to use a new resuable comment mechanism, and incorporating workflow history parsing and rendering in both utils and templates.

Reviewed Changes

Copilot reviewed 19 out of 19 changed files in this pull request and generated no comments.

Show a summary per file
File Description
tests/providers/docker_test/test_docker_plugin_test.py Removed unused metadata/config fields from snapshot assertions.
tests/plugins/github/publish/utils/test_history_workflow.py Added tests to verify parsing of workflow history from comments.
tests/plugins/github/publish/utils/test_comment_issue.py Updated tests to use the new resuable_comment_issue API.
tests/plugins/github/render/test_publish_render_error.py Updated test functions to accept an additional mock_datetime parameter and include history details.
tests/plugins/github/publish/render/test_publish_render_data.py Added history test details in rendered comment snapshots.
tests/plugins/github/publish/process/test_publish_check_plugin.py Added history details in plugin check tests.
src/plugins/github/plugins/remove/init.py, src/plugins/github/plugins/config/init.py Updated calls to use resuable_comment_issue for comment reuse.
src/plugins/github/plugins/publish/utils.py Added history workflow parsing support and new constant definitions.
src/plugins/github/plugins/publish/templates/comment.md.jinja Inserted history test details block in the comment template.
src/plugins/github/plugins/publish/render.py Modified render_comment to accept and include workflow history.
src/plugins/github/plugins/publish/init.py Integrated workflow history retrieval and passing into render_comment.
src/plugins/github/handlers/issue.py, src/plugins/github/handlers/github.py Refactored comment API methods to support comment reuse with history retrieval.
tests/conftest.py Set datetime mocking fixture to autouse for reliable datetime outputs.

@codecov
Copy link
Copy Markdown

codecov Bot commented May 26, 2025

Codecov Report

Attention: Patch coverage is 98.00000% with 1 line in your changes missing coverage. Please review.

Project coverage is 93.72%. Comparing base (e8a7112) to head (bc2af4e).

✅ All tests successful. No failed tests found.

Files with missing lines Patch % Lines
src/plugins/github/plugins/publish/__init__.py 85.71% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main     #393      +/-   ##
==========================================
+ Coverage   93.67%   93.72%   +0.04%     
==========================================
  Files          41       41              
  Lines        2278     2311      +33     
==========================================
+ Hits         2134     2166      +32     
- Misses        144      145       +1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@he0119 he0119 force-pushed the feat/history branch 2 times, most recently from a6b2ff4 to 4795e25 Compare May 26, 2025 16:54
Comment thread tests/plugins/github/publish/render/test_publish_render_error.py Outdated
Comment thread src/plugins/github/plugins/publish/render.py
@he0119 he0119 merged commit 00b735e into main May 27, 2025
3 checks passed
@he0119 he0119 deleted the feat/history branch May 27, 2025 07:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

feat: 在 Noneflow 工作流评论处增设 Noneflow 运行历史

3 participants