adrg / go-wkhtmltopdf

Handcrafted Go bindings for wkhtmltopdf and high-level HTML to PDF conversion interface
https://pkg.go.dev/github.com/adrg/go-wkhtmltopdf
MIT License
238 stars 21 forks source link

Errors #4

Closed loeffel-io closed 4 years ago

loeffel-io commented 4 years ago

WARNING: QApplication was not created in the main() thread. QObject::startTimer: QTimer can only be used with threads started with QThread QObject::startTimer: QTimer can only be used with threads started with QThread QObject::startTimer: QTimer can only be used with threads started with QThread QObject::startTimer: QTimer can only be used with threads started with QThread

loeffel-io commented 4 years ago

fatal error: unexpected signal during runtime execution [signal SIGSEGV: segmentation violation code=0x1 addr=0xb01dfacedebac1e pc=0x4763ddb]

runtime stack: runtime.throw(0x42f0949, 0x2a) /usr/local/Cellar/go/1.12.8/libexec/src/runtime/panic.go:617 +0x72 runtime.sigpanic() /usr/local/Cellar/go/1.12.8/libexec/src/runtime/signal_unix.go:374 +0x4a9

goroutine 1 [syscall]: runtime.cgocall(0x42549f0, 0xc0004c5cc0, 0xc0004c5968) /usr/local/Cellar/go/1.12.8/libexec/src/runtime/cgocall.go:128 +0x5b fp=0xc0004c5c90 sp=0xc0004c5c58 pc=0x4004c5b github.com/adrg/go-wkhtmltopdf._Cfunc_wkhtmltopdf_convert(0xc97cbb0, 0x0) _cgo_gotypes.go:118 +0x49 fp=0xc0004c5cc0 sp=0xc0004c5c90 pc=0x4229a29 github.com/adrg/go-wkhtmltopdf.(Converter).Run.func1(0xc000441e00, 0x0) /Users/lucas.loeffel/go/src/github.com/adrg/go-wkhtmltopdf/converter.go:212 +0x62 fp=0xc0004c5d00 sp=0xc0004c5cc0 pc=0x422e352 github.com/adrg/go-wkhtmltopdf.(Converter).Run(0xc000441e00, 0x433c480, 0xc0000a0028, 0x1b6, 0xc0000a0028) /Users/lucas.loeffel/go/src/github.com/adrg/go-wkhtmltopdf/converter.go:212 +0xdf fp=0xc0004c5d80 sp=0xc0004c5d00 pc=0x422a3ef main.(*mail).generateBodyPdf(0xc00009dea0, 0x0, 0x0) /Users/lucas.loeffel/go/src/github.com/loeffel-io/tax/mail.go:143 +0x396 fp=0xc0004c5e28 sp=0xc0004c5d80 pc=0x4252f56 main.main() /Users/lucas.loeffel/go/src/github.com/loeffel-io/tax/main.go:87 +0xb5a fp=0xc0004c5f98 sp=0xc0004c5e28 pc=0x425410a runtime.main() /usr/local/Cellar/go/1.12.8/libexec/src/runtime/proc.go:200 +0x20c fp=0xc0004c5fe0 sp=0xc0004c5f98 pc=0x402e22c runtime.goexit() /usr/local/Cellar/go/1.12.8/libexec/src/runtime/asm_amd64.s:1337 +0x1 fp=0xc0004c5fe8 sp=0xc0004c5fe0 pc=0x4058511

adrg commented 4 years ago

Hi @loeffel-io. Are you using the converter in a go routine? The issue might be related to #3. Otherwise, could you add a small code sample of how to reproduce the problem?

adrg commented 4 years ago

Closing this as it seems to be a duplicate of #3. Let's keep all discussion regarding this problem in that issue.

loeffel-io commented 4 years ago

Hey @adrg, sorry for the late response. Yea, i think this was inside a go routine