git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH] git-p4: parse marshal output "p4 -G" in p4 changes

From
miguel torroja <miguel.torroja@gmail.com>
Date
Jun 30, 2017, 08:22 UTC
Message-ID
<CAKYtbVajVpJomKOHG5ex7ib9Mtm8z+=mvQOrR1ws6wnASt9LFw@mail.gmail.com>
In-Reply-To
<CAE5ih7-go9PampG3Ltbx2-vYUezbN4QDHEVEHwpfXkpvUfLCaQ@mail.gmail.com>

The Latest patch I sent was already the squashed version with the fix to pass the tests.

Thanks,
On Fri, Jun 30, 2017 at 9:56 AM, Luke Diamand <luke@diamand.org> wrote:
Show 55 quoted lines
> On 29 June 2017 at 23:41, miguel torroja <miguel.torroja@gmail.com> wrote:
>> On Thu, Jun 29, 2017 at 8:59 AM, Luke Diamand <luke@diamand.org> wrote:
>>> On 28 June 2017 at 14:14, miguel torroja <miguel.torroja@gmail.com> wrote:
>>>> Thanks Luke,
>>>>
>>>> regarding the error in t9800 (not ok 18 - unresolvable host in P4PORT
>>>> should display error), for me it's very weird too as it doesn't seem
>>>> to be related to this particular change, as the patch changes are not
>>>> exercised with that test.
>>>
>>> I had a look at this. The problem is that the old code uses
>>> p4_read_pipe_lines() which calls sys.exit() if the subprocess fails.
>>>
>>> But the new code calls p4CmdList() which has does error handling by
>>> setting "p4ExitCode" to a non-zero value in the returned dictionary.
>>>
>>> I think if you just check for that case, the test will then pass
>>
>> Thank you for debugging this,  I did as you suggested and it passed that test!
>>
>>>>
>>>> The test 21 in t9807 was precisely the new test added to test the
>>>> change (it was passing with local setup), the test log is truncated
>>>> before the output of test 21 in t9807 but I'm afraid I'm not very
>>>> familiar with Travis, so maybe I'm missing something. Is there a way
>>>> to have the full logs or they are always truncated after some number
>>>> of lines?
>>>
>>> For me, t9807 is working fine.
>>>
>>>>
>>>> I think you get an error with git diff --check because I added spaces
>>>> after a tab, but those spaces are intentional, the tabs are for the
>>>> "<<-EOF" and spaces are for the "p4 triggers" specificiation.
>>>
>>> OK.
>>>
>>
>> In the end, ,the reason t9807 was not passing was precisely the tabs
>> and spaces of the patch. the original patch had:
>> <tab><tab><spaces>....., as I explained, the tabs were supposed to be
>> ignored by "<<-EOF" and the spaces were supposed to be sent to stdin
>> of p4 triggers, but when the patch was applied to upstream the
>> <spaces> were substituted by tabs what led to a malformed  "p4
>> trigger" description. I just collapsed the description in one single
>> line and now it's passing
>>>
>>> Luke
>>
>>
>> I'm sending a new patch with the two changes I just mentioned.
>
> Looks good to me, Ack. Can we squash the two changes together?
>
> Luke
Previous: Luke DiamandNext: Miguel Torroja
Message 13 of 31 in “git-p4: changelist template with p4 -G change -o”
  1. git-p4: changelist template with p4 -G change -oMiguel Torroja, Jun 20, 2017
  2. Junio C HamanoJun 22, 2017
  3. Luke DiamandJun 24, 2017
  4. miguel torrojaJun 24, 2017
  5. Lars SchneiderJun 24, 2017
  6. miguel torrojaJun 27, 2017
  7. git-p4: parse marshal output "p4 -G" in p4 changesMiguel Torroja, Jun 27, 2017
  8. Junio C HamanoJun 28, 2017
  9. Luke DiamandJun 28, 2017
  10. miguel torrojaJun 28, 2017
  11. miguel torrojaJun 29, 2017
  12. Luke DiamandJun 30, 2017
  13. miguel torrojaJun 30, 2017
  14. git-p4: parse marshal output "p4 -G" in p4 changesMiguel Torroja, Jun 29, 2017
  15. Lars SchneiderJun 30, 2017
  16. Miguel TorrojaJun 30, 2017
  17. Lars SchneiderJun 30, 2017
  18. Miguel TorrojaJun 30, 2017
  19. Miguel TorrojaJul 3, 2017
  20. git-p4: parse marshal output "p4 -G" in p4 changesMiguel Torroja, Jul 3, 2017
  21. Luke DiamandJul 11, 2017
  22. Miguel TorrojaJul 11, 2017
  23. git-p4: parse marshal output "p4 -G" in p4 changesMiguel Torroja, Jul 11, 2017
  24. Luke DiamandJul 12, 2017
  25. Miguel TorrojaJul 12, 2017
  26. Junio C HamanoJul 12, 2017
  27. 1/3 git-p4: git-p4 tests with p4 triggersMiguel Torroja, Jul 13, 2017
  28. 2/3 git-p4: parse marshal output "p4 -G" in p4 changesMiguel Torroja, Jul 13, 2017
  29. 3/3 git-p4: filter for {'code':'info'} in p4CmdListMiguel Torroja, Jul 13, 2017
  30. Miguel TorrojaJul 13, 2017
  31. Junio C HamanoJul 13, 2017

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.