-
Notifications
You must be signed in to change notification settings - Fork 145
Description
Describe the bug
When performing structural optimization tasks for 2D materials, I set:
markdown
#vdW correction
vdw_method d3_0
However, the calculation failed with the error:
**KILLED BY SIGNAL: 9 (Killed)**
After troubleshooting, I discovered that enabling vdw_method requires explicitly declaring dft_functional. While I believe this mandatory requirement is unnecessary (as defaulting to PBE should be acceptable), I adjusted the input accordingly.
However, I need to understand why the error directly triggered SIGNAL: 9 instead of a predefined error message.
Key Questions:
**Why is dft_functional mandatory when vdw_method is enabled?**
Even if the code defaults to PBE, some implementations may enforce explicit declarations for consistency or to avoid ambiguity in parameter selection (e.g., D3 corrections may require functional-specific settings).
**Why does the code crash with SIGNAL: 9 instead of a user-friendly error?**
SIGNAL: 9 typically indicates a process was forcibly terminated by the system (e.g., out-of-memory, segmentation fault, or resource limits). Possible causes:
**Missing Input Handling: The code might lack proper error-checking for unset dft_functional, leading to undefined behavior (e.g., accessing uninitialized variables).
Memory Issues: Incorrect parameterization could cause abnormal memory allocation, triggering system-level termination.
Code-Specific Bugs:** Poor error handling in the DFT code itself (e.g., uncaught exceptions or asserts).
Suggested Actions:
Explicitly declare dft_functional even if using default values.
Check logs/debug outputs for memory or segmentation fault clues.
Report the issue to the code developers, emphasizing the need for graceful error handling.
Expected behavior
No response
To Reproduce
No response
Environment
No response
Additional Context
No response
Task list for Issue attackers (only for developers)
- Verify the issue is not a duplicate.
- Describe the bug.
- Steps to reproduce.
- Expected behavior.
- Error message.
- Environment details.
- Additional context.
- Assign a priority level (low, medium, high, urgent).
- Assign the issue to a team member.
- Label the issue with relevant tags.
- Identify possible related issues.
- Create a unit test or automated test to reproduce the bug (if applicable).
- Fix the bug.
- Test the fix.
- Update documentation (if necessary).
- Close the issue and inform the reporter (if applicable).

