flightplan-tool / flightplan

Search for award inventory using Node.js and Headless Chrome!
Apache License 2.0
140 stars 41 forks source link

CX - the program will occur the error with first search. #39

Closed kochiya2002 closed 5 years ago

kochiya2002 commented 5 years ago

[CX] info Logging in... [CX] error Unexpected error occurred while searching! Error: Execution context was destroyed, most likely because of a navigation. at rewriteError (C:\Users\kitko\AppData\Roaming\npm\node_modules\flightplan-tool\node_modules\puppeteer\lib\ExecutionContext.js:159:15) at processTicksAndRejections (internal/process/next_tick.js:81:5) -- ASYNC -- at ExecutionContext. (C:\Users\kitko\AppData\Roaming\npm\node_modules\flightplan-tool\node_modules\puppeteer\lib\helper.js:108:27) at ExecutionContext.evaluate (C:\Users\kitko\AppData\Roaming\npm\node_modules\flightplan-tool\node_modules\puppeteer\lib\ExecutionContext.js:48:31) at ExecutionContext. (C:\Users\kitko\AppData\Roaming\npm\node_modules\flightplan-tool\node_modules\puppeteer\lib\helper.js:109:23) at DOMWorld.evaluate (C:\Users\kitko\AppData\Roaming\npm\node_modules\flightplan-tool\node_modules\puppeteer\lib\DOMWorld.js:105:20) at processTicksAndRejections (internal/process/next_tick.js:81:5) -- ASYNC -- at Frame. (C:\Users\kitko\AppData\Roaming\npm\node_modules\flightplan-tool\node_modules\puppeteer\lib\helper.js:108:27) at Page.evaluate (C:\Users\kitko\AppData\Roaming\npm\node_modules\flightplan-tool\node_modules\puppeteer\lib\Page.js:815:43) at Page. (C:\Users\kitko\AppData\Roaming\npm\node_modules\flightplan-tool\node_modules\puppeteer\lib\helper.js:109:23) at module.exports.textContent (C:\Users\kitko\AppData\Roaming\npm\node_modules\flightplan-tool\src\Searcher.js:314:17) at module.exports.login (C:\Users\kitko\AppData\Roaming\npm\node_modules\flightplan-tool\src\engines\cx\searcher.js:46:33) at processTicksAndRejections (internal/process/next_tick.js:81:5)

jd20 commented 5 years ago

Is this fairly reproducible (happens every time, or just randomly)? The Execution context was destroyed errors are usually timing issues (page reloads or navigates unexpectedly). If it is fairly repeatable, what query are you running to reproduce it?

kochiya2002 commented 5 years ago

Yes, this problem occurs every time. I found out the error message will occur when the login successfully,

Below is the searching result From HKG to KIX Cabin: economy from 2019-08-06 to 2019-08-11

jd20 commented 5 years ago

Fixed on 0.3.46.