This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def create_engine(sql_connection, sqlite_fk=False, | |
mysql_traditional_mode=False): | |
return session.create_engine(sql_connection, | |
sqlite_fk, | |
mysql_traditional_mode, | |
idle_timeout=CONF.database.idle_timeout, | |
connection_debug=CONF.databse.connection_debug, | |
max_pool_size=CONF.database.max_pool_size, | |
max_overflow=CONF.database.max_overflow, | |
pool_timeout=CONF.database.pool_timeout, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
=> GET /v2/meter/instances/statistics?reset_on=metadata.vm_state | |
<= { | |
'off': [ { avg: ... max: ... start: '2013-07-01 00:00:00', end: '2013-07-01 00:59:59' }, | |
{ avg: ... max: ... start: '2013-07-01 03:00:00', end: '2013-07-01 03:59:59' }, | |
'on': [ { avg: ... max: ... start: '2013-07-01 01:00:00', end: '2013-07-01 01:59:59' } ], | |
'suspended': [ { avg: ... max: ... start: '2013-07-01 02:00:00', end: '2013-07-01 02:59:59' } ] | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
% git diff | |
diff --git a/ceilometer/storage/impl_mongodb.py b/ceilometer/storage/impl_mongodb.py | |
index 4580833..84bd8fc 100644 | |
--- a/ceilometer/storage/impl_mongodb.py | |
+++ b/ceilometer/storage/impl_mongodb.py | |
@@ -288,6 +288,8 @@ class Connection(base.Connection): | |
self.db.clear() | |
else: | |
self.conn.drop_database(self.db) | |
+ import time |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(if (if 1 2) 1) | |
Generates the tree | |
ast.stmt.If | |
`-> ast.stmt.If | |
`-> ast.expr.Num | |
`-> ast.expr.Num | |
`-> ast.expr.Num |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/hy/compiler.py b/hy/compiler.py | |
index 24ba107..22687ca 100644 | |
--- a/hy/compiler.py | |
+++ b/hy/compiler.py | |
@@ -157,6 +157,19 @@ class HyASTCompiler(object): | |
return self._mangle_branch([branch]) | |
@builds("if") | |
+ def wraps_if_expression(self, expr): | |
+ return ast.Expr( |
NewerOlder