Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8638845
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 12, 20262026-06-12T10:50:39+00:00 2026-06-12T10:50:39+00:00

How can a QWebView be configured to lower network timeout values – so that

  • 0

How can a QWebView be configured to lower network timeout values – so that in the event of the network failure the loadFinished(bool ok) signal can be reached sooner, obviously, with a false value and an appropriate error condition set?

Bonus points for handling different timeouts differently

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-12T10:50:41+00:00Added an answer on June 12, 2026 at 10:50 am

    Standard errors and successful page loading will trigger loadFinished the same way as before, but a custom timer will stop the webpage loading and trigger loadFinished with ok=False

    class Browser(object):
    
        def __init__(self):
            self.web_view = QWebView()
            self.web_view.loadFinished.connect(self._load_finished)
    
            self._error = None
    
        def perform(self, url, timeout_value=30):
            request = QNetworkRequest()
            request.setUrl(QUrl(url))
    
            self.timeout_timer = QTimer()
            self.timeout_timer.timeout.connect(self._request_timed_out)
    
            self.timeout_timer.start(timeout_value * 1000)
            self.web_view.load(request)
    
        def _request_timed_out(self):
            self._error = 'Custom request timeout value exceeded.'
            self.timeout_timer.stop()
            self.web_view.stop()
            self.loadFinished.emit(False)
    
        def _load_finished(self, ok):
            pass
            # ok is now False, and self._error contains a custom error message
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

How can I issue a POST request over a QWebView instance?
I have a simple Qt application that launches a window with a QWebView. I
I have an application that requires to use QWebView::setContent() to load some HTML content
Can we change the color of the divider? Apple documentations says, that we can
Is it possible to access Flash's ExternalInterface from QWebView ? If so, how can
When a user scroll with his mouse within a QWebView widget , can i
Can somebody point me to a resource that explains how to go about having
My Qt application loads an external html page within a QWebView widget. How can
I got a QtWebKit.QWebView widget in a PyQt application window that I use to
Can anyone let me know how can we change the value of kendo combobox

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.