Skip to content
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

Time-out errors #155

Closed
johan-de-jong opened this issue Jun 17, 2024 · 1 comment
Closed

Time-out errors #155

johan-de-jong opened this issue Jun 17, 2024 · 1 comment

Comments

@johan-de-jong
Copy link

johan-de-jong commented Jun 17, 2024

My logs are filling up with the errors show as below.

Log details (ERROR)

This error originated from a custom integration.
Logger: custom_components.hpprinter.managers.rest_api
Source: custom_components/hpprinter/managers/rest_api.py:452
integration: HP Printer (documentation, issues)
First occurred: June 16, 2024 at 9:42:43 PM (2452 occurrences)
Last logged: 11:15:16 AM

  • Failed to get /DevMgmt/ProductStatusDyn.xml, Error: , Line: 392, Time: 5.998s
  • Failed to get /ePrint/ePrintConfigDyn.xml, Error: , Line: 392, Time: 5.938s
  • Failed to get /ePrint/ePrintConfigDyn.xml, Error: , Line: 392, Time: 5.939s
  • Failed to get /ePrint/ePrintConfigDyn.xml, Error: , Line: 392, Time: 5.743s
  • Failed to get /ePrint/ePrintConfigDyn.xml, Error: , Line: 392, Time: 5.937s

It seems it takes my HP LaserJet Pro MFP M125nw a lot of time to respond to these GET requests:

When I try to request these URL's with curl it takes at least 10s before my HP LaserJet Pro MFP M125nw responds. E.g:

`$ time curl -s http://laserjet.fritz.box/ePrint/ePrintConfigDyn.xml

<ep:ePrintConfigDyn
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:dd="http://www.hp.com/schemas/imaging/con/dictionaries/1.0/"
xmlns:ep="http://www.hp.com/schemas/imaging/con/eprint/2010/04/30"
xsi:schemaLocation="http://www.hp.com/schemas/imaging/con/eprint/2010/04/30 ../../schemas/ePrintConfigDyn.xsd">
dd:Version
dd:Revision333</dd:Revision>
</dd:Version>
ep:DeviceConfiguration
dd:MakeAndModelHP LaserJet Pro MFP M125nw</dd:MakeAndModel>
dd:ProductNumberCZ173A</dd:ProductNumber>
dd:SerialNumberCNB7H7xxxx</dd:SerialNumber>
dd:CountryAndRegionNamenetherlandsThe</dd:CountryAndRegionName>
dd:Languagenl</dd:Language>
dd:FirmwareVersion
dd:Date2023-03-30</dd:Date>
</dd:FirmwareVersion>
</ep:DeviceConfiguration>
ep:AllowedServices
ep:OptInenabled</ep:OptIn>

ep:EmailServiceenabled</ep:EmailService>

</ep:AllowedServices>
ep:AllowedRemovableServices
ep:OptInenabled</ep:OptIn>
ep:EmailServiceenabled</ep:EmailService>

</ep:AllowedRemovableServices>
ep:RegistrationStateregistered</ep:RegistrationState>
ep:XMPPConnectionStateconnected</ep:XMPPConnectionState>
dd:DeviceWebServicesURI/SSI/Auth/set_config_webServices.htm</dd:DeviceWebServicesURI>
</ep:ePrintConfigDyn>

real 0m11.437s
user 0m0.017s
sys 0m0.000s`

image

image

image

Perhaps the timeout value could be increased to at least 25 seconds? The HP Printer integration seems to give up after about 5.9 seconds.

@elad-bar
Copy link
Owner

closing it as setting the timeout to 25 seconds, multiplied by means that for almost 2.5 minutes the component will try to update while the interval between updates is 5 minutes, seems like lots of IO,
if it takes ~6 seconds to load of less than 900 bytes, there is a network issue or a problem with the printer, try to understand which one of them is the issue,
if that is related to printer, i would contact HP support, as this is one of the pages being opened when you are working with the web console of it, meaning that the entire page will take lot of time and that's bad user experience

anyway, it is related to #129 if you would like to add more

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants