问题
A p4 check-in failed with the following error:
Submit aborted -- fix problems then use 'p4 submit -c XXXX'.
Some file(s) could not be transferred from client.
I read another solution on the site about how incorrect filetypes might be the problem.
How do I get more information regarding the error in p4?
回答1:
Typically you will see this error on submit when there is a file in the changelist that does not exist on the client, and therefore cannot be transferred to the server. There are at least two conditions that can cause this problem:-
First, Perforce allows you to add files to your changelist (via
p4 add
) that don't exist. Just drop to a prompt and typep4 add blahblah.txt
(assuming blahblah.txt doesn't exist). Perforce will happily add a file to your default changelist. If you try and submit that changelist (and the file still doesn't exist), then you will get the above error).Second, you can
p4 edit
a file, then delete it locally, then try and submit the file (or the changelist that the file was in). You will get the same error.
If you are using the command line or p4win (or p4v I presume), then there will be output that will tell you the offending file(s). You might see lines like:
open for read: d:\path\to\file\somefile.txt: The system cannot find the file specified.
This error will tell you that the file doesn't exist. This output will be in the output pane in p4win, or will show up in the output spew from the p4 command line.
回答2:
Resolving problems for large changeset submission failures
I had to submit a changeset recently that had 400,000+ files, and it failed with the error:
Submit aborted -- fix problems then use 'p4 submit -c 11111'.
There was not enough history in the console buffer to review what failed and what succeeded. So I ran the command suggested in the error message and output stdout to a file:
p4 submit -c 11111 > p4_submit_11111.txt
When this ran, errors (stderr) was output to the commandline, allowing me to resolve the problems (as described in other answers). In my case, it was a file I'd added to the changeset but since deleted, as per the first point in Mark's answer:
open for read: /home/myUserName/yada/_files.txt: No such file or directory
So to deal with this, I just reverted it from the changeset...
$ p4 revert /home/myUserName/yada/_files.txt
//P4Root/Proj1/yada/_files.txt#none - was add, unlocked and abandoned
... and then re-submitted the changelist using the same command:
p4 submit -c 11111 > p4_submit_11111.txt
This submit succeeded.
回答3:
Sometimes P4 fails to submit files, that contain unusual encodings. To resolve the problem, revert them, then use
p4 add -t binary <fileset>
回答4:
Another reason: P4 considers ANSI-encoded file to be <Unicode>.
ANSI file cannot be generally treated as UTF-8 file (which P4 calls <unicode>
) because not all byte sequences in UTF-8 encoding are valid and P4 produces the following error in such a case:
Translation of file content failed near line 384 file D:\P4
\etc\file.txt
Submit aborted -- fix problems then use 'p4 submit -c 125'.
Some file(s) could not be transferred from client.
In this case, checking line 384 revealed that it contained character ľ
and the file was encoded in ANSI, but Perforce automatically and mistakenly marked it as <unicode>
(UTF-8).
Solution: perforce filetype and actual file content must be put in sync
if application related to the file allows that, convert the file to UTF-8 and keep file type
<unicode>
.
Generally, this is better solution – you get the file ready for international and special characters.if file must me kept in ANSI, change file type to
<text>
回答5:
When this usually happens it's because either you don't have access to the files, or rights to push them in.
When this happens to me I break up the changelist into pieces to find the offender. This can be done in a number of ways. Ask a new question if you need pointers.
回答6:
Perforce may also not like the naming of your file.
e.g. example@somefile.txt: The system cannot find the file specified.
回答7:
In my case, I had an "undo-undo" changelist where I was fixing an issue with a previous submit. To fix the issue I had made changes to another file which was showing in the changelist, however, it showed the error when I tried to submit (Submit aborted -- fix problems then use 'p4 submit -c xxxx'.)
I noticed on right click in the P4V client that the file was "not checked out" (even though it was showing in the changelist as modified).
The solution : I checked it out again manually, and was then able to submit fine.
来源:https://stackoverflow.com/questions/1268632/p4-submit-aborted-error-how-to-resolve