mike820324 / microProxy

A http/https interceptor written in pure python.
MIT License
17 stars 3 forks source link

Resolved #147: Add Server state and related API. #197

Closed mike820324 closed 7 years ago

mike820324 commented 7 years ago
mike820324 commented 7 years ago

@chhsiao90 Help me review thanks.

mike820324 commented 7 years ago

I will update unittest for server state later.

coveralls commented 7 years ago

Coverage Status

Coverage decreased (-0.3%) to 79.241% when pulling 69ccc04c22a09e4e795bb92a0264a7d102c87819 on server-state-#147 into 6ea6b13ebe586ea9268971d0f620ad6e6e5b3105 on master.

chhsiao90 commented 7 years ago

Great work! LGTM~

Had some suggestion about the global state of server_state. (Global state is hard to maintain!) How I think to remove the global state of server_state

And the layer_manager in ProxyServer I think we could remove self.layer_manager = layer_manager in __init__ method. Because layer_manager had changed from object to a module, it's not object anymore, so I think there is no need to assign it to ProxyServer as its field.

How do you think :)

coveralls commented 7 years ago

Coverage Status

Coverage decreased (-2.4%) to 77.06% when pulling 464a96000973502484782cfc71ec931aa7fff632 on server-state-#147 into 6ea6b13ebe586ea9268971d0f620ad6e6e5b3105 on master.

mike820324 commented 7 years ago

@chhsiao90 I have modified the code based on the previous review.

mike820324 commented 7 years ago

Thanks. You have used the new github feature. XD

chhsiao90 commented 7 years ago

Yeah, it's cool~ XD

chhsiao90 commented 7 years ago

There is no reject options, so sad...

coveralls commented 7 years ago

Coverage Status

Coverage increased (+0.4%) to 79.858% when pulling 6ee31163c05eee3f5cff8f1c2d8b1d3fbb3420d9 on server-state-#147 into 6ea6b13ebe586ea9268971d0f620ad6e6e5b3105 on master.

mike820324 commented 7 years ago

Don't reject me\ QAQ/