File tree Expand file tree Collapse file tree 2 files changed +6
-1
lines changed Expand file tree Collapse file tree 2 files changed +6
-1
lines changed Original file line number Diff line number Diff line change @@ -7,7 +7,7 @@ high-level consumer and producer classes. Request batching is supported by the
7
7
protocol as well as broker-aware request routing. Gzip and Snappy compression
8
8
is also supported for message sets.
9
9
10
- Compatible with Apache Kafka 0.8.1
10
+ Compatible with Python 2.6+ and Apache Kafka 0.8.1
11
11
12
12
http://kafka.apache.org/
13
13
Original file line number Diff line number Diff line change 1
1
import os
2
2
import random
3
3
import struct
4
+ import sys
4
5
import unittest
5
6
6
7
from kafka .client import KafkaClient , ProduceRequest , FetchRequest
13
14
ITERATIONS = 1000
14
15
STRLEN = 100
15
16
17
+ # TODO remove this and fix unit tests
18
+ if sys .version_info < (2 ,7 ):
19
+ print ("Skipping unit tests for Python <2.7" )
20
+ exit (0 )
16
21
17
22
def random_string ():
18
23
return os .urandom (random .randint (1 , STRLEN ))
You can’t perform that action at this time.
0 commit comments