Skip to content

Commit 74eb33e

Browse files
madhupalulguohan
authored andcommitted
[configdb]: Fixed TypeErrorException when get_config with python3 sonic-net#44 (sonic-net#46)
1 parent cb4fec9 commit 74eb33e

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

src/swsssdk/configdb.py

+2
Original file line numberDiff line numberDiff line change
@@ -280,6 +280,8 @@ def get_config(self):
280280
keys = client.keys('*')
281281
data = {}
282282
for key in keys:
283+
if PY3K:
284+
key = key.decode('utf-8')
283285
try:
284286
(table_name, row) = key.split(self.TABLE_NAME_SEPARATOR, 1)
285287
entry = self.__raw_to_typed(client.hgetall(key))

0 commit comments

Comments
 (0)