Skip to content
This repository has been archived by the owner on May 30, 2023. It is now read-only.

Feature: Control network timeout duration #11129

Closed
Tomtomgo opened this issue Mar 11, 2013 · 4 comments
Closed

Feature: Control network timeout duration #11129

Tomtomgo opened this issue Mar 11, 2013 · 4 comments
Milestone

Comments

@Tomtomgo
Copy link
Contributor

tom.aize...@gmail.com commented:

Which version of PhantomJS are you using? Tip: run 'phantomjs --version'.

1.9.0 (development)

What steps will reproduce the problem?

  1. Make a request with page.open to a non-responding server
  2. PhantomJS will wait forever

What is the expected output? What do you see instead?
I can only handle this by calling phantom.exit() via a setTimeout. It would be more logical to be able to set a timeout on the page.open call that aborts the request and optionally throw an error (via callback .onError).

Which operating system are you using?
Ubuntu 12.04

Did you use binary PhantomJS or did you compile it from source?
Compile from master tree

Please provide any additional information below.
On the discussion board J. Greene proposed I put a feature request here. The page: https://groups.google.com/forum/?fromgroups=#!topic/phantomjs/0OnJPkDAqSk.

Disclaimer:
This issue was migrated on 2013-03-15 from the project's former issue tracker on Google Code, Issue #1129.
🌟   3 people had starred this issue at the time of migration.

@JamesMGreene
Copy link
Collaborator

james.m....@gmail.com commented:

 

 
Metadata Updates

  • CC(s) added:
  • Status updated: Accepted
  • Title updated: Feature: Control network timeout duration

@JamesMGreene
Copy link
Collaborator

james.m....@gmail.com commented:

 

 
Metadata Updates

  • Label(s) removed:
    • Type-Defect
  • Label(s) added:
    • Type-Enhancement
    • Component-Logic
    • Module-WebPage
    • Domain-Qt

@vitallium
Copy link
Collaborator

vitaliy....@gmail.com commented:

Hi.

I saw your discussion on GitHub. I agree with you, this feature will be awesome.
Some ideas about implementing this feature:

  1. Control timeout for a page open request via options arguments in page.open
  2. [In future] I want to control the timeout for each network request

@Tomtomgo
Copy link
Contributor Author

tom.aize...@gmail.com commented:

I've issued a pull request here:

#414

ariya pushed a commit that referenced this issue Mar 20, 2013
@ariya ariya closed this as completed Mar 23, 2013
vitallium pushed a commit to vitallium/phantomjs that referenced this issue May 28, 2013
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants