Code review comment for lp:~abentley/launchpad/empty-conflicts

Revision history for this message
Aaron Bentley (abentley) wrote :

= Summary =
This fixes bug #515775, which is caused by our new conflict-detection.
Unfortunately, the code in place for handling conflicts assumed only None
indicated no conflicts, but our new conflict detection (unlike MAD), uses the
empty string.

== Proposed fix ==
Update our UI to treat '' as indicating no conflicts.

== Pre-implementation notes ==
Post-implementation call with Thumper.

== Implementation details ==
This determination was previously made by the PreviewDiff's link formatter,
but is now changed to be a method on the model class.

Some lint fixes were made to other code.

== Tests ==
bin/test -vt PreviewDiff -t FormatterAPI

== Demo and Q/A ==
Create a merge proposal that has a diff with no conflicts. Observe that it
does not say "(has conflicts)".

= Launchpad lint =

Checking for conflicts. and issues in doctests and templates.
Running jslint, xmllint, pyflakes, and pylint.
Using normal rules.

Linting changed files:
  lib/lp/code/browser/diff.py
  lib/lp/code/model/diff.py
  lib/lp/testing/factory.py
  lib/lp/code/model/tests/test_diff.py
  lib/lp/code/browser/tests/test_diff.py
  lib/lp/code/interfaces/diff.py
  lib/lp/code/templates/branchmergeproposal-pagelet-summary.pt

== Pylint notices ==

lib/lp/code/model/diff.py
    18: [F0401] Unable to import 'lazr.delegates' (No module named delegates)
    209: [W0703, Diff.fromFile] Catch "Exception"

lib/lp/testing/factory.py
    1619: [F0401, LaunchpadObjectFactory.makeRecipe] Unable to import 'bzrlib.plugins.builder.recipe' (No module named builder)

lib/lp/code/interfaces/diff.py
    20: [F0401] Unable to import 'lazr.restful.fields' (No module named restful)
    21: [F0401] Unable to import 'lazr.restful.declarations' (No module named restful)

« Back to merge proposal