Skip to content

refactor: convert appmode misc if/elif to match/case (#30001)#34869

Merged
asukaminato0721 merged 1 commit intolanggenius:mainfrom
dataCenter430:refactor/match-case-appmode-misc
Apr 10, 2026
Merged

refactor: convert appmode misc if/elif to match/case (#30001)#34869
asukaminato0721 merged 1 commit intolanggenius:mainfrom
dataCenter430:refactor/match-case-appmode-misc

Conversation

@dataCenter430
Copy link
Copy Markdown
Contributor

Complete the issue: #30001

Changes

Convert if/elif chains on SegmentType controllers enum to exhaustive match/case statements in token_buffer_memory.py, file_input_compat.py and app_dsl_service.py.

Part of #30001.

Files changed

  • api/core/memory/token_buffer_memory.py
  • api/models/utils/file_input_compat.py
  • api/services/app_dsl_service.py

All tests passed.

@dosubot dosubot Bot added size:L This PR changes 100-499 lines, ignoring generated files. refactor labels Apr 9, 2026
@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Apr 9, 2026

Pyrefly Diff

No changes detected.

@dosubot dosubot Bot added the lgtm This PR has been approved by a maintainer label Apr 10, 2026
@asukaminato0721 asukaminato0721 added this pull request to the merge queue Apr 10, 2026
Merged via the queue into langgenius:main with commit 1117b6e Apr 10, 2026
26 of 27 checks passed
dataCenter430 added a commit to dataCenter430/dify that referenced this pull request Apr 10, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

lgtm This PR has been approved by a maintainer refactor size:L This PR changes 100-499 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants