Snappy install fails cryptically if meta/readme.md doesn't have two lines

Bug #1400308 reported by Robin Winslow on 2014-12-08
10
This bug affects 2 people
Affects Status Importance Assigned to Milestone
Snappy
Medium
Barry Warsaw

Bug Description

The "meta/readme.md" file must have at least 2 lines of text.

If the file is empty, I get this error:

https://pastebin.canonical.com/121892/

If the file only has one line, I get this error:

https://pastebin.canonical.com/121893/

I also get that error if the readme has a blank line, or an "=" in it (perfectly valid markdown).

Related branches

summary: - Snappy install cryptically if meta/readme.md doesn't have two lines
+ Snappy install fails cryptically if meta/readme.md doesn't have two
+ lines
description: updated
Barry Warsaw (barry) on 2014-12-09
Changed in snappy-ubuntu:
assignee: nobody → Barry Warsaw (barry)
importance: Undecided → Medium
status: New → Triaged
Barry Warsaw (barry) wrote :

The 'empty readme.md' problem is because the resulting DEBIAN/control file has an empty Description: header, and this breaks dpkg (which does the underlying install). My thought is that `snappy build` should recognize this case and add a dummy header like "No description available".

Let's see what the second one is...

Barry Warsaw (barry) wrote :

snappy build just does blind fp.readline()'s of the readme.md file and doesn't check that the lines are empty (signaling EOF). I think in those cases, since downstream consumers of the manifest require non-empty strings for the title and description, it makes sense to just check for EOF/empty-line in those cases and use dummy titles and descriptions.

Barry Warsaw (barry) wrote :

Or... snappy build should complain loudly and fail.

Michael Vogt (mvo) wrote :

This is fixed in ppa:snappy-dev/tools-proposed

Changed in snappy-ubuntu:
status: Triaged → Fix Committed
Martin Pitt (pitti) on 2014-12-14
information type: Embargoed → Public
Michael Vogt (mvo) on 2015-03-31
Changed in snappy-ubuntu:
status: Fix Committed → Fix Released
Michael Terry (mterry) on 2015-05-18
affects: snappy-ubuntu → snappy
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers