Tanganelli / CoAPthon3

CoAPthon3 is a porting to python3 of my CoAPthon library. CoAPthon3 is a python3 library to the CoAP protocol compliant with the RFC. Branch is available for the Twisted framework.
MIT License
59 stars 50 forks source link

Response packet size can't be bigger than 1500 #45

Open Kevin0626 opened 2 years ago

Kevin0626 commented 2 years ago

I used the coapthon as the client to send GET request, the server side sent a package a little bigger than 1500. then only partial data available in the response.payload.

Any suggestions on how to solve it is appreciated.

zr4in commented 7 months ago

not sure if this is still helpful, maybe you could solve it by changing line 253 of coapthon/client/coap.py

michaelschefczyk commented 6 months ago

Thank you very much @zr4in! Please be so kind to indicate how I would do this, as I have no knowledge about pip. I have the file in /usr/local/lib/python3.11/dist-packages/coapthon/client/coap.py I can also edit the value from 1500 to 2000 - but that does not have an impact. Changing settings on the Philips device does work, however requesting the status does time out. Can I / do I need to install the changed py-file locally? Do I need to clone at github and modify there?

zr4in commented 6 months ago

@michaelschefczyk hi there. If there is only one place(not sure about this) in the original code resticts the package size to 1500(as we already know: coapthon/client/coap.py), then I think changing it to 2000 should work. I'm also new to this project. If having any progress I'll contact you.

zr4in commented 6 months ago

@michaelschefczyk Apologies, I mistook you for Kevin earlier. I'm not sure if the size of the package is the reason for your request timing out.