> On July 7, 2015, 9:42 p.m., Vinod Kone wrote:
> > support/post-reviews.py, line 173
> > <https://reviews.apache.org/r/35777/diff/2/?file=1001308#file1001308line173>
> >
> > Why 'format' instead of directly printing the message with a %s? Just
> > curious.
It's a more portable way of printing - also, using `format()` allows for better
ways of formatting messages.
Personally, now I'm always using (if I still have to support Python 2.7):
```
from future import __print_function__
...
print("foo bar {baz}".format(baz=something))
```
but that's pedantic me :)
- Marco
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/35777/#review90785
-----------------------------------------------------------
On July 7, 2015, 3:19 p.m., Michael Park wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/35777/
> -----------------------------------------------------------
>
> (Updated July 7, 2015, 3:19 p.m.)
>
>
> Review request for mesos, Benjamin Hindman, Marco Massenzio, and Till
> Toenshoff.
>
>
> Repository: mesos
>
>
> Description
> -------
>
> (1) Handles the case where the `Review: ...` line isn't the last of the
> commit message.
>
> ```
> 01596ce802669e9dac7dd24193f041cef3354830 - Fixed post-reviews.py hanging bug.
> (6 seconds ago)
>
> ReviewBoard URL must be the last line of the commit message!
>
> Fixed post-reviews.py hanging bug.
>
> Review: https://reviews.apache.org/r/35771
>
> abcd
> ```
>
> (2) Handles the case where the ReviewBoard URL is invalid.
>
> ```
> af081a07234794f60a2575e0383ce537d7111c18 - Fixed post-reviews.py hanging bug.
> (29 seconds ago)
>
> Invalid ReviewBoard URL : 'https://reviews.apache.org/r/35771 abcd'
> ```
>
>
> Diffs
> -----
>
> support/post-reviews.py b04e26b85e6b056098c15078f9b31dc352682351
>
> Diff: https://reviews.apache.org/r/35777/diff/
>
>
> Testing
> -------
>
> Modified the commit message with `git rebase` and ran
> `./support/post-reviews.py` to observe the above error messages.
> Used the valid commit message for this patch and created it by running
> `./support/post-reviews.py`.
>
>
> Thanks,
>
> Michael Park
>
>