Fish Trophy

brennie got a fish trophy!

Generate commit histories with Mercurial

Review Request #10101 — Created July 24, 2018 and updated

brennie
RBTools
master
9b3cdd2...
rbtools

The Mercurial SCM tool can now generate commit histories so that it can
be used to create review requests with history.

TODO. Support still needs to be added to RB

  • 0
  • 0
  • 12
  • 2
  • 14
Description From Last Updated
Checks run (1 failed, 1 succeeded)
flake8 failed.
JSHint passed.

flake8

brennie
chipx86
  1. 
      
  2. rbtools/clients/mercurial.py (Diff revision 2)
     
     

    Byte string prefix?

    We'd need it above as well.

  3. rbtools/clients/mercurial.py (Diff revision 2)
     
     
     

    Byte string prefix?

  4. 
      
brennie
brennie
chipx86
  1. 
      
  2. rbtools/clients/mercurial.py (Diff revision 4)
     
     
     

    Alphabetical order.

  3. rbtools/clients/mercurial.py (Diff revision 4)
     
     
     
     
     
     
     
     
     
     
     

    This should say that it raises NotImplementedError under the conditions.

  4. rbtools/clients/mercurial.py (Diff revision 4)
     
     
     

    It'd be nice to know where the revisions come from.

  5. rbtools/clients/mercurial.py (Diff revision 4)
     
     

    Just to check, is \\x1f right, or would \x1f be right?

    1. \ is correct. We are giving the string "\x1f" (instead of the character 0x1F) to Hg. Ill switch it to a raw string.

  6. rbtools/clients/mercurial.py (Diff revision 4)
     
     
     

    We use these special markers in several places. Let's make them constants so it's readable and consistent.

    1. We actually use \x1f (the character) and \\x1f (a string which contains a python escape sequence).

  7. 
      
brennie
chipx86
  1. 
      
  2. rbtools/clients/mercurial.py (Diff revision 5)
     
     
     

    This was reordered but wasn't put in alphabetical order.

  3. rbtools/clients/mercurial.py (Diff revision 5)
     
     

    I think the function name changed in a parent change. Can you retest with that?

    1. it did but the call sites didnt change. Ill fix that up.

  4. rbtools/clients/mercurial.py (Diff revision 5)
     
     

    Must be the full path: rbtools.clients.errors.SCMError.

  5. rbtools/clients/mercurial.py (Diff revision 5)
     
     
     

    It'd be nice to have these as constants like with Git, to help with readability.

  6. 
      
brennie
david
  1. 
      
  2. rbtools/clients/mercurial.py (Diff revision 6)
     
     
     
     

    Is there any reason why we couldn't just do if entry['parent2'] != self.NO_PARENT? We don't use it elsewhere, and it seems like it's always going to be present (pop will throw an exception by default if not).

    1. It will always be present, but we do not want it present in the history entry.

    2. Can you add a comment explaining that?

  3. 
      
brennie
Review request changed

Change Summary:

addressed feedback

Commit:

-9ef4b914a78636778f6ea6d1a1a912655d16798c
+9b3cdd22774f16cfc676cec183eef9d893428b43

Diff:

Revision 7 (+92 -2)

Show changes

Checks run (2 succeeded)

flake8 passed.
JSHint passed.
david
  1. Ship It!
  2. 
      
Loading...