apinf / platform

Apinf - Open source API management platform with multi proxy and protocol support
https://apinf.com/
European Union Public License 1.1
74 stars 35 forks source link

Staging: shows empty page in IE and Edge browsers #3091

Closed saralavanip closed 6 years ago

saralavanip commented 6 years ago

Steps

1.Visit https://staging.apinf.io v 0.51.0

Findings

Shows empty page

Operating system

Browsers

bajiat commented 6 years ago

@saralavanip Can you reproduce the error again, go to console and copy-paste what is shown on console? This is potentially related to another error. See: #3088.

anarva commented 6 years ago

Could not reproduce with Firefox v.56 or Chrome v.61 on Linux.

saralavanip commented 6 years ago

@bajiat , please find the console error messages in IE browser and Edge. screenshots below:

IE: "SCRIPT5007: Array.prototype.toString: 'this' is null or undefined bundle.js (104,24987)"

Edge: " SCRIPT5007: Array.prototype.toString: 'this' is null or undefined bundle.js (104,25523) "

Screenshot:

ie_console_error_message

edge_console_error

edge_debugger_info

bajiat commented 6 years ago

I was able to reproduce the empty page problem in IE v. 11.674.15063. Did not get any console error, though.

staging empty first page

Correction: after reloading page I got the console error: "SCRIPT5007: Array.prototype.toString: 'this' is null or undefined"

matleppa commented 6 years ago

I also was able to reproduce it. IE 11.674.15063.0. With console error.

Staging_error_2017-11-03.PNG

bajiat commented 6 years ago

Same thing for apinf.io in IE: Empty page, zero console errors.

bajiat commented 6 years ago

Not able to reproduce in Edge.

Microsoft Edge 40.15063.674.0 Microsoft EdgeHTML 15.15063

preriasusi commented 6 years ago

Windows 10 + Firefox:

apinf io
matleppa commented 6 years ago

@preriasusi also found this API in API catalog (apinf.io). It seems, that because the name of API is in Chinese (or Japanese), the generation of slug has failed, thus the link being only https://apinf.io/apis

I wonder, whether these have some connection, because the error message was Array.prototype.toString: 'this' is null or undefined

production_error_2017-11-03.PNG

But what about error staging?

matleppa commented 6 years ago

Now I was able to reproduce the error in localhost.

IE 11.674.15063.0

92 errors. IE_empty_page.PNG

matleppa commented 6 years ago

0.49.0

In release 0.49.0 there are no errors.

Release 0.50.0

In release 0.50.0 there is lot of new code, however, nothing seems to be related to both UI and swagger. There is also Meteor version upgrade and many Meteor package updates.

Tracking changes after commits

After updating Meteor.js from 1.4.4.2 to 1.5.2 (commit 49898814e1bfdca359123cd316dab02201901354) the errors appear.

Updating Meteor updates automatically following packages also. accounts-base upgraded from 1.2.17 to 1.3.2 accounts-github upgraded from 1.2.1 to 1.3.0 accounts-password upgraded from 1.3.6 to 1.4.0 allow-deny upgraded from 1.0.5 to 1.0.6 babel-compiler upgraded from 6.18.2 to 6.20.0 boilerplate-generator upgraded from 1.0.11 to 1.2.0 ddp upgraded from 1.2.5 to 1.3.0 ddp-client upgraded from 1.3.4 to 2.1.3 ddp-common upgraded from 1.2.8 to 1.2.9 ddp-server upgraded from 1.3.14 to 2.0.2 dynamic-import added, version 0.1.1 ecmascript upgraded from 0.7.3 to 0.8.2 ecmascript-runtime upgraded from 0.3.15 to 0.4.1 ecmascript-runtime-client added, version 0.4.3 ecmascript-runtime-server added, version 0.4.1 ejson upgraded from 1.0.13 to 1.0.14 email upgraded from 1.2.1 to 1.2.3 localstorage upgraded from 1.0.12 to 1.1.1 meteor upgraded from 1.6.1 to 1.7.1 meteor-base upgraded from 1.0.4 to 1.1.0 minifier-js upgraded from 2.0.0 to 2.1.2 minimongo upgraded from 1.0.23 to 1.3.1 modules upgraded from 0.8.2 to 0.10.0 modules-runtime upgraded from 0.7.10 to 0.8.0 mongo upgraded from 1.1.17 to 1.2.0 mongo-dev-server added, version 1.0.1 npm-bcrypt upgraded from 0.9.2 to 0.9.3 npm-mongo upgraded from 2.2.24 to 2.2.30 promise upgraded from 0.8.8 to 0.9.0 reactive-dict upgraded from 1.1.8 to 1.1.9 shell-server upgraded from 0.2.3 to 0.2.4 standard-minifier-js upgraded from 2.0.0 to 2.1.1 webapp upgraded from 1.3.15 to 1.3.19

One guess

According to discussions found when searching: Array.prototype.toString: 'this' is null or undefined The problem might be similar as in https://github.com/zloirock/core-js/issues/300

Nazarah commented 6 years ago

from @55 Suggestion 1: update meteor to 1.6 to release 51 to see if the problem goes away. Suggestion 2: isolate this problem from development branch and make a release 51 if the problem takes too much time to solve

matleppa commented 6 years ago

2017-11-13 Researching suggestion 1. (update Meteor 1.6 to release 0.51.0)

Upgrading Meteor to 1.6 (in Windows)

Installing Meteor

matleppa commented 6 years ago

2017-11-14

Cont'd

Reinstalling ShareJS: meteor add mizzao:sharejs, meteor add mizzao:sharejs-ace

While installation (in this case $ meteor npm install --save bcrypt), an error message "error MSB4019: The imported pr oject "C:\Microsoft.Cpp.Default.props" was not found"

$ meteor npm cache clean

After that command still:

matleppa commented 6 years ago

2017-11-16

Continuing again

matleppa commented 6 years ago

2017-11-17

What about downgrading Meteor version?

$ meteor --release 1.4.4.3

matleppa commented 6 years ago

2017-11-21

Struggle against Meteor continues

[3984:001C82D8] 3524147 ms: Mark-sweep 583.5 (859.9) -> 578.5 (861.4) MB, 2270.1 / 4.1 ms allocation failure scavenge might not succeed [3984:001C82D8] 3526403 ms: Mark-sweep 584.9 (861.4) -> 579.6 (862.4) MB, 2023.7 / 3.9 ms allocation failure scavenge might not succeed [3984:001C82D8] 3528297 ms: Mark-sweep 585.9 (862.4) -> 580.7 (864.4) MB, 1589.0 / 4.3 ms allocation failure scavenge might not succeed

<--- JS stacktrace ---> Cannot get stack trace in GC. FATAL ERROR: NewSpace::Rebalance Allocation failed - process out of memory

C:\Users\matleppa\AppData\Local.meteor\packages\meteor-tool\1.5.2\mt-os.windows.x86_32\dev_bundle\lib\node_modules\meteor-promise\promise_server.js:218 throw error

matleppa commented 6 years ago

2017-11-22

checking, whether a working combination can be found

anarva commented 6 years ago

An imported swagger UI bundle JavaScript file which has been minified caused the problem - the compressed product was not compatible with IE. I have submitted a code fix for review.