flightplan-tool / flightplan

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

Search halt after 3 consecutive days for NH #40

Open mlc130104 opened 5 years ago

mlc130104 commented 5 years ago
screenshot 2019-03-01 at 11 45 15 pm

After every 3 days of search, the chromium must halt such that the terminal will retry and give up after 90000ms so that I have to restart the search manually.

screenshot 2019-03-02 at 12 00 04 am screenshot 2019-03-02 at 12 16 04 am

Was able to reproduce this error on both Mac and Win PC

Mac versions npm: 6.7 node 11.10.1 flightplan-tools 0.3.49

Win versions npm: 6.4.1 node: 10.15.2 flightplan-tools 0.3.49

mlc130104 commented 5 years ago

Edit: Chromium will halt at the seventh enquires when searching for one-way rewards

jd20 commented 5 years ago

Thanks for reporting, I will take a look.

jd20 commented 5 years ago

I'm not able to reproduce this so far, using these commands:

flightplan search -w NH -f HKG -t HND -c economy -s 2019-06-10 -e 2019-07-20 -q 2 --force
flightplan search -w NH -f HKG -t HND -c economy -s 2019-06-21 -e 2019-07-01 -q 2 --force --headless

Is it still happening for you? I'm thinking they may have flagged the account or IP address you're using, and are limiting you to 6 searches per login session. You could try using a different NH account or a proxy (to change your IP address) to verify which is the case.

If it is the account, you can privately send me the account details and I can try to reproduce it locally and fix it (from your screenshot, they're still showing the results, instead of a "blocked" message or CAPTCHA, which I find odd).

mlc130104 commented 5 years ago

I still experience the same error by both changing the ip address (mobile network hotspot) and account. The weird thing is that awards can be found by clicking the search button at the halt chromium page.

On Sat, 2 Mar 2019 at 06:16, Jason notifications@github.com wrote:

I'm not able to reproduce this so far, using these commands:

flightplan search -w NH -f HKG -t HND -c economy -s 2019-06-10 -e 2019-07-20 -q 2 --force flightplan search -w NH -f HKG -t HND -c economy -s 2019-06-21 -e 2019-07-01 -q 2 --force --headless

Is it still happening for you? I'm thinking they may have flagged the account or IP address you're using, and are limiting you to 6 searches per login session. You could try using a different NH account or a proxy (to change your IP address) to verify which is the case.

If it is the account, you can privately send me the account details and I can try to reproduce it locally and fix it (from your screenshot, they're still showing the results, instead of a "blocked" message or CAPTCHA, which I find odd).

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/flightplan-tool/flightplan/issues/40#issuecomment-468830806, or mute the thread https://github.com/notifications/unsubscribe-auth/AG2115lw0MvVymfk2V1lGrvsDUCA5bumks5vSabBgaJpZM4bZsHa .

jd20 commented 5 years ago

Can you paste the full error call stack, when it times out after 90000 ms? I will try running a longer search tomorrow, in the hopes that I can reproduce.

jd20 commented 5 years ago

@mlc130104 Are ANA searches more than 7 queries still failing for you?

mlc130104 commented 5 years ago

image

Hello, it still fails for me. Attached with the timeout log for your reference.

mlc130104 commented 5 years ago

After performing upgrade in yarn, the problem vanished for mac. Will do upgrade on my PC later today to see if the problem will persist.

diser55 commented 5 years ago

Is this related to no new data added for the backend of flightplantool.com for 2020?

jd20 commented 5 years ago

No, they should not be related at all.