SenseNet / sn-dms-demo

Document Management Demo upon sensenet
GNU General Public License v2.0
3 stars 0 forks source link

Query issue while logging in using Edge #381

Closed LuisAverhoff closed 5 years ago

LuisAverhoff commented 6 years ago

So this issue seems to be present only in production when trying to login using Edge. This issue is nonexistent for other browsers like Google and Firefox.

Steps to reproduce issue:

1.) Go to the website(http://sn-dms-demo-dev.netlify.com) 2.) Login 3.) Open up the developer console by pressing F12 and you will be greeted with this error.

HTTP500: SERVER ERROR - The server encountered an unexpected condition that prevented it from fulfilling the request. (Fetch)GET - https://dmsservice.demo.sensenet.com/odata.svc/Root?query=TypeIs: AND Domain:'Public' AND LoginName:'alba@sensenet.com'&metadata=no&$inlinecount=allpages&$expand=Actions,Owner,CheckedOutTo&$top=10000

screenshot 13

Notice that in the query string, there is no reference to what the type is(TypeIs would refer to a user in this case). Probably has to do with how the server is interpreting the query string given that this a 500 error but that is just my guess.

This is the version of Edge that I'm running on.

Microsoft Edge: 42.17134.1.0 Microsoft EdgeHTML: 17.17134

LuisAverhoff commented 6 years ago

Here is more information that I found while looking in the network tab of the browser. Hopefully this helps you guys out.

{
  "error": {
    "code": "NotSpecified",
    "exceptiontype": "ParserException",
    "message": {
      "lang": "en-us",
      "value": "Unexpected  AND , (query:  +(TypeIs: AND Domain: Public  AND LoginName: alba@sensenet.com ) +(InTree: /Root ) ) [Line: 1, Col: 15]"
    },
    "innererror": null
  }
}
LuisAverhoff commented 5 years ago

What I did to fix this issue was installing the terser-webpack-plugin(npm install terser-webpack-plugin --save-dev)

and configuring the minimizer like so:

minimizer: [
   new TerserPlugin({
          terserOptions: {
            keep_fnames: true,
            compress: false
          }
    })
]