-
Notifications
You must be signed in to change notification settings - Fork 121
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
App crashing after ping #46
Comments
I have the same issue often. |
I am also facing the same issue. |
Can you please reproduce the error or give me some details? How many devices they are in the network? subnet etc? |
Thank you for your response. My subnet is /24 and there are 10 devices on the network, but as far as I noticed, it doesn't depend on the number of devices. I have tried also in different networks with less devices and still after several scannings in a row, it will crash the app. I used also the commit that @jpalten did with all the changes to your code, and the application works somehow better, the crashes happen more rare but still, they happen. Here are some images of the crash. I would really appreciate if you have a look also to the @jpalten commit and after that to find some solutions for this crashing problem. My application really depends on this library. Thank you again for the response. |
Can you please create a project that reproduces this error? I will download it and I will try to find the issue. I did more than 20 scans in a row and the app is running fine. |
https://gitlab.com/elisgjana/lan-scan-test |
@elisgjana is exactly pointing the issues, which I also experience, out with the provided screenshots. It isn't reproducible by code changes, it just happens after intensive testing. The problem is that app users could experience this issue directly during the first usage, so they got directly a negative app experience. It would be really great if you can fix the issues anytime. |
@rpolenthon I understand the impact of the negative first usage but you need to understand that I was at your place 3 years ago (I wanted to use a network scanner library) and I created one instead and I was kind enough to open source it. So I would suggest that you and @elisgjana join me, and help me to find the issue instead of requesting to be fixed. My time is limited and this project it's just a hobby to me. So, since this bug is affecting you and @elisgjana, I would suggest starting digging in Apple's SimplePing. Something is going wrong in this class. You could try to replace it with any other Ping class (it won't be that hard). |
@mavris I don’t want do criticism about your work. I am really happy about that you shared your work with the world. I completely understand if you have not enough time to deep dive in again. By writing in the issues, my main afford was to show that the issue (still) exists. Yes it is bad, but I completely understand you. If I would have enough time to check out more deeply how the library works and why it may crashes, I would do so. But currently I am at my personal limit with the main app functionality. So if someone has time to fix it, it would be awesome, otherwise I will do it in Spring 2020 when I have a bigger gap for these improvements. Luckily the network scanner is just a tool in the app, so it is not the main use case. |
@mavris I am really thankful for publishing your work, not only for this library but also the others and I really understand that your time is limited, that's why I will do my best to help you in order to find a mutual solution. The only barrier for me is the lack of knowledge in Objective C that's why everything looked so abstract to me. For me this is a main feature for the application (smart home app) and this is why I am testing all the possible options. I tested the commit that @jpalten did and it fixes a lot of problems even-though the app still crashes (but not so often). I think by reviewing his commit would be a good headstart. Thanks again for your support. |
@elisgjana I used your project and I added a timer for a scan every 10 seconds. It ran 106 times without a crash. I understand that the bug is there. I will try to reproduce it on another network. |
@mavris I think I fixed one of the bugs by adding an "if condition" and checking if the socket is valid before stoping it: The scanning looks better now, but still crashes after some time in two different points: Can you please have a look when you have time and check what can we do to fix it. |
This might be related 🤷♂️ #53 |
When I start scanning the network, at some random time(not every time), the app crashes and I get this error. Can you please help me to fix it.
The text was updated successfully, but these errors were encountered: