Opened 12 years ago

Closed 12 years ago

Last modified 12 years ago

#35793 closed defect (fixed)

webkit-gtk @1.8.2_2 +quartz +video "ImportError: No module named simplejson"

Reported by: sasoph@… Owned by: jeremyhu (Jeremy Huddleston Sequoia)
Priority: Normal Milestone:
Component: ports Version: 2.1.2
Keywords: Cc: dbevans (David B. Evans), cooljeanius (Eric Gallager)
Port: webkit-gtk

Description

10.5.8 PPC, Xcode 3.1.4

Traceback (most recent call last):
  File "./Source/WebCore/inspector/CodeGeneratorInspector.py", line 38, in <module>
    import simplejson as json
ImportError: No module named simplejson
make: *** [DerivedSources/WebCore/InspectorBackendDispatcher.cpp] Error 1

Attachments (2)

main.log (87.5 KB) - added by sasoph@… 12 years ago.
main.2.log (87.5 KB) - added by sasoph@… 12 years ago.
Patch applied

Download all attachments as: .zip

Change History (9)

Changed 12 years ago by sasoph@…

Attachment: main.log added

comment:1 Changed 12 years ago by ryandesign (Ryan Carsten Schmidt)

Owner: changed from macports-tickets@… to jeremyhu@…

comment:2 Changed 12 years ago by jeremyhu (Jeremy Huddleston Sequoia)

It is using simplejson if json fails to import:

try:
    import json
except ImportError:
    import simplejson as json

...

perhaps we need to force it to use /usr/bin/python when building...

comment:3 Changed 12 years ago by jeremyhu (Jeremy Huddleston Sequoia)

Status: newassigned

Please try this patch:

Index: Portfile
===================================================================
--- Portfile	(revision 96967)
+++ Portfile	(working copy)
@@ -52,6 +52,10 @@
         quartz.patch \
         bison-2.6.patch
 
+# https://trac.macports.org/ticket/35793
+configure.env-append \
+        PYTHON=/usr/bin/python
+
 configure.args	\
         --with-gtk=2.0 \
         --disable-introspection \

comment:4 Changed 12 years ago by sasoph@…

The patch gives the very same error.

How do I incant the json/simplejson import code block?

Does "port select python" have any bearing on the error?

Available versions for python:
	none (active)
	python25-apple
	python27
$ ls -l $(which python)
lrwxr-xr-x  1 root  wheel  72 Jan 17  2009 /usr/bin/python -> ../../System/Library/Frameworks/Python.framework/Versions/2.5/bin/python

Changed 12 years ago by sasoph@…

Attachment: main.2.log added

Patch applied

comment:5 Changed 12 years ago by jeremyhu (Jeremy Huddleston Sequoia)

Ah, I see... it's an issue with Leopard's python not having json. We'll need to build with MacPorts' python on Leopard.

comment:6 Changed 12 years ago by jeremyhu (Jeremy Huddleston Sequoia)

Resolution: fixed
Status: assignedclosed

comment:7 Changed 12 years ago by cooljeanius (Eric Gallager)

Cc: egall@… added

Cc Me!

Note: See TracTickets for help on using tickets.