Strange mongo shell behavior on meteor.com: enter key is stuck? - meteor

I can connect successfully to my mongodb shell on meteor.com, but as soon as I get a prompt it is as if I hold down the enter key (which I do not...). The output below was produced by logging in and then pressin Ctrl-C after half a second. Any pointers?
mongodb://client:84a38acd-9ac1-e8dc-9ed8-f0cc43c23647#production-db-a1.meteor.io:27017/XXXXXXXXX_com
MongoDB shell version: 2.4.4
connecting to: production-db-a1.meteor.io:27017/XXXXXXXXXX_com
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
^CWed Jul 3 21:24:01.937 Assertion failure isABSONObj() src/mongo/db/../bson/bson-inl.h 183
0x1000ec22b 0x1000caadc 0x100083311 0x10000f2ca 0x100001755 0x7fff9321894a 0x101018210 0x1000e11fc 0x1000e1841 0x1000e1bd8 0x100044cfe 0x100044f4d 0x10006a9aa 0x1000427c0 0x10004e222 0x1000c4b87 0x1000af44d 0xab67c34c4db 0xab67c3485c2
0 mongo 0x00000001000ec22b _ZN5mongo15printStackTraceERSo + 43
1 mongo 0x00000001000caadc _ZN5mongo12verifyFailedEPKcS1_j + 284
2 mongo 0x0000000100083311 _ZNK5mongo11BSONElement14embeddedObjectEv + 193
3 mongo 0x000000010000f2ca _ZNK5mongo11shell_utils18ConnectionRegistry30killOperationsOnAllConnectionsEb + 524
4 mongo 0x0000000100001755 _Z10quitNicelyi + 85
5 libsystem_c.dylib 0x00007fff9321894a _sigtramp + 26
6 ??? 0x0000000101018210 0x0 + 4311843344
7 mongo 0x00000001000e11fc _ZN5mongo13MessagingPort4recvERNS_7MessageE + 112
8 mongo 0x00000001000e1841 _ZN5mongo13MessagingPort4recvERKNS_7MessageERS1_ + 33
9 mongo 0x00000001000e1bd8 _ZN5mongo13MessagingPort4callERNS_7MessageES2_ + 52
Wed Jul 3 21:24:01.941 terminate() called in shell, printing stack:

Related

Solaris: Equivalent command for chronyc sources and chronyc tracking

As per title I want to check output of the equivalent command but on a Solaris 11 box.
Is there a similar command?
In Solaris 11 you have standard ntp daemon so you can use command:
ntpq -p
to get the list of peers. And with this command you can see also some local time sync parameters:
root#sol1:/etc/inet# ntpq -p
remote refid st t when poll reach delay offset jitter
==============================================================================
+time.cloudflare 10.74.8.178 3 u 15 64 3 9.287 -241.90 210.255
*mail.eban-meban 147.125.80.35 3 u 36 64 1 4.415 -192.07 16.270
-purple.bonev.co 151.237.71.222 2 u 14 64 3 5.197 -242.41 219.576
+ntp.netguard.bg 20.39.126.15 2 u 47 64 3 4.570 -162.62 147.576

JavaFx Scenebuilder.exe won't start and it looks like the included JVM won't run. How can I fix it?

