那为什么还要报错remote: error: File wandb/run-20240116_141410-8p3edhag/run-8p3edhag.wandb is 148.54 MB; this exceeds GitHub's file size limit of 100.00 MB
这可能是因为该文件仍然存在于 Git 的历史记录中,尽管在当前分支中已删除。GitHub 在接收推送时会检查所有提交的文件,包括历史记录中的文件。即使文件已从当前分支中删除,但如果它仍然存在于历史记录中且超出了GitHub的文件大小限制,GitHub仍会报告错误。
要解决此问题,你需要对 Git 历史进行清理,以彻底删除该文件。你可以使用以下命令进行重写历史并清除该文件的记录:
git filter-branch --force --index-filter 'git rm --cached --ignore-unmatch wandb/run-20240116_141410-8p3edhag/run-8p3edhag.wandb' --prune-empty --tag-name-filter cat -- --all