organize needs to run after build in stage

Bug #1628098 reported by Sergio Schvezov
22
This bug affects 4 people
Affects Status Importance Assigned to Milestone
Snapcraft
Fix Released
High
Kyle Fazzari

Bug Description

If not files that would not conflict if organized would show up as conflicts.
Other options is to make the transaction and check take into account the organization.

Joe Talbott (joetalbott)
Changed in snapcraft:
assignee: nobody → Joe Talbott (joetalbott)
status: Triaged → In Progress
Revision history for this message
Joe Talbott (joetalbott) wrote :
Revision history for this message
Joe Talbott (joetalbott) wrote :

Should 'stage' refer to filenames pre or post-organize?

eg.

parts:
  organize:
    plugin: dump
    source: .
    organize:
      test: bin/
    stage:
      - bin/test # or 'test'?
    prime:
      - bin/test

Revision history for this message
Kyle Fazzari (kyrofa) wrote :

From https://github.com/snapcore/snapcraft/blob/master/docs/snapcraft-syntax.md:

"organize (yaml subsection) A dictionary exposing replacements, the key is the internal name whilst the value the exposed name, filesets will refer to the exposed named applied after organization is applied."

Note that filesets are made to be used in stage/prime filters so they must refer to the organized names.

Kyle Fazzari (kyrofa)
Changed in snapcraft:
status: In Progress → Confirmed
assignee: Joe Talbott (joetalbott) → nobody
Revision history for this message
Kyle Fazzari (kyrofa) wrote :

I've actually gone the other direction with it, and made it happen in build instead. Solves all the same problems, while being super simple: https://github.com/snapcore/snapcraft/pull/2047

Changed in snapcraft:
status: Confirmed → In Progress
assignee: nobody → Kyle Fazzari (kyrofa)
Kyle Fazzari (kyrofa)
Changed in snapcraft:
status: In Progress → Fix Committed
Changed in snapcraft:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.