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 7399531
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 29, 20262026-05-29T04:04:20+00:00 2026-05-29T04:04:20+00:00

I am learning PyQT programing, and when I try a simple test, I get

  • 0

I am learning PyQT programing, and when I try a simple test, I get Segmentation fault, here is my code pop.py:

#! /usr/bin/python

import sys
from PyQt4.QtGui import QApplication
from PyQt4.QtCore import QUrl
from PyQt4.QtWebKit import QWebView

app = QApplication(sys.argv)
v = QWebView()
v.load(QUrl("http://127.0.0.1/j.html"))
v.show()
app.exec_()

I started an Apache server at 127.0.0.1 for testing. And here is j.html:

<html><script>alert("I am here");</script>
<body>Hello World</body>
</html>

I start the pop.py, open a window, javascript popup alert dialog, I click the OK, then pop.py will quite and get “Segmentation fault”

I tried PySide, get same result. If not JS alert in html, will be OK. Is this a bug of QT or I missed something?

I worked on Debian with python 2.6.6, python-qt4 4.8.3, libqtwebkit4 2.1.0

I also tried Fedora 15 with PyQt4-4.8.3, python 2.7.1, same issue

Any suggestion, clue for searching will be helpful. Thanks

  • 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-05-29T04:04:21+00:00Added an answer on May 29, 2026 at 4:04 am

    This works with the test case given above for

    Qt:     4.7.2
    PyQt:   4.8.3 or PySide 1.0.1
    Python: 2.7.1
    

    As noted above in the comments, http://developer.qt.nokia.com/forums/viewthread/4760 explains the bug and it is reported as fixed from https://bugs.webkit.org/show_bug.cgi?id=57414 and was probably included in Qt 4.7.2.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm writing a small app (learning Python and PyQt) that has an About box.
I am learning PyQt and wonder if one can create custom/owner draw control like
Learning from my last question , most member names seem to get included in
Learning to use Ruby Threads for transportability of code between different OS platforms. The
learning about loops (still a beginner) in VB.net. I have got the below code
learning html/css here. I can't seem to understand how to tweak this drop down
For learning purposes, I'm trying to make a function using Python that takes in
learning python, coming from a php background. Keeping it short. Is there a way
Learning client side code of an existing site, would like to understand some activity
I started learning a bit of python and would now like to toy around

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.