public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
From: "André Erdmann" <dywi@mailerd.de>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] proj/R_overlay:master commit in: roverlay/db/
Date: Fri, 16 Aug 2013 14:26:17 +0000 (UTC)	[thread overview]
Message-ID: <1376663147.9a6828ffdf99b117a0c16b17f2b5ab04b2defe32.dywi@gentoo> (raw)

commit:     9a6828ffdf99b117a0c16b17f2b5ab04b2defe32
Author:     André Erdmann <dywi <AT> mailerd <DOT> de>
AuthorDate: Fri Aug 16 14:25:47 2013 +0000
Commit:     André Erdmann <dywi <AT> mailerd <DOT> de>
CommitDate: Fri Aug 16 14:25:47 2013 +0000
URL:        http://git.overlays.gentoo.org/gitweb/?p=proj/R_overlay.git;a=commit;h=9a6828ff

roverlay/db/rrdtool: read GAUGE as int by default

---
 roverlay/db/rrdtool.py | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/roverlay/db/rrdtool.py b/roverlay/db/rrdtool.py
index b326e7d..0e3e9b6 100644
--- a/roverlay/db/rrdtool.py
+++ b/roverlay/db/rrdtool.py
@@ -279,14 +279,14 @@ class RRD ( object ):
          self.clear()
    # --- end of commit (...) ---
 
-   def make_cache ( self, mask=-1, clear_cache=False ):
+   def make_cache ( self, mask=-1, clear_cache=False, gauge_type=int ):
       def convert_value ( str_value, value_type ):
          if str_value.lower() in self.KNOWN_UNKNOWN:
             return None
          else:
             try:
                if value_type == 'GAUGE':
-                  ret = float ( str_value )
+                  ret = gauge_type ( str_value )
                elif value_type in { 'COUNTER', 'DERIVE', 'ABSOLUTE' }:
                   ret = int ( str_value )
                else:


             reply	other threads:[~2013-08-16 14:26 UTC|newest]

Thread overview: 28+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-08-16 14:26 André Erdmann [this message]
  -- strict thread matches above, loose matches on Subject: below --
2016-07-07  4:19 [gentoo-commits] proj/R_overlay:master commit in: roverlay/db/ Benda XU
2014-07-16 15:14 André Erdmann
2013-09-05 14:43 André Erdmann
2013-09-05 14:43 André Erdmann
2013-09-05 14:43 André Erdmann
2013-09-05 10:24 André Erdmann
2013-09-05  9:25 André Erdmann
2013-09-05  9:25 André Erdmann
2013-09-05  9:25 André Erdmann
2013-09-03 15:37 André Erdmann
2013-09-03 13:15 André Erdmann
2013-09-03 12:21 André Erdmann
2013-09-03 12:21 André Erdmann
2013-09-02  8:44 André Erdmann
2013-08-30 15:25 André Erdmann
2013-08-30 15:23 André Erdmann
2013-08-30 14:49 André Erdmann
2013-08-30 14:49 André Erdmann
2013-08-22  9:01 André Erdmann
2013-08-16 12:42 André Erdmann
2013-08-15  9:18 André Erdmann
2013-08-14 14:56 André Erdmann
2013-08-14 14:56 André Erdmann
2013-08-13  8:56 André Erdmann
2013-07-30 18:40 André Erdmann
2013-07-10 15:10 [gentoo-commits] proj/R_overlay:gsoc13/next " André Erdmann
2013-07-10 16:16 ` [gentoo-commits] proj/R_overlay:master " André Erdmann
2013-06-22 15:14 [gentoo-commits] proj/R_overlay:gsoc13/next " André Erdmann
2013-06-22 15:24 ` [gentoo-commits] proj/R_overlay:master " André Erdmann

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1376663147.9a6828ffdf99b117a0c16b17f2b5ab04b2defe32.dywi@gentoo \
    --to=dywi@mailerd.de \
    --cc=gentoo-commits@lists.gentoo.org \
    --cc=gentoo-dev@lists.gentoo.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox