All of lore.kernel.org
 help / color / mirror / Atom feed
* Errors and Warnings listing on the dashboard page.
@ 2014-02-20 11:18 Amit Kumar Chaudhary
  2014-02-20 15:04 ` Damian, Alexandru
                   ` (3 more replies)
  0 siblings, 4 replies; 13+ messages in thread
From: Amit Kumar Chaudhary @ 2014-02-20 11:18 UTC (permalink / raw)
  To: toaster

[-- Attachment #1: Type: text/plain, Size: 1544 bytes --]

Hello, 

I am just beginning with the toaster and web apps in general, and I am trying to add errors and warning listing to the build dashboard page, as prototyped at

https://www.yoctoproject.org/toaster/build-dashboard-failed.html#errors

I am trying to re-use the following code --

<td>{{build.errors_no}}:{% if  build.errors_no %}{% for error in logs %}{% if error.build == build %}{% if error.level == 2 %}<p>{{error.message}}</p>{% endif %}{% endif %}{% endfor %}{% else %}None{% endif %}</td>

from ~/poky-contrib/bitbake/lib/toaster/bldviewer/templates/simple_build.html.

And, I am expecting the logs, for example at
~/poky-contrib/build/tmp/log/cooker/qemux86/20140213120738.log

to be read via LogMessage class below

class LogMessage(models.Model):
    INFO = 0
    WARNING = 1
    ERROR = 2

    LOG_LEVEL = ( (INFO, "info"),
            (WARNING, "warn"),
            (ERROR, "error") )

    build = models.ForeignKey(Build)
    level = models.IntegerField(choices=LOG_LEVEL, default=INFO)
—>    message=models.CharField(max_length=240)
    pathname = models.FilePathField(max_length=255, blank=True)
    lineno = models.IntegerField(null=True)

implemented in ~/poky-contrib/bitbake/lib/toaster/orm/models.py.

But, I can’t seem to find the code that does it, reading from the log file to the sqlite table. Could someone please point me to the files/path that might contain this code, or such code for other tables.

Thanks!

-- 
Amit Kumar Chaudhary

[-- Attachment #2: Type: text/html, Size: 5426 bytes --]

^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: Errors and Warnings listing on the dashboard page.
  2014-02-20 11:18 Errors and Warnings listing on the dashboard page Amit Kumar Chaudhary
@ 2014-02-20 15:04 ` Damian, Alexandru
       [not found] ` <AK2VCmoAADYfUwYZngQa1zNKOTA>
                   ` (2 subsequent siblings)
  3 siblings, 0 replies; 13+ messages in thread
From: Damian, Alexandru @ 2014-02-20 15:04 UTC (permalink / raw)
  To: Amit Kumar Chaudhary; +Cc: toaster

[-- Attachment #1: Type: text/plain, Size: 2457 bytes --]

Hello,

The LogMessage table is designed to hold logs coming from the build process
itself, and not logs that result from normal task execution.
It is the difference between the output displayed from the bitbake command,
and the output from the "make" command in a "do_compile" task.

For the latter case, we currently do not hold/save the content of such log
files. We do not have yet a strategy on determining what log files are
important, and saving everything may be a prohibitive cost in terms of
storage.

Hope this helps,
Alex


On Thu, Feb 20, 2014 at 11:18 AM, Amit Kumar Chaudhary <
amit@floatingpondtech.com> wrote:

> Hello,
>
> I am just beginning with the toaster and web apps in general, and I am
> trying to add errors and warning listing to the build dashboard page, as
> prototyped at
>
> https://www.yoctoproject.org/toaster/build-dashboard-failed.html#errors
>
> I am trying to re-use the following code --
>
> <td>{{build.errors_no}}:{% if  build.errors_no %}{% for error in logs %}{%
> if error.build == build %}{% if error.level == 2
> %}<p>{{error.message}}</p>{% endif %}{% endif %}{% endfor %}{% else
> %}None{% endif %}</td>
>
> from
> ~/poky-contrib/bitbake/lib/toaster/bldviewer/templates/simple_build.html.
>
> And, I am expecting the logs, for example at
> ~/poky-contrib/build/tmp/log/cooker/qemux86/20140213120738.log
>
> to be read via LogMessage class below
>
> class LogMessage(models.Model):
>     INFO = 0
>     WARNING = 1
>     ERROR = 2
>
>     LOG_LEVEL = ( (INFO, "info"),
>             (WARNING, "warn"),
>             (ERROR, "error") )
>
>     build = models.ForeignKey(Build)
>     level = models.IntegerField(choices=LOG_LEVEL, default=INFO)
> —>    message=models.CharField(max_length=240)
>     pathname = models.FilePathField(max_length=255, blank=True)
>     lineno = models.IntegerField(null=True)
>
> implemented in ~/poky-contrib/bitbake/lib/toaster/orm/models.py.
>
> But, I can’t seem to find the code that does it, reading from the log file
> to the sqlite table. Could someone please point me to the files/path that
> might contain this code, or such code for other tables.
>
> Thanks!
>
> --
> Amit Kumar Chaudhary
>
> _______________________________________________
> toaster mailing list
> toaster@yoctoproject.org
> https://lists.yoctoproject.org/listinfo/toaster
>
>


-- 
Alex Damian
Yocto Project
SSG / OTC

[-- Attachment #2: Type: text/html, Size: 6262 bytes --]

^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: Errors and Warnings listing on the dashboard page.
       [not found] ` <AK2VCmoAADYfUwYZngQa1zNKOTA>
@ 2014-02-24 15:16   ` Amit Kumar Chaudhary
       [not found]   ` <AK+VCmoAADfjUwtlVwOu4B9x834>
  1 sibling, 0 replies; 13+ messages in thread
From: Amit Kumar Chaudhary @ 2014-02-24 15:16 UTC (permalink / raw)
  To: Damian, Alexandru; +Cc: toaster

[-- Attachment #1: Type: text/plain, Size: 3678 bytes --]

Thanks Alex,

"The LogMessage table is designed to hold logs coming from the build process itself”

This is the part I was trying to figure out. I have got the handle on how to retrieve the messages from the table, (how those were put in there in the first place is still a mystery), I have added the following code to 'builddashboard(request, build_id)’ function defined in toastergui/views.py 

     context = {
             'build' : Build.objects.filter(pk=build_id)[0],
-            'recipecount' : Recipe.objects.filter(layer_version__id__in=Layer_Version.objects.filter(build=build_id)).count()
+            'recipecount' : Recipe.objects.filter(layer_version__id__in=Layer_Version.objects.filter(build=build_id)).count(),
+            'logmessages': LogMessage.objects.filter(build=build_id),
     }
     return render(request, template, context)

now I can use the logmessages in toastergui/templates/builddashboard.html, using the html code I was trying to re-use below. I have a patch that nearly works, I will clean that up a bit and post it for giving a better picture.

Thanks for all the insights.

-- 
Amit Kumar Chaudhary

On 20 February 2014 at 8:34:36 pm, Damian, Alexandru (alexandru.damian@intel.com) wrote:

Hello,

The LogMessage table is designed to hold logs coming from the build process itself, and not logs that result from normal task execution. 
It is the difference between the output displayed from the bitbake command, and the output from the "make" command in a "do_compile" task.

For the latter case, we currently do not hold/save the content of such log files. We do not have yet a strategy on determining what log files are important, and saving everything may be a prohibitive cost in terms of storage.

Hope this helps,
Alex


On Thu, Feb 20, 2014 at 11:18 AM, Amit Kumar Chaudhary <amit@floatingpondtech.com> wrote:
Hello, 

I am just beginning with the toaster and web apps in general, and I am trying to add errors and warning listing to the build dashboard page, as prototyped at

https://www.yoctoproject.org/toaster/build-dashboard-failed.html#errors

I am trying to re-use the following code --

<td>{{build.errors_no}}:{% if  build.errors_no %}{% for error in logs %}{% if error.build == build %}{% if error.level == 2 %}<p>{{error.message}}</p>{% endif %}{% endif %}{% endfor %}{% else %}None{% endif %}</td>

from ~/poky-contrib/bitbake/lib/toaster/bldviewer/templates/simple_build.html.

And, I am expecting the logs, for example at
~/poky-contrib/build/tmp/log/cooker/qemux86/20140213120738.log

to be read via LogMessage class below

class LogMessage(models.Model):
    INFO = 0
    WARNING = 1
    ERROR = 2

    LOG_LEVEL = ( (INFO, "info"),
            (WARNING, "warn"),
            (ERROR, "error") )

    build = models.ForeignKey(Build)
    level = models.IntegerField(choices=LOG_LEVEL, default=INFO)
—>    message=models.CharField(max_length=240)
    pathname = models.FilePathField(max_length=255, blank=True)
    lineno = models.IntegerField(null=True)

implemented in ~/poky-contrib/bitbake/lib/toaster/orm/models.py.

But, I can’t seem to find the code that does it, reading from the log file to the sqlite table. Could someone please point me to the files/path that might contain this code, or such code for other tables.

Thanks!

-- 
Amit Kumar Chaudhary

_______________________________________________
toaster mailing list
toaster@yoctoproject.org
https://lists.yoctoproject.org/listinfo/toaster




--
Alex Damian
Yocto Project
SSG / OTC 

[-- Attachment #2: Type: text/html, Size: 10244 bytes --]

^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: Errors and Warnings listing on the dashboard page.
  2014-02-20 11:18 Errors and Warnings listing on the dashboard page Amit Kumar Chaudhary
  2014-02-20 15:04 ` Damian, Alexandru
       [not found] ` <AK2VCmoAADYfUwYZngQa1zNKOTA>
@ 2014-02-25 17:22 ` Reyna, David
       [not found] ` <AK+VCmoAAKVFUwzReQybVnuHOhU>
  3 siblings, 0 replies; 13+ messages in thread
From: Reyna, David @ 2014-02-25 17:22 UTC (permalink / raw)
  To: Amit Kumar Chaudhary; +Cc: toaster

[-- Attachment #1: Type: text/plain, Size: 2016 bytes --]

Hi Amit,

We have a scrum meeting every Wednesday morning (8:00 am Pacific Time) with the Yocto team to discuss the Toaster GUI implementation progress and issues. Would you like to join us? I can include you into my invitation.

- David

From: toaster-bounces@yoctoproject.org [mailto:toaster-bounces@yoctoproject.org] On Behalf Of Amit Kumar Chaudhary
Sent: Thursday, February 20, 2014 3:18 AM
To: toaster@yoctoproject.org
Subject: [Toaster] Errors and Warnings listing on the dashboard page.

Hello,

I am just beginning with the toaster and web apps in general, and I am trying to add errors and warning listing to the build dashboard page, as prototyped at

https://www.yoctoproject.org/toaster/build-dashboard-failed.html#errors

I am trying to re-use the following code --

<td>{{build.errors_no}}:{% if  build.errors_no %}{% for error in logs %}{% if error.build == build %}{% if error.level == 2 %}<p>{{error.message}}</p>{% endif %}{% endif %}{% endfor %}{% else %}None{% endif %}</td>

from ~/poky-contrib/bitbake/lib/toaster/bldviewer/templates/simple_build.html.

And, I am expecting the logs, for example at
~/poky-contrib/build/tmp/log/cooker/qemux86/20140213120738.log

to be read via LogMessage class below

class LogMessage(models.Model):
    INFO = 0
    WARNING = 1
    ERROR = 2

    LOG_LEVEL = ( (INFO, "info"),
            (WARNING, "warn"),
            (ERROR, "error") )

    build = models.ForeignKey(Build)
    level = models.IntegerField(choices=LOG_LEVEL, default=INFO)
—>    message=models.CharField(max_length=240)
    pathname = models.FilePathField(max_length=255, blank=True)
    lineno = models.IntegerField(null=True)

implemented in ~/poky-contrib/bitbake/lib/toaster/orm/models.py.

But, I can’t seem to find the code that does it, reading from the log file to the sqlite table. Could someone please point me to the files/path that might contain this code, or such code for other tables.

Thanks!

--
Amit Kumar Chaudhary

[-- Attachment #2: Type: text/html, Size: 12364 bytes --]

^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: Errors and Warnings listing on the dashboard page.
       [not found] ` <AK+VCmoAAKVFUwzReQybVnuHOhU>
@ 2014-02-26  6:54   ` Amit Kumar Chaudhary
  0 siblings, 0 replies; 13+ messages in thread
From: Amit Kumar Chaudhary @ 2014-02-26  6:54 UTC (permalink / raw)
  To: Reyna, David; +Cc: toaster

[-- Attachment #1: Type: text/plain, Size: 2370 bytes --]

Hi David, 

Sure, I would be happy to. Thanks for the invitation.

-- 
Amit Kumar Chaudhary

On 25 February 2014 at 10:52:57 pm, Reyna, David (david.reyna@windriver.com) wrote:

Hi Amit,

 

We have a scrum meeting every Wednesday morning (8:00 am Pacific Time) with the Yocto team to discuss the Toaster GUI implementation progress and issues. Would you like to join us? I can include you into my invitation.

 

- David

 

From: toaster-bounces@yoctoproject.org [mailto:toaster-bounces@yoctoproject.org] On Behalf Of Amit Kumar Chaudhary
Sent: Thursday, February 20, 2014 3:18 AM
To: toaster@yoctoproject.org
Subject: [Toaster] Errors and Warnings listing on the dashboard page.

 

Hello, 

 

I am just beginning with the toaster and web apps in general, and I am trying to add errors and warning listing to the build dashboard page, as prototyped at

 

https://www.yoctoproject.org/toaster/build-dashboard-failed.html#errors

 

I am trying to re-use the following code --

 

<td>{{build.errors_no}}:{% if  build.errors_no %}{% for error in logs %}{% if error.build == build %}{% if error.level == 2 %}<p>{{error.message}}</p>{% endif %}{% endif %}{% endfor %}{% else %}None{% endif %}</td>

 

from ~/poky-contrib/bitbake/lib/toaster/bldviewer/templates/simple_build.html.

 

And, I am expecting the logs, for example at

~/poky-contrib/build/tmp/log/cooker/qemux86/20140213120738.log

 

to be read via LogMessage class below

 

class LogMessage(models.Model):

    INFO = 0

    WARNING = 1

    ERROR = 2

 

    LOG_LEVEL = ( (INFO, "info"),

            (WARNING, "warn"),

            (ERROR, "error") )

 

    build = models.ForeignKey(Build)

    level = models.IntegerField(choices=LOG_LEVEL, default=INFO)

—>    message=models.CharField(max_length=240)

    pathname = models.FilePathField(max_length=255, blank=True)

    lineno = models.IntegerField(null=True)

 

implemented in ~/poky-contrib/bitbake/lib/toaster/orm/models.py.

 

But, I can’t seem to find the code that does it, reading from the log file to the sqlite table. Could someone please point me to the files/path that might contain this code, or such code for other tables.

 

Thanks!

 

-- 

Amit Kumar Chaudhary

[-- Attachment #2: Type: text/html, Size: 11847 bytes --]

^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: Errors and Warnings listing on the dashboard page.
       [not found]   ` <AK+VCmoAADfjUwtlVwOu4B9x834>
@ 2014-02-26 12:13     ` Amit Kumar Chaudhary
  2014-02-26 13:52       ` Barros Pena, Belen
  0 siblings, 1 reply; 13+ messages in thread
From: Amit Kumar Chaudhary @ 2014-02-26 12:13 UTC (permalink / raw)
  To: toaster

[-- Attachment #1: Type: text/plain, Size: 4268 bytes --]

Hello, 

This is the patch I had been working on, It is complete now and works as expected (as the prototype page), can you please review?

http://git.yoctoproject.org/cgit/cgit.cgi/poky-contrib/commit/?h=achaudhary/errors_warning_on_builddashboard&id=1aaada41ec2129bd9bc31cc591b75f6d9bcb7251

Thanks!

-- 
Amit Kumar Chaudhary

On 24 February 2014 at 8:46:21 pm, Amit Kumar Chaudhary (amit@floatingpondtech.com) wrote:

Thanks Alex,

"The LogMessage table is designed to hold logs coming from the build process itself”

This is the part I was trying to figure out. I have got the handle on how to retrieve the messages from the table, (how those were put in there in the first place is still a mystery), I have added the following code to 'builddashboard(request, build_id)’ function defined in toastergui/views.py 

     context = {
             'build' : Build.objects.filter(pk=build_id)[0],
-            'recipecount' : Recipe.objects.filter(layer_version__id__in=Layer_Version.objects.filter(build=build_id)).count()
+            'recipecount' : Recipe.objects.filter(layer_version__id__in=Layer_Version.objects.filter(build=build_id)).count(),
+            'logmessages': LogMessage.objects.filter(build=build_id),
     }
     return render(request, template, context)

now I can use the logmessages in toastergui/templates/builddashboard.html, using the html code I was trying to re-use below. I have a patch that nearly works, I will clean that up a bit and post it for giving a better picture.

Thanks for all the insights.

-- 
Amit Kumar Chaudhary

On 20 February 2014 at 8:34:36 pm, Damian, Alexandru (alexandru.damian@intel.com) wrote:

Hello,

The LogMessage table is designed to hold logs coming from the build process itself, and not logs that result from normal task execution. 
It is the difference between the output displayed from the bitbake command, and the output from the "make" command in a "do_compile" task.

For the latter case, we currently do not hold/save the content of such log files. We do not have yet a strategy on determining what log files are important, and saving everything may be a prohibitive cost in terms of storage.

Hope this helps,
Alex


On Thu, Feb 20, 2014 at 11:18 AM, Amit Kumar Chaudhary <amit@floatingpondtech.com> wrote:
Hello, 

I am just beginning with the toaster and web apps in general, and I am trying to add errors and warning listing to the build dashboard page, as prototyped at

https://www.yoctoproject.org/toaster/build-dashboard-failed.html#errors

I am trying to re-use the following code --

<td>{{build.errors_no}}:{% if  build.errors_no %}{% for error in logs %}{% if error.build == build %}{% if error.level == 2 %}<p>{{error.message}}</p>{% endif %}{% endif %}{% endfor %}{% else %}None{% endif %}</td>

from ~/poky-contrib/bitbake/lib/toaster/bldviewer/templates/simple_build.html.

And, I am expecting the logs, for example at
~/poky-contrib/build/tmp/log/cooker/qemux86/20140213120738.log

to be read via LogMessage class below

class LogMessage(models.Model):
    INFO = 0
    WARNING = 1
    ERROR = 2

    LOG_LEVEL = ( (INFO, "info"),
            (WARNING, "warn"),
            (ERROR, "error") )

    build = models.ForeignKey(Build)
    level = models.IntegerField(choices=LOG_LEVEL, default=INFO)
—>    message=models.CharField(max_length=240)
    pathname = models.FilePathField(max_length=255, blank=True)
    lineno = models.IntegerField(null=True)

implemented in ~/poky-contrib/bitbake/lib/toaster/orm/models.py.

But, I can’t seem to find the code that does it, reading from the log file to the sqlite table. Could someone please point me to the files/path that might contain this code, or such code for other tables.

Thanks!

-- 
Amit Kumar Chaudhary

_______________________________________________
toaster mailing list
toaster@yoctoproject.org
https://lists.yoctoproject.org/listinfo/toaster




--
Alex Damian
Yocto Project
SSG / OTC 
_______________________________________________  
toaster mailing list  
toaster@yoctoproject.org  
https://lists.yoctoproject.org/listinfo/toaster  

[-- Attachment #2: Type: text/html, Size: 13209 bytes --]

^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: Errors and Warnings listing on the dashboard page.
  2014-02-26 12:13     ` Amit Kumar Chaudhary
@ 2014-02-26 13:52       ` Barros Pena, Belen
  2014-02-26 13:59         ` Barros Pena, Belen
  0 siblings, 1 reply; 13+ messages in thread
From: Barros Pena, Belen @ 2014-02-26 13:52 UTC (permalink / raw)
  To: Amit Kumar Chaudhary, toaster

On 26/02/2014 12:13, "Amit Kumar Chaudhary" <amit@floatingpondtech.com>
wrote:

>
>Hello, 
>
>
>This is the patch I had been working on, It is complete now and works as
>expected (as the prototype page), can you please review?
>
>
>http://git.yoctoproject.org/cgit/cgit.cgi/poky-contrib/commit/?h=achaudhar
>y/errors_warning_on_builddashboard&id=1aaada41ec2129bd9bc31cc591b75f6d9bcb
>7251

Hi Amit,

From an interface standpoint, this is looking pretty good. I am however
seeing some mismatch between the number of warnings and the number of
messages shown in the warnings section. It looks like the number of
warnings is displaying the overall number of entries in the orm_logmessage
table. 

The number of warnings should be the number of entries in the
orm_logmessage table with level = 1. The number of errors should be the
number of entries with level = 2.

Any chance you could verify is this what's is being shown in the interface?

Thanks!

Belén


>
>
>Thanks!
>
>
>-- 
>Amit Kumar Chaudhary
>
>
>
>On 24 February 2014 at 8:46:21 pm, Amit Kumar Chaudhary
>(amit@floatingpondtech.com <mailto://amit@floatingpondtech.com>) wrote:
>
>Thanks Alex,
>
>
>"The LogMessage table is designed to hold logs coming from the build
>process itself²
>
>
>This is the part I was trying to figure out. I have got the handle on how
>to retrieve the messages from the table, (how those were put in there in
>the first place is still a mystery),
> I have added the following code to 'builddashboard(request, build_id)¹
>function defined in toastergui/views.py
>
>
>     context = {
>             'build' : Build.objects.filter(pk=build_id)[0],
>-            'recipecount' :
>Recipe.objects.filter(layer_version__id__in=Layer_Version.objects.filter(b
>uild=build_id)).count()
>+            'recipecount' :
>Recipe.objects.filter(layer_version__id__in=Layer_Version.objects.filter(b
>uild=build_id)).count(),
>+            'logmessages': LogMessage.objects.filter(build=build_id),
>     }
>     return render(request, template, context)
>
>
>now I can use the logmessages in
>toastergui/templates/builddashboard.html, using the html code I was
>trying to re-use below. I have a patch that nearly works, I will clean
>that up a bit and post it for giving a better picture.
>
>
>Thanks for all the insights.
>
>
>-- 
>Amit Kumar Chaudhary
>
>
>
>On 20 February 2014 at 8:34:36 pm, Damian, Alexandru
>(alexandru.damian@intel.com <mailto://alexandru.damian@intel.com>) wrote:
>
>Hello,
>
>
>The LogMessage table is designed to hold logs coming from the build
>process itself, and not logs that result from normal task execution.
>It is the difference between the output displayed from the bitbake
>command, and the output from the "make" command in a "do_compile" task.
>
>
>For the latter case, we currently do not hold/save the content of such
>log files. We do not have yet a strategy on determining what log files
>are important, and saving everything may be
> a prohibitive cost in terms of storage.
>
>
>Hope this helps,
>Alex
>
>
>
>On Thu, Feb 20, 2014 at 11:18 AM, Amit Kumar Chaudhary
><amit@floatingpondtech.com> wrote:
>
>Hello, 
>
>
>I am just beginning with the toaster and web apps in general, and I am
>trying to add errors and warning listing to the build dashboard page, as
>prototyped at
>
>
>https://www.yoctoproject.org/toaster/build-dashboard-failed.html#errors
>
>
>I am trying to re-use the following code --
>
>
>
><td>{{build.errors_no}}:{% if  build.errors_no %}{% for error in logs
>%}{% if error.build == build %}{% if error.level == 2
>%}<p>{{error.message}}</p>{% endif %}{% endif %}{% endfor %}{% else
>%}None{% endif %}</td>
>
>
>from 
>~/poky-contrib/bitbake/lib/toaster/bldviewer/templates/simple_build.html.
>
>
>And, I am expecting the logs, for example at
>~/poky-contrib/build/tmp/log/cooker/qemux86/20140213120738.log
>
>
>to be read via LogMessage class below
>
>
>class LogMessage(models.Model):
>    INFO = 0
>    WARNING = 1
>    ERROR = 2
>
>
>    LOG_LEVEL = ( (INFO, "info"),
>            (WARNING, "warn"),
>            (ERROR, "error") )
>
>
>    build = models.ForeignKey(Build)
>    level = models.IntegerField(choices=LOG_LEVEL, default=INFO)
>‹>    message=models.CharField(max_length=240)
>    pathname = models.FilePathField(max_length=255, blank=True)
>    lineno = models.IntegerField(null=True)
>
>
>implemented in ~/poky-contrib/bitbake/lib/toaster/orm/models.py.
>
>
>But, I can¹t seem to find the code that does it, reading from the log
>file to the sqlite table. Could someone please point me to the files/path
>that might contain this code, or such code for other tables.
>
>
>Thanks!
>
>
>
>-- 
>Amit Kumar Chaudhary
>
>
>
>
>_______________________________________________
>toaster mailing list
>toaster@yoctoproject.org
>https://lists.yoctoproject.org/listinfo/toaster
>
>
>
>
>
>
>
>
>--
>Alex Damian
>Yocto Project
>
>SSG / OTC 
>
>
>
>
>
>
>_______________________________________________
>toaster mailing list
>toaster@yoctoproject.org
>https://lists.yoctoproject.org/listinfo/toaster
>
>
>
>



^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: Errors and Warnings listing on the dashboard page.
  2014-02-26 13:52       ` Barros Pena, Belen
@ 2014-02-26 13:59         ` Barros Pena, Belen
  0 siblings, 0 replies; 13+ messages in thread
From: Barros Pena, Belen @ 2014-02-26 13:59 UTC (permalink / raw)
  To: Barros Pena, Belen, Amit Kumar Chaudhary, toaster

And of course I forgot something: sorry about that.

If there are no warnings in a build, the build dashboard is showing a
warnings section saying '0 warnings'. Instead, the warnings section should
not exist when there are no warnings.

Cheers

Belén

On 26/02/2014 13:52, "Barros Pena, Belen" <belen.barros.pena@intel.com>
wrote:

>On 26/02/2014 12:13, "Amit Kumar Chaudhary" <amit@floatingpondtech.com>
>wrote:
>
>>
>>Hello, 
>>
>>
>>This is the patch I had been working on, It is complete now and works as
>>expected (as the prototype page), can you please review?
>>
>>
>>http://git.yoctoproject.org/cgit/cgit.cgi/poky-contrib/commit/?h=achaudha
>>r
>>y/errors_warning_on_builddashboard&id=1aaada41ec2129bd9bc31cc591b75f6d9bc
>>b
>>7251
>
>Hi Amit,
>
>From an interface standpoint, this is looking pretty good. I am however
>seeing some mismatch between the number of warnings and the number of
>messages shown in the warnings section. It looks like the number of
>warnings is displaying the overall number of entries in the orm_logmessage
>table. 
>
>The number of warnings should be the number of entries in the
>orm_logmessage table with level = 1. The number of errors should be the
>number of entries with level = 2.
>
>Any chance you could verify is this what's is being shown in the
>interface?
>
>Thanks!
>
>Belén
>
>
>>
>>
>>Thanks!
>>
>>
>>-- 
>>Amit Kumar Chaudhary
>>
>>
>>
>>On 24 February 2014 at 8:46:21 pm, Amit Kumar Chaudhary
>>(amit@floatingpondtech.com <mailto://amit@floatingpondtech.com>) wrote:
>>
>>Thanks Alex,
>>
>>
>>"The LogMessage table is designed to hold logs coming from the build
>>process itself²
>>
>>
>>This is the part I was trying to figure out. I have got the handle on how
>>to retrieve the messages from the table, (how those were put in there in
>>the first place is still a mystery),
>> I have added the following code to 'builddashboard(request, build_id)¹
>>function defined in toastergui/views.py
>>
>>
>>     context = {
>>             'build' : Build.objects.filter(pk=build_id)[0],
>>-            'recipecount' :
>>Recipe.objects.filter(layer_version__id__in=Layer_Version.objects.filter(
>>b
>>uild=build_id)).count()
>>+            'recipecount' :
>>Recipe.objects.filter(layer_version__id__in=Layer_Version.objects.filter(
>>b
>>uild=build_id)).count(),
>>+            'logmessages': LogMessage.objects.filter(build=build_id),
>>     }
>>     return render(request, template, context)
>>
>>
>>now I can use the logmessages in
>>toastergui/templates/builddashboard.html, using the html code I was
>>trying to re-use below. I have a patch that nearly works, I will clean
>>that up a bit and post it for giving a better picture.
>>
>>
>>Thanks for all the insights.
>>
>>
>>-- 
>>Amit Kumar Chaudhary
>>
>>
>>
>>On 20 February 2014 at 8:34:36 pm, Damian, Alexandru
>>(alexandru.damian@intel.com <mailto://alexandru.damian@intel.com>) wrote:
>>
>>Hello,
>>
>>
>>The LogMessage table is designed to hold logs coming from the build
>>process itself, and not logs that result from normal task execution.
>>It is the difference between the output displayed from the bitbake
>>command, and the output from the "make" command in a "do_compile" task.
>>
>>
>>For the latter case, we currently do not hold/save the content of such
>>log files. We do not have yet a strategy on determining what log files
>>are important, and saving everything may be
>> a prohibitive cost in terms of storage.
>>
>>
>>Hope this helps,
>>Alex
>>
>>
>>
>>On Thu, Feb 20, 2014 at 11:18 AM, Amit Kumar Chaudhary
>><amit@floatingpondtech.com> wrote:
>>
>>Hello, 
>>
>>
>>I am just beginning with the toaster and web apps in general, and I am
>>trying to add errors and warning listing to the build dashboard page, as
>>prototyped at
>>
>>
>>https://www.yoctoproject.org/toaster/build-dashboard-failed.html#errors
>>
>>
>>I am trying to re-use the following code --
>>
>>
>>
>><td>{{build.errors_no}}:{% if  build.errors_no %}{% for error in logs
>>%}{% if error.build == build %}{% if error.level == 2
>>%}<p>{{error.message}}</p>{% endif %}{% endif %}{% endfor %}{% else
>>%}None{% endif %}</td>
>>
>>
>>from 
>>~/poky-contrib/bitbake/lib/toaster/bldviewer/templates/simple_build.html.
>>
>>
>>And, I am expecting the logs, for example at
>>~/poky-contrib/build/tmp/log/cooker/qemux86/20140213120738.log
>>
>>
>>to be read via LogMessage class below
>>
>>
>>class LogMessage(models.Model):
>>    INFO = 0
>>    WARNING = 1
>>    ERROR = 2
>>
>>
>>    LOG_LEVEL = ( (INFO, "info"),
>>            (WARNING, "warn"),
>>            (ERROR, "error") )
>>
>>
>>    build = models.ForeignKey(Build)
>>    level = models.IntegerField(choices=LOG_LEVEL, default=INFO)
>>‹>    message=models.CharField(max_length=240)
>>    pathname = models.FilePathField(max_length=255, blank=True)
>>    lineno = models.IntegerField(null=True)
>>
>>
>>implemented in ~/poky-contrib/bitbake/lib/toaster/orm/models.py.
>>
>>
>>But, I can¹t seem to find the code that does it, reading from the log
>>file to the sqlite table. Could someone please point me to the files/path
>>that might contain this code, or such code for other tables.
>>
>>
>>Thanks!
>>
>>
>>
>>-- 
>>Amit Kumar Chaudhary
>>
>>
>>
>>
>>_______________________________________________
>>toaster mailing list
>>toaster@yoctoproject.org
>>https://lists.yoctoproject.org/listinfo/toaster
>>
>>
>>
>>
>>
>>
>>
>>
>>--
>>Alex Damian
>>Yocto Project
>>
>>SSG / OTC 
>>
>>
>>
>>
>>
>>
>>_______________________________________________
>>toaster mailing list
>>toaster@yoctoproject.org
>>https://lists.yoctoproject.org/listinfo/toaster
>>
>>
>>
>>
>
>_______________________________________________
>toaster mailing list
>toaster@yoctoproject.org
>https://lists.yoctoproject.org/listinfo/toaster


^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: Errors and Warnings listing on the dashboard page.
  2014-03-07 13:01     ` Amit Kumar Chaudhary
@ 2014-03-07 13:24       ` Barros Pena, Belen
  0 siblings, 0 replies; 13+ messages in thread
From: Barros Pena, Belen @ 2014-03-07 13:24 UTC (permalink / raw)
  To: Amit Kumar Chaudhary, toaster

Thanks for this, Amit. We have been trying to reproduce this problem:

https://bugzilla.yoctoproject.org/show_bug.cgi?id=5642

I'll ask QA to look into it.

Cheers

Belén

On 07/03/2014 13:01, "Amit Kumar Chaudhary" <amit@floatingpondtech.com>
wrote:

>
>Hi Belen, 
>
>
>I think the problem occurs whenever we use a database that may have
>different value stored for warnings_no in orm_build than the  actual no.
>of messages stored in orm_logmessage. I saw this problem while using this
>db from https://wiki.yoctoproject.org/wiki/File:Toaster.sqlite
>
>
>It has warnings_no=6 for id=7 in orm_build and only 2 messages with
>level=1 (level 1 = warning) for build_id=7 in orm_logmessage, which is
>consistent with what the webpage is showing,
> 6 warnings with only 2 actual messages under it.
>
>
>Thanks.
>
>
>-- 
>Amit Kumar Chaudhary
>
>
>
>On 3 March 2014 at 10:44:58 pm, Barros Pena, Belen
>(belen.barros.pena@intel.com) wrote:
>
>On 03/03/2014 15:26, "Amit Kumar Chaudhary" <amit@floatingpondtech.com>
>wrote: 
>
>>Investigating this right now. Also, is it possible you could send me the
>>log file using which you saw the errors and warnings number mismatch,
>>that will give me more cases to better make sense of the code and the
>>problem as well. (The log file I am talking about is
>>build/tmp/log/cooker/qemux86/20140213121357.log for me)
>
>Hi Amit, 
>
>I no longer have the log file, I am afraid. But looking into the data
>stored in the database for that build, it matches what you are showing. I
>cannot reproduce the problem with any of the other builds I have.
>
>Thanks for all the work.
>
>Belén 
>
>
>
>
>



^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: Errors and Warnings listing on the dashboard page.
       [not found]   ` <ALGVCmoAAWuHUxS5NQQjRHR7lXs>
@ 2014-03-07 13:01     ` Amit Kumar Chaudhary
  2014-03-07 13:24       ` Barros Pena, Belen
  0 siblings, 1 reply; 13+ messages in thread
From: Amit Kumar Chaudhary @ 2014-03-07 13:01 UTC (permalink / raw)
  To: toaster, Barros Pena, Belen

[-- Attachment #1: Type: text/plain, Size: 1374 bytes --]

Hi Belen, 

I think the problem occurs whenever we use a database that may have different value stored for warnings_no in orm_build than the  actual no. of messages stored in orm_logmessage. I saw this problem while using this db from https://wiki.yoctoproject.org/wiki/File:Toaster.sqlite

It has warnings_no=6 for id=7 in orm_build and only 2 messages with level=1 (level 1 = warning) for build_id=7 in orm_logmessage, which is consistent with what the webpage is showing, 6 warnings with only 2 actual messages under it.

Thanks.

-- 
Amit Kumar Chaudhary

On 3 March 2014 at 10:44:58 pm, Barros Pena, Belen (belen.barros.pena@intel.com) wrote:

On 03/03/2014 15:26, "Amit Kumar Chaudhary" <amit@floatingpondtech.com>  
wrote:  

>Investigating this right now. Also, is it possible you could send me the  
>log file using which you saw the errors and warnings number mismatch,  
>that will give me more cases to better make sense of the code and the  
>problem as well. (The log file I am talking about is  
>build/tmp/log/cooker/qemux86/20140213121357.log for me)  

Hi Amit,  

I no longer have the log file, I am afraid. But looking into the data  
stored in the database for that build, it matches what you are showing. I  
cannot reproduce the problem with any of the other builds I have.  

Thanks for all the work.  

Belén  


[-- Attachment #2: Type: text/html, Size: 3491 bytes --]

^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: Errors and Warnings listing on the dashboard page.
  2014-03-03 15:26 ` Amit Kumar Chaudhary
@ 2014-03-03 17:14   ` Barros Pena, Belen
       [not found]   ` <ALGVCmoAAWuHUxS5NQQjRHR7lXs>
  1 sibling, 0 replies; 13+ messages in thread
From: Barros Pena, Belen @ 2014-03-03 17:14 UTC (permalink / raw)
  To: Amit Kumar Chaudhary, toaster

On 03/03/2014 15:26, "Amit Kumar Chaudhary" <amit@floatingpondtech.com>
wrote:

>Investigating this right now. Also, is it possible you could send me the
>log file using which you saw the errors and warnings number mismatch,
>that will give me more cases to better make sense of the code and the
>problem as well. (The log file I am talking about is
>build/tmp/log/cooker/qemux86/20140213121357.log for me)

Hi Amit,

I no longer have the log file, I am afraid. But looking into the data
stored in the database for that build, it matches what you are showing. I
cannot reproduce the problem with any of the other builds I have.

Thanks for all the work.

Belén



^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: Errors and Warnings listing on the dashboard page.
       [not found] <ALCVCmoAAM3hUw82zAi9LHa0k0Q>
@ 2014-03-03 15:26 ` Amit Kumar Chaudhary
  2014-03-03 17:14   ` Barros Pena, Belen
       [not found]   ` <ALGVCmoAAWuHUxS5NQQjRHR7lXs>
  0 siblings, 2 replies; 13+ messages in thread
From: Amit Kumar Chaudhary @ 2014-03-03 15:26 UTC (permalink / raw)
  To: toaster, Barros Pena, Belen

[-- Attachment #1: Type: text/plain, Size: 7657 bytes --]

Hello Belen,

Pushed achaudhary/errors_warnings_ondashboard_v2

http://git.yoctoproject.org/cgit/cgit.cgi/poky-contrib/commit/?h=achaudhary/errors_warnings_ondashboard_v2&id=89f5fa173857d582d6631f3fc151dcabde9968f9

It fixes the first problem of zero errors being displayed, when no errors are present, thanks for the test data, that helped. 

If there are no warnings in a build, the build dashboard is showing a 
warnings section saying '0 warnings'. Instead, the warnings section should 
not exist when there are no warnings. 
Yes, this should be an easy fix. I should’ve noticed this on other prototype pages :), thanks for pointing this out.

Should not show zero warnings anymore.

>From an interface standpoint, this is looking pretty good. I am however 
>seeing some mismatch between the number of warnings and the number of 
>messages shown in the warnings section. It looks like the number of 
>warnings is displaying the overall number of entries in the orm_logmessage 
>table. 
> 
>The number of warnings should be the number of entries in the 
>orm_logmessage table with level = 1. The number of errors should be the 
>number of entries with level = 2. 
> 

>Any chance you could verify is this what's is being shown in the 
>interface? 
Yes, there is a problem, I will take a look.

This appears to be a problem rooted in the way the table is being read, I have one error in my log file that doesn’t get picked up.

ERROR: Nothing PROVIDES 'core-image-install'. Close matches:  

core-image-minimal

core-image-sato

core-image-rt

Could it be that certain type of errors are not supposed to be picked up? for example the one above occurs while the build is being launched (It is in the bitbake command parameter itself that launches the build). There is code as well that seems to be doing something about it, in lib/bb/ui/toastergui.py

            if isinstance(event, bb.event.NoProvider):
                return_value = 1
                errors = errors + 1
                if event._runtime:
                    r = "R"
                else:
                    r = “"
…

Investigating this right now. Also, is it possible you could send me the log file using which you saw the errors and warnings number mismatch, that will give me more cases to better make sense of the code and the problem as well. (The log file I am talking about is build/tmp/log/cooker/qemux86/20140213121357.log for me)

Thanks!

—amit

—amit


> 
>Thanks! 
> 
>Belén 
> 
> 
>> 
>> 
>>Thanks! 
>> 
>> 
>>-- 
>>Amit Kumar Chaudhary 
>> 
>> 
>> 
>>On 24 February 2014 at 8:46:21 pm, Amit Kumar Chaudhary 
>>(amit@floatingpondtech.com <mailto://amit@floatingpondtech.com>) wrote: 
>> 
>>Thanks Alex, 
>> 
>> 
>>"The LogMessage table is designed to hold logs coming from the build 
>>process itself² 
>> 
>> 
>>This is the part I was trying to figure out. I have got the handle on how 
>>to retrieve the messages from the table, (how those were put in there in 
>>the first place is still a mystery), 
>> I have added the following code to 'builddashboard(request, build_id)¹ 
>>function defined in toastergui/views.py 
>> 
>> 
>> context = { 
>> 'build' : Build.objects.filter(pk=build_id)[0], 
>>- 'recipecount' : 
>>Recipe.objects.filter(layer_version__id__in=Layer_Version.objects.filter( 
>>b 
>>uild=build_id)).count() 
>>+ 'recipecount' : 
>>Recipe.objects.filter(layer_version__id__in=Layer_Version.objects.filter( 
>>b 
>>uild=build_id)).count(), 
>>+ 'logmessages': LogMessage.objects.filter(build=build_id), 
>> } 
>> return render(request, template, context) 
>> 
>> 
>>now I can use the logmessages in 
>>toastergui/templates/builddashboard.html, using the html code I was 
>>trying to re-use below. I have a patch that nearly works, I will clean 
>>that up a bit and post it for giving a better picture. 
>> 
>> 
>>Thanks for all the insights. 
>> 
>> 
>>-- 
>>Amit Kumar Chaudhary 
>> 
>> 
>> 
>>On 20 February 2014 at 8:34:36 pm, Damian, Alexandru 
>>(alexandru.damian@intel.com <mailto://alexandru.damian@intel.com>) wrote: 
>> 
>>Hello, 
>> 
>> 
>>The LogMessage table is designed to hold logs coming from the build 
>>process itself, and not logs that result from normal task execution. 
>>It is the difference between the output displayed from the bitbake 
>>command, and the output from the "make" command in a "do_compile" task. 
>> 
>> 
>>For the latter case, we currently do not hold/save the content of such 
>>log files. We do not have yet a strategy on determining what log files 
>>are important, and saving everything may be 
>> a prohibitive cost in terms of storage. 
>> 
>> 
>>Hope this helps, 
>>Alex 
>> 
>> 
>> 
>>On Thu, Feb 20, 2014 at 11:18 AM, Amit Kumar Chaudhary 
>><amit@floatingpondtech.com> wrote: 
>> 
>>Hello, 
>> 
>> 
>>I am just beginning with the toaster and web apps in general, and I am 
>>trying to add errors and warning listing to the build dashboard page, as 
>>prototyped at 
>> 
>> 
>>https://www.yoctoproject.org/toaster/build-dashboard-failed.html#errors 
>> 
>> 
>>I am trying to re-use the following code -- 
>> 
>> 
>> 
>><td>{{build.errors_no}}:{% if build.errors_no %}{% for error in logs 
>>%}{% if error.build == build %}{% if error.level == 2 
>>%}<p>{{error.message}}</p>{% endif %}{% endif %}{% endfor %}{% else 
>>%}None{% endif %}</td> 
>> 
>> 
>>from 
>>~/poky-contrib/bitbake/lib/toaster/bldviewer/templates/simple_build.html. 
>> 
>> 
>>And, I am expecting the logs, for example at 
>>~/poky-contrib/build/tmp/log/cooker/qemux86/20140213120738.log 
>> 
>> 
>>to be read via LogMessage class below 
>> 
>> 
>>class LogMessage(models.Model): 
>> INFO = 0 
>> WARNING = 1 
>> ERROR = 2 
>> 
>> 
>> LOG_LEVEL = ( (INFO, "info"), 
>> (WARNING, "warn"), 
>> (ERROR, "error") ) 
>> 
>> 
>> build = models.ForeignKey(Build) 
>> level = models.IntegerField(choices=LOG_LEVEL, default=INFO) 
>>‹> message=models.CharField(max_length=240) 
>> pathname = models.FilePathField(max_length=255, blank=True) 
>> lineno = models.IntegerField(null=True) 
>> 
>> 
>>implemented in ~/poky-contrib/bitbake/lib/toaster/orm/models.py. 
>> 
>> 
>>But, I can¹t seem to find the code that does it, reading from the log 
>>file to the sqlite table. Could someone please point me to the files/path 
>>that might contain this code, or such code for other tables. 
>> 
>> 
>>Thanks! 
>> 
>> 
>> 
>>-- 
>>Amit Kumar Chaudhary 
>> 
>> 
>> 
>> 
>>_______________________________________________ 
>>toaster mailing list 
>>toaster@yoctoproject.org 
>>https://lists.yoctoproject.org/listinfo/toaster 
>> 
>> 
>> 
>> 
>> 
>> 
>> 
>> 
>>-- 
>>Alex Damian 
>>Yocto Project 
>> 
>>SSG / OTC 
>> 
>> 
>> 
>> 
>> 
>> 
>>_______________________________________________ 
>>toaster mailing list 
>>toaster@yoctoproject.org 
>>https://lists.yoctoproject.org/listinfo/toaster 
>> 
>> 
>> 
>> 
> 
>_______________________________________________ 
>toaster mailing list 
>toaster@yoctoproject.org 
>https://lists.yoctoproject.org/listinfo/toaster 

_______________________________________________ 
toaster mailing list 
toaster@yoctoproject.org 
https://lists.yoctoproject.org/listinfo/toaster 

[-- Attachment #2: Type: text/html, Size: 27716 bytes --]

^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: Errors and Warnings listing on the dashboard page.
@ 2014-02-27 12:59 Amit Kumar Chaudhary
  0 siblings, 0 replies; 13+ messages in thread
From: Amit Kumar Chaudhary @ 2014-02-27 12:59 UTC (permalink / raw)
  To: toaster, Barros Pena, Belen

[-- Attachment #1: Type: text/plain, Size: 6663 bytes --]

Thanks Belen,

Comments below, 
On 26 February 2014 at 7:29:05 pm, Barros Pena, Belen (belen.barros.pena@intel.com) wrote:


And of course I forgot something: sorry about that. 

If there are no warnings in a build, the build dashboard is showing a 
warnings section saying '0 warnings'. Instead, the warnings section should 
not exist when there are no warnings. 
Yes, this should be an easy fix. I should’ve noticed this on other prototype pages :), thanks for pointing this out.



Cheers 

Belén 

On 26/02/2014 13:52, "Barros Pena, Belen" <belen.barros.pena@intel.com> 
wrote: 

>On 26/02/2014 12:13, "Amit Kumar Chaudhary" <amit@floatingpondtech.com> 
>wrote: 
> 
>> 
>>Hello, 
>> 
>> 
>>This is the patch I had been working on, It is complete now and works as 
>>expected (as the prototype page), can you please review? 
>> 
>> 
>>http://git.yoctoproject.org/cgit/cgit.cgi/poky-contrib/commit/?h=achaudha 
>>r 
>>y/errors_warning_on_builddashboard&id=1aaada41ec2129bd9bc31cc591b75f6d9bc 
>>b 
>>7251 
> 
>Hi Amit, 
> 
>From an interface standpoint, this is looking pretty good. I am however 
>seeing some mismatch between the number of warnings and the number of 
>messages shown in the warnings section. It looks like the number of 
>warnings is displaying the overall number of entries in the orm_logmessage 
>table. 
> 
>The number of warnings should be the number of entries in the 
>orm_logmessage table with level = 1. The number of errors should be the 
>number of entries with level = 2. 
> 

>Any chance you could verify is this what's is being shown in the 
>interface? 
Yes, there is a problem, I will take a look.

—amit


> 
>Thanks! 
> 
>Belén 
> 
> 
>> 
>> 
>>Thanks! 
>> 
>> 
>>-- 
>>Amit Kumar Chaudhary 
>> 
>> 
>> 
>>On 24 February 2014 at 8:46:21 pm, Amit Kumar Chaudhary 
>>(amit@floatingpondtech.com <mailto://amit@floatingpondtech.com>) wrote: 
>> 
>>Thanks Alex, 
>> 
>> 
>>"The LogMessage table is designed to hold logs coming from the build 
>>process itself² 
>> 
>> 
>>This is the part I was trying to figure out. I have got the handle on how 
>>to retrieve the messages from the table, (how those were put in there in 
>>the first place is still a mystery), 
>> I have added the following code to 'builddashboard(request, build_id)¹ 
>>function defined in toastergui/views.py 
>> 
>> 
>> context = { 
>> 'build' : Build.objects.filter(pk=build_id)[0], 
>>- 'recipecount' : 
>>Recipe.objects.filter(layer_version__id__in=Layer_Version.objects.filter( 
>>b 
>>uild=build_id)).count() 
>>+ 'recipecount' : 
>>Recipe.objects.filter(layer_version__id__in=Layer_Version.objects.filter( 
>>b 
>>uild=build_id)).count(), 
>>+ 'logmessages': LogMessage.objects.filter(build=build_id), 
>> } 
>> return render(request, template, context) 
>> 
>> 
>>now I can use the logmessages in 
>>toastergui/templates/builddashboard.html, using the html code I was 
>>trying to re-use below. I have a patch that nearly works, I will clean 
>>that up a bit and post it for giving a better picture. 
>> 
>> 
>>Thanks for all the insights. 
>> 
>> 
>>-- 
>>Amit Kumar Chaudhary 
>> 
>> 
>> 
>>On 20 February 2014 at 8:34:36 pm, Damian, Alexandru 
>>(alexandru.damian@intel.com <mailto://alexandru.damian@intel.com>) wrote: 
>> 
>>Hello, 
>> 
>> 
>>The LogMessage table is designed to hold logs coming from the build 
>>process itself, and not logs that result from normal task execution. 
>>It is the difference between the output displayed from the bitbake 
>>command, and the output from the "make" command in a "do_compile" task. 
>> 
>> 
>>For the latter case, we currently do not hold/save the content of such 
>>log files. We do not have yet a strategy on determining what log files 
>>are important, and saving everything may be 
>> a prohibitive cost in terms of storage. 
>> 
>> 
>>Hope this helps, 
>>Alex 
>> 
>> 
>> 
>>On Thu, Feb 20, 2014 at 11:18 AM, Amit Kumar Chaudhary 
>><amit@floatingpondtech.com> wrote: 
>> 
>>Hello, 
>> 
>> 
>>I am just beginning with the toaster and web apps in general, and I am 
>>trying to add errors and warning listing to the build dashboard page, as 
>>prototyped at 
>> 
>> 
>>https://www.yoctoproject.org/toaster/build-dashboard-failed.html#errors 
>> 
>> 
>>I am trying to re-use the following code -- 
>> 
>> 
>> 
>><td>{{build.errors_no}}:{% if build.errors_no %}{% for error in logs 
>>%}{% if error.build == build %}{% if error.level == 2 
>>%}<p>{{error.message}}</p>{% endif %}{% endif %}{% endfor %}{% else 
>>%}None{% endif %}</td> 
>> 
>> 
>>from 
>>~/poky-contrib/bitbake/lib/toaster/bldviewer/templates/simple_build.html. 
>> 
>> 
>>And, I am expecting the logs, for example at 
>>~/poky-contrib/build/tmp/log/cooker/qemux86/20140213120738.log 
>> 
>> 
>>to be read via LogMessage class below 
>> 
>> 
>>class LogMessage(models.Model): 
>> INFO = 0 
>> WARNING = 1 
>> ERROR = 2 
>> 
>> 
>> LOG_LEVEL = ( (INFO, "info"), 
>> (WARNING, "warn"), 
>> (ERROR, "error") ) 
>> 
>> 
>> build = models.ForeignKey(Build) 
>> level = models.IntegerField(choices=LOG_LEVEL, default=INFO) 
>>‹> message=models.CharField(max_length=240) 
>> pathname = models.FilePathField(max_length=255, blank=True) 
>> lineno = models.IntegerField(null=True) 
>> 
>> 
>>implemented in ~/poky-contrib/bitbake/lib/toaster/orm/models.py. 
>> 
>> 
>>But, I can¹t seem to find the code that does it, reading from the log 
>>file to the sqlite table. Could someone please point me to the files/path 
>>that might contain this code, or such code for other tables. 
>> 
>> 
>>Thanks! 
>> 
>> 
>> 
>>-- 
>>Amit Kumar Chaudhary 
>> 
>> 
>> 
>> 
>>_______________________________________________ 
>>toaster mailing list 
>>toaster@yoctoproject.org 
>>https://lists.yoctoproject.org/listinfo/toaster 
>> 
>> 
>> 
>> 
>> 
>> 
>> 
>> 
>>-- 
>>Alex Damian 
>>Yocto Project 
>> 
>>SSG / OTC 
>> 
>> 
>> 
>> 
>> 
>> 
>>_______________________________________________ 
>>toaster mailing list 
>>toaster@yoctoproject.org 
>>https://lists.yoctoproject.org/listinfo/toaster 
>> 
>> 
>> 
>> 
> 
>_______________________________________________ 
>toaster mailing list 
>toaster@yoctoproject.org 
>https://lists.yoctoproject.org/listinfo/toaster 


[-- Attachment #2: Type: text/html, Size: 22836 bytes --]

^ permalink raw reply	[flat|nested] 13+ messages in thread

end of thread, other threads:[~2014-03-07 13:24 UTC | newest]

Thread overview: 13+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-02-20 11:18 Errors and Warnings listing on the dashboard page Amit Kumar Chaudhary
2014-02-20 15:04 ` Damian, Alexandru
     [not found] ` <AK2VCmoAADYfUwYZngQa1zNKOTA>
2014-02-24 15:16   ` Amit Kumar Chaudhary
     [not found]   ` <AK+VCmoAADfjUwtlVwOu4B9x834>
2014-02-26 12:13     ` Amit Kumar Chaudhary
2014-02-26 13:52       ` Barros Pena, Belen
2014-02-26 13:59         ` Barros Pena, Belen
2014-02-25 17:22 ` Reyna, David
     [not found] ` <AK+VCmoAAKVFUwzReQybVnuHOhU>
2014-02-26  6:54   ` Amit Kumar Chaudhary
2014-02-27 12:59 Amit Kumar Chaudhary
     [not found] <ALCVCmoAAM3hUw82zAi9LHa0k0Q>
2014-03-03 15:26 ` Amit Kumar Chaudhary
2014-03-03 17:14   ` Barros Pena, Belen
     [not found]   ` <ALGVCmoAAWuHUxS5NQQjRHR7lXs>
2014-03-07 13:01     ` Amit Kumar Chaudhary
2014-03-07 13:24       ` Barros Pena, Belen

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.