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

Fix mutable default argument #2635

Merged
merged 1 commit into from
Sep 29, 2024
Merged

Fix mutable default argument #2635

merged 1 commit into from
Sep 29, 2024

Conversation

yqkcn
Copy link
Contributor

@yqkcn yqkcn commented Sep 28, 2024

What problem does this PR solve?

The default value of Python function parameters cannot be mutable. Modifying this parameter inside the function will permanently change the default value

Type of change

  • Bug Fix (non-breaking change which fixes an issue)

@KevinHuSh KevinHuSh merged commit 604061c into infiniflow:main Sep 29, 2024
1 check passed
Halfknow pushed a commit to Halfknow/ragflow that referenced this pull request Nov 11, 2024
### What problem does this PR solve?

The default value of Python function parameters cannot be mutable.
Modifying this parameter inside the function will permanently change the
default value

### Type of change

- [x] Bug Fix (non-breaking change which fixes an issue)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants