Bug 5836 - Target model needs table for image names and sizes
Summary: Target model needs table for image names and sizes
Status: VERIFIED FIXED
Alias: None
Product: Toaster
Classification: Build System, Metadata & Runtime
Component: toaster (show other bugs)
Version: 1.6
Hardware: All Multiple
: Medium normal
Target Milestone: 1.6 M4
Assignee: Alexandru Damian
QA Contact:
URL:
Whiteboard: needs data completion test
Depends on:
Blocks:
 
Reported: 2014-02-18 03:35 UTC by David Reyna
Modified: 2014-03-20 09:39 UTC (History)
5 users (show)

See Also:
OS type for building Yocto: ---
Type of Regression: ---
Verified:
Documentation change: No (bug/feature does not impact docs)


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description David Reyna 2014-02-18 03:35:56 UTC
The Target table has the members "file_name" and "file_size" for its image file(s). However, a target can and mostly likely will have multiple generated images, and while the name will be the same (modulo the file name extensions from Build.image_fstypes) each image will have a different file size.

The requirement is to create a new table of Target image names and sizes, keyed to the parent Target pk.

For example:

  class Target_Image_File(models.Model):
    target = models.ForeignKey(Target,related_name='target_image')
    file_name = models.FilePathField(max_length=255, blank=True)
    file_size = models.IntegerField()
Comment 1 Alexandru Damian 2014-02-20 11:12:42 UTC
Added, data is not collected yet.
Comment 2 Alexandru Damian 2014-03-11 12:46:17 UTC
Database change merged into toaster/master.
Comment 3 Andreea Brandusa Proca 2014-03-20 09:39:04 UTC
Verified in master:ac4ff568f5b2ad4f50a1b7b60797e7b797c314bb