Skip to content

Commit f21c736

Browse files
Copilotnjzjz
andauthored
fix: remove VASP pseudopotential linking from CP2K FP workflow (#1802)
CP2K workflows were incorrectly calling VASP-style pseudopotential linking functions, causing `KeyError: 'fp_pp_path'` when these VASP-specific parameters weren't provided. ## Problem The `make_fp_cp2k` function was unconditionally calling `_link_fp_vasp_pp()`, which expects `fp_pp_path` and `fp_pp_files` parameters. However, CP2K manages pseudopotentials and basis sets through: - Directives in CP2K input templates - Environment variables (e.g., `CP2K_DATA_DIR`) - Built-in pseudopotential libraries CP2K does not use VASP-style symbolic linking of pseudopotential files. ## Solution Completely removed the `_link_fp_vasp_pp()` call from `make_fp_cp2k`. This change: - ✅ Eliminates the KeyError when `fp_pp_path`/`fp_pp_files` are not provided - ✅ Properly decouples CP2K from VASP-style pseudopotential handling - ✅ Aligns with CP2K's native workflow requirements - ✅ Maintains all existing CP2K functionality ## Testing All existing tests pass, including CP2K-specific tests. The `param-ch4.json` example now works correctly without requiring any pseudopotential configuration parameters. Fixes #1754. <!-- START COPILOT CODING AGENT TIPS --> --- 💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more [Copilot coding agent tips](https://gh.io/copilot-coding-agent-tips) in the docs. --------- Co-authored-by: copilot-swe-agent[bot] <[email protected]> Co-authored-by: njzjz <[email protected]>
1 parent ad30c4f commit f21c736

File tree

1 file changed

+0
-3
lines changed

1 file changed

+0
-3
lines changed

dpgen/generator/run.py

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3791,9 +3791,6 @@ def make_fp_cp2k(iter_index, jdata):
37913791
fp.close()
37923792
os.chdir(cwd)
37933793

3794-
# link pp files
3795-
_link_fp_vasp_pp(iter_index, jdata)
3796-
37973794

37983795
def make_fp_pwmat(iter_index, jdata):
37993796
# abs path for fp_incar if it exists

0 commit comments

Comments
 (0)