Scenebuilder.exe will not start on my new PC either from IntelliJ, Windows explorer, or command line. It gives no errors and terminates instantly. On a hunch I tried running the included JVM in
C:\Program Files\SceneBuilder\runtime\bin
java --version
I get the log below and it shows an access exception that looks like a bug in the underlying JVM itself, not in the execution of the SceneBuilder code. I've been running JDK 11 on this AMD Ryzen just fine, and there are no DLLs sneaking in that do not belong there. I need help, thanks!
C:\Program Files\SceneBuilder\runtime\bin>java --version
#
# A fatal error has been detected by the Java Runtime Environment:
#
# EXCEPTION_ACCESS_VIOLATION (0xc0000005) at pc=0x00007ff8e3bf8f29, pid=12296, tid=11532
#
# JRE version: (11.0.1+13) (build )
# Java VM: Java HotSpot(TM) 64-Bit Server VM (11.0.1+13-LTS, mixed mode, aot, sharing, tiered, compressed oops, g1 gc, windows-amd64)
# Problematic frame:
# V [jvm.dll+0x1e8f29]
#
# No core dump will be written. Minidumps are not enabled by default on client versions of Windows
#
# An error report file with more information is saved as:
# C:\Users\Tim\AppData\Local\Temp\\hs_err_pid12296.log
#
# If you would like to submit a bug report, please visit:
# http://bugreport.java.com/bugreport/crash.jsp
#
C:\Program Files\SceneBuilder\runtime\bin>type C:\Users\Tim\AppData\Local\Temp\\hs_err_pid12296.log
#
# A fatal error has been detected by the Java Runtime Environment:
#
# EXCEPTION_ACCESS_VIOLATION (0xc0000005) at pc=0x00007ff8e3bf8f29, pid=12296, tid=11532
#
# JRE version: (11.0.1+13) (build )
# Java VM: Java HotSpot(TM) 64-Bit Server VM (11.0.1+13-LTS, mixed mode, aot, sharing, tiered, compressed oops, g1 gc, windows-amd64)
# Problematic frame:
# V [jvm.dll+0x1e8f29]
#
# No core dump will be written. Minidumps are not enabled by default on client versions of Windows
#
# If you would like to submit a bug report, please visit:
# http://bugreport.java.com/bugreport/crash.jsp
#
--------------- S U M M A R Y ------------
Command Line:
Host: AMD Ryzen 5 2600 Six-Core Processor , 12 cores, 15G, Windows 10 , 64 bit Build 18362 (10.0.18362.778)
Time: Sat Apr 25 09:02:07 2020 Eastern Daylight Time elapsed time: 0 seconds (0d 0h 0m 0s)
--------------- T H R E A D ---------------
Current thread (0x000002312e8c6000): JavaThread "Unknown thread" [_thread_in_vm, id=11532, stack(0x0000005029100000,0x0000005029200000)]
Stack: [0x0000005029100000,0x0000005029200000], sp=0x00000050291feee0, free space=1019k
Native frames: (J=compiled Java code, j=interpreted, Vv=VM code, C=native code)
V [jvm.dll+0x1e8f29]
V [jvm.dll+0x1e73d3]
V [jvm.dll+0x37524b]
V [jvm.dll+0x7394a9]
V [jvm.dll+0x3e467d]
V [jvm.dll+0x3e6951]
C [java.exe+0x3603]
C [java.exe+0x178dc]
C [KERNEL32.DLL+0x17bd4]
C [ntdll.dll+0x6ce51]
siginfo: EXCEPTION_ACCESS_VIOLATION (0xc0000005), reading address 0x0000000000000000
Registers:
RAX=0x0000a780aacf8fcc, RBX=0x0000000000000000, RCX=0x0000000000000000, RDX=0x0000000000000006
RSP=0x00000050291feee0, RBP=0x0000000000000000, RSI=0x000002312e8c6000, RDI=0x0000000000000000
R8 =0x0000000000000006, R9 =0x0000000000000006, R10=0x0000000000000006, R11=0x00000050291fe750
R12=0x0000000000000000, R13=0x00007ff8e3ff6d90, R14=0x000002312c602d98, R15=0x00000050291ff938
RIP=0x00007ff8e3bf8f29, EFLAGS=0x0000000000010256
Top of Stack: (sp=0x00000050291feee0)
0x00000050291feee0: 000002312c60db10 00007ff94e71c6c0
0x00000050291feef0: 00000050291ff938 000002312c602d98
0x00000050291fef00: 0000000000000000 0000000000000400
0x00000050291fef10: 00006181910f784b 00007ff8e3ff6d90
0x00000050291fef20: 0000000000000000 00000050291ff938
0x00000050291fef30: 000002312c602d98 00007ff8e3ff6d90
0x00000050291fef40: 0000000000000000 00007ff92e470000
0x00000050291fef50: 00007ff8e4282558 0000000000000000
0x00000050291fef60: 00007ff8e3bf7277 00007ff94e6d1b1c
0x00000050291fef70: 0000000000000000 00007ff8e40745dd
0x00000050291fef80: 0000a780aacf8fcc 000002312c602d98
0x00000050291fef90: 00007ff800000000 00007ff8e3ff6d90
0x00000050291fefa0: 000002312e8c6000 00000050291ff0c0
0x00000050291fefb0: 0000000000000000 00007ff8e3bf73d3
0x00000050291fefc0: 00007ff92e450000 00007ff92e47d088
0x00000050291fefd0: 00000050291ff0c0 000002312e8c6000
Instructions: (pc=0x00007ff8e3bf8f29)
0x00007ff8e3bf8f09: b8 00 00 00 48 8b 05 bc 40 85 00 48 33 c4 48 89
0x00007ff8e3bf8f19: 84 24 a0 00 00 00 48 8b e9 48 83 cb ff 48 ff c3
0x00007ff8e3bf8f29: 80 3c 0b 00 75 f7 33 f6 c6 44 24 30 01 40 38 35
0x00007ff8e3bf8f39: c2 62 88 00 74 17 40 38 35 a3 c9 87 00 75 0e 33
--------------- P R O C E S S ---------------
Threads class SMR info:
_java_thread_list=0x000002312c602d50, length=0, elements={
}
Java Threads: ( => current thread )
Other Threads:
[error occurred during error reporting (printing all threads), id 0xc0000005, EXCEPTION_ACCESS_VIOLATION (0xc0000005) at pc=0x00007ff8e414e1fd]
VM state:not at safepoint (not fully initialized)
VM Mutex/Monitor currently owned by a thread: None
[error occurred during error reporting (printing compressed oops mode), id 0xc0000005, EXCEPTION_ACCESS_VIOLATION (0xc0000005) at pc=0x00007ff8e4163b67]
Deoptimization events (0 events):
No events
Classes redefined (0 events):
No events
Internal exceptions (0 events):
No events
Events (0 events):
No events
Dynamic libraries:
0x00007ff6af5a0000 - 0x00007ff6af5e7000 C:\Program Files\SceneBuilder\runtime\bin\java.exe
0x00007ff9512e0000 - 0x00007ff9514d0000 C:\WINDOWS\SYSTEM32\ntdll.dll
0x00007ff950230000 - 0x00007ff9502e2000 C:\WINDOWS\System32\KERNEL32.DLL
0x00007ff94e6c0000 - 0x00007ff94e963000 C:\WINDOWS\System32\KERNELBASE.dll
0x00007ff94fb00000 - 0x00007ff94fba3000 C:\WINDOWS\System32\ADVAPI32.dll
0x00007ff9502f0000 - 0x00007ff95038e000 C:\WINDOWS\System32\msvcrt.dll
0x00007ff951200000 - 0x00007ff951297000 C:\WINDOWS\System32\sechost.dll
0x00007ff94f9e0000 - 0x00007ff94fb00000 C:\WINDOWS\System32\RPCRT4.dll
0x00007ff94f390000 - 0x00007ff94f524000 C:\WINDOWS\System32\USER32.dll
0x00007ff94f2e0000 - 0x00007ff94f301000 C:\WINDOWS\System32\win32u.dll
0x00007ff94f530000 - 0x00007ff94f556000 C:\WINDOWS\System32\GDI32.dll
0x00007ff94e520000 - 0x00007ff94e6b4000 C:\WINDOWS\System32\gdi32full.dll
0x00007ff94f240000 - 0x00007ff94f2de000 C:\WINDOWS\System32\msvcp_win.dll
0x00007ff94e270000 - 0x00007ff94e36a000 C:\WINDOWS\System32\ucrtbase.dll
0x00007ff942260000 - 0x00007ff9424e5000 C:\WINDOWS\WinSxS\amd64_microsoft.windows.common-controls_6595b64144ccf1df_6.0.18362.778_none_e6c6b761130d4fb8\COMCTL32.dll
0x00007ff947e60000 - 0x00007ff947e6a000 C:\WINDOWS\SYSTEM32\VERSION.dll
0x00007ff94f640000 - 0x00007ff94f976000 C:\WINDOWS\System32\combase.dll
0x00007ff94e370000 - 0x00007ff94e3f0000 C:\WINDOWS\System32\bcryptPrimitives.dll
0x00007ff950df0000 - 0x00007ff950e1e000 C:\WINDOWS\System32\IMM32.DLL
0x00007ff94aa90000 - 0x00007ff94aaa6000 C:\Program Files\SceneBuilder\runtime\bin\vcruntime140.dll
0x00007ff932a30000 - 0x00007ff932ada000 C:\Program Files\SceneBuilder\runtime\bin\msvcp140.dll
0x00007ff8e3a10000 - 0x00007ff8e4552000 C:\Program Files\SceneBuilder\runtime\bin\server\jvm.dll
0x00007ff950220000 - 0x00007ff950228000 C:\WINDOWS\System32\PSAPI.DLL
0x00007ff94ae30000 - 0x00007ff94ae54000 C:\WINDOWS\SYSTEM32\WINMM.dll
0x00007ff93c080000 - 0x00007ff93c089000 C:\WINDOWS\SYSTEM32\WSOCK32.dll
0x00007ff950d80000 - 0x00007ff950def000 C:\WINDOWS\System32\WS2_32.dll
0x00007ff94ae00000 - 0x00007ff94ae2d000 C:\WINDOWS\SYSTEM32\WINMMBASE.dll
0x00007ff94e4d0000 - 0x00007ff94e51a000 C:\WINDOWS\System32\cfgmgr32.dll
0x00007ff94e250000 - 0x00007ff94e261000 C:\WINDOWS\System32\kernel.appcore.dll
0x00007ff94a980000 - 0x00007ff94a991000 C:\Program Files\SceneBuilder\runtime\bin\verify.dll
0x00007ff93d1a0000 - 0x00007ff93d394000 C:\WINDOWS\SYSTEM32\DBGHELP.DLL
0x00007ff93cf30000 - 0x00007ff93cf5a000 C:\WINDOWS\SYSTEM32\dbgcore.DLL
0x00007ff92e470000 - 0x00007ff92e499000 C:\Program Files\SceneBuilder\runtime\bin\java.dll
0x00007ff92e450000 - 0x00007ff92e466000 C:\Program Files\SceneBuilder\runtime\bin\zip.dll
0x00007ff94aa80000 - 0x00007ff94aa8a000 C:\Program Files\SceneBuilder\runtime\bin\jimage.dll
dbghelp: loaded successfully - version: 4.0.5 - missing functions: none
symbol engine: initialized successfully - sym options: 0x614 - pdb path: .;C:\Program Files\SceneBuilder\runtime\bin;C:\WINDOWS\SYSTEM32;C:\WINDOWS\WinSxS\amd64_microsoft.windows.common-controls_6595b64144ccf1df_6.0.18362.778_none_e6c6b761130d4fb8;C:\Program Files\SceneBuilder\runtime\bin\server
VM Arguments:
java_command: <unknown>
java_class_path (initial): <not set>
Launcher Type: SUN_STANDARD
[Global flags]
uint G1ConcRefinementThreads = 10 {product} {ergonomic}
uintx GCDrainStackTargetSize = 64 {product} {ergonomic}
size_t InitialHeapSize = 267632960 {product} {ergonomic}
size_t MaxHeapSize = 4282127360 {product} {ergonomic}
uintx ReservedCodeCacheSize = 251658240 {pd product} {ergonomic}
bool SegmentedCodeCache = true {product} {ergonomic}
bool UseCompressedClassPointers = true {lp64_product} {ergonomic}
bool UseCompressedOops = true {lp64_product} {ergonomic}
bool UseG1GC = true {product} {ergonomic}
bool UseLargePagesIndividualAllocation = false {pd product} {ergonomic}
Logging:
Log output configuration:
#0: stdout all=warning uptime,level,tags
#1: stderr all=off uptime,level,tags
Environment Variables:
JAVA_HOME=C:\Users\Tim\jdk-13.0.2
PATH=...
USERNAME=Tim
OS=Windows_NT
PROCESSOR_IDENTIFIER=AMD64 Family 23 Model 8 Stepping 2, AuthenticAMD
--------------- S Y S T E M ---------------
OS: Windows 10 , 64 bit Build 18362 (10.0.18362.778)
CPU:total 12 (initial active 12)
Memory: 4k page, system-wide physical 16335M (7401M free)
TotalPageFile size 38863M (AvailPageFile size 26823M)
current process WorkingSet (physical memory assigned to process): 8M, peak: 8M
current process commit charge ("private bytes"): 3M, peak: 3M
vm_info: Java HotSpot(TM) 64-Bit Server VM (11.0.1+13-LTS) for windows-amd64 JRE (11.0.1+13-LTS), built on Oct 6 2018 13:20:16 by "mach5one" with MS VC++ 15.5 (VS2017)
END.

Execution halted error in R

I run hicpipe tools and it returns this error during execution. Its error was:
Rsge temp files: tmp/Rsge.test_cluster.binned.*
Error in if (trace) cat("Running locally \n") :
argument is of length zero
Calls: compute.total.counts -> model.predict.split -> sge.parRapply
Execution halted
Error: error in total_expected_counts_wrapper.r
Execution halted
make[1]: *** [/home/dashti/hicpipe/output/test_cluster/test_cluster.nm]
Error 1
make[1]: Leaving directory `/home/dashti/hicpipe'
make: *** [all] Error 1
It was run a Rscript code in below:
Rscript R/total_expected_counts_wrapper.r /home/dashti/hicpipe/output/test_cluster/test_cluster /home/dashti/hicpipe/models/map_len_gc.mdl trans 1e+06 0 200
Code of total_expected_counts_wrapper.r is :
options(warn=1)
# get script name
all.args = commandArgs(F)
fn.arg = "--file="
script.name = sub(fn.arg, "", all.args[grep(fn.arg, all.args)])
args = commandArgs(T)
if (length(args) == 1) {
cat(sprintf("usage: %s <input prefix> <model file> <filter> <cis.threshold> <use cluster> <max jobs on cluster>\n",
script.name))
q(status=1)
}
ifn.prefix = args[1]
model.ifn = args[2]
filter = args[3]
cis.threshold = as.numeric(args[4])
cluster = (args[5] == "1")
max.njobs = as.numeric(args[6])
mtable = read.delim(model.ifn)
mfields = mtable$field
maxvals = mtable$size
if (cluster) {
cat("Using Sun Grid Engine cluster\n")
} else {
cat("Not using Sun Grid Engine cluster, running sequentially on local machine\n")
}
source("R/model_predict.r")
compute.total.counts(prefix=ifn.prefix, cluster=cluster, max.njobs=max.njobs, ofields=mfields, max.vals=maxvals, filter=filter, cis.threshold=cis.threshold)
q(status=0)
What should I do? I see other .R files but I cannot find any trace variable in them. I send an E-mail to authors but I do not receive any response.
source("R/model_predict.r")
In model_predict.r, Rsge library is loaded
173 library(Rsge)
174 sge.options(sge.save.global=F)
175 sge.prefix = paste("tmp/Rsge.", get.short.fn(fends.fn), ".", sep="")
176 cat(sprintf("Rsge temp files: %s*\n", sge.prefix))
177 sge.options(sge.file.prefix=sge.prefix)
178
179 result = sge.parRapply(ranges, model.predict, lib.dir=lib.dir,
180 njobs=njobs, join.method=c, cluster=cluster,
181 fends.fn=fends.fn, log.dir=log.dir,
182 prior=prior, mfields=mfields, mfields.maxvals=mfields.maxvals, mfields.fns=mfields.fns,
183 filter=filter, cis.threshold=cis.threshold, ofields.x=ofields.x, ofields.y=ofields.y,
184 function.savelist=c("get.short.fn", "get.ofield.args"))
185 if (class(result) == "list" && class(result[[1]]) == "try-error")
186 return (-1)
and it seems that Rsge does not work properly.
I workarounded by editing Rsge/sge.parApply.R code
(set value of variables equal to Rsge/sge.optionR)
and reinstalling Rsge.
1
2 # $Id: sge.parRapply.R,v 1.2 2006/12/15 15:21:23 kuhna03 Exp $
3
4 sge.apply <- function(X, MARGIN, FUN, ...,
5 join.method=cbind,
6 njobs,
7 batch.size=options('sge.block.size'),
8 packages=NULL,
9 global.savelist=NULL,
10 function.savelist=NULL,
11 cluster=options('sge.use.cluster'),
12 #trace=options('sge.trace'),
13 trace=TRUE,
14 #debug=options('sge.debug'),
15 debug=FALSE,
16 file.prefix=options('sge.file.prefix')
17 ) {

How can i make a python file run another which is not in same directory?

This is my code...I have tried many solutions given on stackoverflow but i am not able to run another python file which is not in same directory
f.py
import os
print "Start..."
file='"C:\Users\Mohit\Desktop\ML PROJECT\Practical Session on R\Practical
Session on R\Session II - Regression\run.py"'
os.system('python file ')
print "Done"
Output:
Fatal error: cannot open file 'file': No such file or directory
run.py
import os
print "Start..."
files=r'"C:\Users\Mohit\Desktop\ML PROJECT\Practical Session on R\Practical
Session on R\Session II - Regression\decisionTree.R"'
os.system('Rscript '+files)
print "Done"
I get the desired result when i run run.py.
Output:
C:\Users\Mohit\Desktop\ML PROJECT\Practical Session on R\Practical Session
on R\
Session II - Regression>python r.py
Start...
START
elapsed
0.17
Step 1: Library Inclusion
Step 2: Variable Declaration[1]
[1] "regressionDataSet.csv"
Step 3: Data Loading RMSD
irNumber
14395 1.167 5364.27 4616.64
15435 2.500 25468.10 475274.00 -
8739 4.039 5921.03 7071.89
11586 0.000 14192.70 75413.00
13765 0.000 17432.40 245147.00 -
10087 3.814 7333.51 26580.70
[1] 16382
[1] "RMSD" "Area"
[5] "SS" "ResidueLeng
Step 4: Counting dataset[1] 1638
Step 5: Choose Target Variable[1
Step 6: Choose Inputs Variable[1
"SS"
[5] "ResidueLength" "PairNumber"
[1] 6
Step 7: Select training dataset
th PairNumber RMSD
14395 5364.27 4616.64 -696.
15435 25468.10 475274.00 -10600.
8739 5921.03 7071.89 -1658.
11586 14192.70 75413.00 -7939.
13765 17432.40 245147.00 -10885.
10087 7333.51 26580.70 -2746.
[1] 8191
Step 8: Select testing dataset
PairNumber RMSD
10216 20510.40 254178.0 44500.0
2385 9981.42 28499.0 -4789.0
1886 21107.10 192443.0 -4860.0
13684 17765.00 76543.0 -8164.0
10319 6308.91 10287.3 -3370.0
13088 5844.34 11139.7 -1879.7
[1] 8192
Step 9: Model Building -> decis
ength + PairNumber
n= 8191
node), split, n, deviance, yval
* denotes terminal node
1) root 8191 23819.88000 2.364
2) Energy< -6161.885 1592 4
4) ResidueLength< 387.5 74
8) Energy< -7785.3 262
9) Energy>=-7785.3 481
5) ResidueLength>=387.5 84
10) Energy< -12910.5 173
11) Energy>=-12910.5 676
22) ResidueLength< 467.
44) ResidueLength>=39
45) ResidueLength< 39
23) ResidueLength>=467.
3) Energy>=-6161.885 6599 17
6) SS< 21.5 1584 3795.813
7) SS>=21.5 5015 13126.850
14) Energy< -3971.125 163
28) ResidueLength< 192.
29) ResidueLength>=192.
58) ResidueLength< 26
116) Energy< -4680.5
117) Energy>=-4680.5
59) ResidueLength>=26
15) Energy>=-3971.125 337
30) Area< 8601.98 1655
60) Energy< -2933.36
61) Energy>=-2933.36
31) Area>=8601.98 1721
Step 10: Prediction using -> de
13684 10319 13088
3.24618361 0.51722167 3.10727318
Step 11: Extracting Actual[1] 3.
Step 12: Model Evaluation[1] 0.5
[1] 0.25
[1] 1.19
[1] 48.19
elapsed
0.53
null device
1
modelName r R rm
elapsed decisionTree 0.5 0.25 1.
Step 13: Writing to file
Step 14: Saving the Model -> dec
Done
Total Time Taken: 0.53 secDone
But i get the following error when i run it through f.py
Error:
Start...
Start...
START
elapsed
0.18
Step 1: Library Inclusion
Step 2: Variable Declaration[1] "decisionTree"
[1] "regressionDataSet.csv"
Step 3: Data LoadingError in file(file, "rt") : cannot open the connec
Calls: read.csv -> read.table -> file
In addition: Warning message:
In file(file, "rt") :
cannot open file 'regressionDataSet.csv': No such file or directory
Put an r in front of your file path, so that the backslashes \ don't escape strings where you don't want them to be escaped (see also this question).
Secondly os.system('python file') will literally execute python file, your variable isn't being used.
Also make sure there's no linebreak your file path (just one long line).
import os
print "Start..."
folder = r'C:\Users\Mohit\Desktop\ML PROJECT\Practical Session on R\Practical Session on R\Session II - Regression'
file= r'"{}\run.py"'.format(folder)
os.chdir(folder)
os.system('python '+file)
print "Done"

Compiling PyQt5 App with QtWebEngine

I've been trying to compile an app that uses the QtWebEngine from PyQt5. The app works as intended but it fails when compiling. I've spent a couple of days looking for solution but so far I had no luck. I've installed python from both brew and downloading the package form it's website. I've also installed PyQt5 form brew and pip3 without any luck. After running the pyinstaller script I get the "cannot find QtWebEngineProcess" error. That's fixed by copying the QtWebEngineProcess.app file into the MacOS folder. Subsequentially I made sure that the info.plist file is not a symlink but the actual file. Afterwards I added the "org.qt-project.Qt.QtWebEngineCore" flag to the "CFBundleIdentifier" in the main app info.plist. This resolves the problem of not finding "QtWebEngineProcess" but it brings now the error stated below. I copied the "icudtl.dat" to the MacOS folder as well. I also tried rebuilding the dependencies with the framework itself and making sure I don't have symlinks like stated here. I'm not familiar with the install_name_tool so I'm stuck there. Any ideas? Is anyone able to compile a pyqt app using QtWebEngine at all?
Here's the error I'm facing:
[0201/130544:ERROR:icu_util.cc(162)] Invalid file descriptor to ICU data received.
[0201/130544:FATAL:content_main_runner.cc(714)] Check failed: base::i18n::InitializeICU().
0 QtWebEngineCore 0x000000010d4b62e3 _ZN15QtWebEngineCore20FilePickerController11qt_metacallEN11QMetaObject4CallEiPPv + 12132083
1 QtWebEngineCore 0x000000010d4c9809 _ZN15QtWebEngineCore20FilePickerController11qt_metacallEN11QMetaObject4CallEiPPv + 12211225
2 QtWebEngineCore 0x000000010ce7cb03 _ZN15QtWebEngineCore20FilePickerController11qt_metacallEN11QMetaObject4CallEiPPv + 5605139
3 QtWebEngineCore 0x000000010c918ee4 _ZN15QtWebEngineCore18WebContentsAdapter14faviconManagerEv + 28052
4 QtWebEngineCore 0x000000010c917f48 _ZN15QtWebEngineCore18WebContentsAdapter14faviconManagerEv + 24056
5 QtWebEngineCore 0x000000010c90e3b9 _ZN15QtWebEngineCore18WebContentsAdapterC2EPN7content11WebContentsE + 57
6 QtWebEngineWidgets 0x000000011113ce4e _ZrsR11QDataStreamR17QWebEngineHistory + 1870
7 QtWebEngineWidgets 0x000000011113ec20 _ZN14QWebEnginePageC1EP7QObject + 48
8 QtWebEngineWidgets 0x000000011114ad17 _ZN14QWebEngineView6setUrlERK4QUrl + 55
9 PyQt5.QtWebEngineWidgets.so 0x0000000111100ca3 _ZL26meth_QWebEngineView_setUrlP7_objectS0_ + 99
10 Python 0x00000001080faae9 PyCFunction_Call + 233
11 Python 0x0000000108187a81 PyEval_EvalFrameEx + 35729
12 Python 0x00000001081884fc PyEval_EvalFrameEx + 38412
13 Python 0x0000000108188e90 _PyEval_EvalCodeWithName + 2400
14 Python 0x0000000108188f97 PyEval_EvalCodeEx + 71
15 Python 0x00000001080d577a function_call + 186
16 Python 0x00000001080a28d3 PyObject_Call + 99
17 Python 0x00000001080bd9cc method_call + 140
18 Python 0x00000001080a28d3 PyObject_Call + 99
19 Python 0x00000001081184c1 slot_tp_init + 81
20 Python 0x000000010810ef44 type_call + 212
21 Python 0x00000001080a28d3 PyObject_Call + 99
22 Python 0x0000000108182b65 PyEval_EvalFrameEx + 15477
23 Python 0x0000000108188e90 _PyEval_EvalCodeWithName + 2400
24 Python
0x0000000108188ff1 PyEval_EvalCode + 81
25 Sailor 0x0000000106e52490 Sailor + 9360
26 Sailor 0x0000000106e529f9 Sailor + 10745
27 Sailor 0x0000000106e51464 Sailor + 5220
28 ??? 0x0000000000000003 0x0 + 3
Trace/BPT trap: 5
It worked for me after using this branch and adding some custom patching:
def patch_osx_app():
"""Patch .app to copy missing data and link some libs.
See https://github.com/pyinstaller/pyinstaller/issues/2276
"""
app_path = os.path.join('dist', 'qutebrowser.app')
qtwe_core_dir = os.path.join('.tox', 'pyinstaller', 'lib', 'python3.6',
'site-packages', 'PyQt5', 'Qt', 'lib',
'QtWebengineCore.framework')
# Copy QtWebEngineProcess.app
proc_app = 'QtWebEngineProcess.app'
shutil.copytree(os.path.join(qtwe_core_dir, 'Helpers', proc_app),
os.path.join(app_path, 'Contents', 'MacOS', proc_app))
# Copy resources
for f in glob.glob(os.path.join(qtwe_core_dir, 'Resources', '*')):
dest = os.path.join(app_path, 'Contents', 'Resources')
if os.path.isdir(f):
shutil.copytree(f, os.path.join(dest, f))
else:
shutil.copy(f, dest)
# Link dependencies
for lib in ['QtCore', 'QtWebEngineCore', 'QtQuick', 'QtQml', 'QtNetwork',
'QtGui', 'QtWebChannel', 'QtPositioning']:
dest = os.path.join(app_path, lib + '.framework', 'Versions', '5')
os.makedirs(dest)
os.symlink(os.path.join(os.pardir, os.pardir, os.pardir, 'Contents',
'MacOS', lib),
os.path.join(dest, lib))
It`s some problem with the QtWebEngine. I believed that exists patch to fix this bug.
You can see other informations in https://github.com/pyinstaller/pyinstaller/issues/2566
The files:
icudtl.dat
qtwebengine_devtools_resources.pak
qtwebengine_resources.pak
qtwebengine_resources_100p.pak
qtwebengine_resources_200p.pak
need to be in .app/Contents/Resources

Resources