Access page secured by htaccess in chromium directly (angularjs error appears) - angularjs

I experienced an strange error in angularjs when I use .htaccess (AuthType Basic) within chromium.
If I access the page 'in an normal way' the user and password promt get shown from the browser. If I enter them angularjs (and the rest of the page) is working perfectly fine!
But when I access the page with embedded credentials, e.g. like this: http://user:password#domain.com/directory I get the following warnung:
[Deprecation] Subresource requests whose URLs contain embedded credentials (e.g. https://user:pass#host/) are blocked. See https://www.chromestatus.com/feature/5669008342777856 for more details.
which due to its 'just' a warning, it should not cause the issue.
But along this the following error gets shown as well (which stops the page from working):
angular.js:14700 Error: [$controller:ctrlreg] http://errors.angularjs.org/1.6.6/$controller/ctrlreg?p0=myController
at angular.js:88
at angular.js:10973
at da (angular.js:10050)
at q (angular.js:9820)
at f (angular.js:9174)
at f (angular.js:9177)
at angular.js:9039
at angular.js:1954
at m.$eval (angular.js:18423)
at m.$apply (angular.js:18523)
any clue why this error gets show, or better, how to avoid this error? Using non-embedded credentials the error is not appearing and the exact same code is working perfectly fine.
When I use e.g. chrome both approaches are working great as well. The issue just appears using the combination of chromium and embedded credentials.
PS: my chromium is running on raspbian in case this matter.

Related

ReferenceError: privateSpecialRepair is not defined

I am getting this error on sentry. I don't know how or why the next/router is redirecting users to the same page, it is happening on some browsers, and on some browsers, it is working just fine.
Tags
{
"routing.instrumentation": "next-router"
}
Operation - pageLoad
It looks like this has to do specifically with the Vivo OEM browser.
The current Vivo is based on Chrome 87 (2020).
I ended up on some Chinese dev blogs etc detailing similar errors with the same message.
Those seem to have been due to Vivo not handling new ES6 features. Not certain exactly what is not supported in the current version that's causing this.
We're looking at adding filtering around the <anonymous> file in the stack trace since (as far as I can tell) that's always 3rd party scripts throwing up.

Google analytics script fails to load within page with 500 error code

Google analytics script fails to load with 500 error code on the website however if the link is opened in a new tab it's working fine.
Checked on MacOS BigSur Chrome, Firefox, Safari in normal and Incognito/Private mode without any active browser extension and got the same error.
Even the solution provided by NextJS https://github.com/vercel/next.js/tree/canary/examples/with-google-analytics does not work
Whatever I tried, I can't get rid of this error: GET https://www.googletagmanager.com/gtag/js?id=G-O5IW7EZ46Q net::ERR_ABORTED 500
Also tried to create simple static site to check is it NextJS issue or not and seems like it's not. https://codesandbox.io/s/nifty-currying-1hzu1?file=/index.html - this is the link to sandbox with google analytic script initialization and it fails as well with same error code.
Try to move the Google Analytics snippet in head section of the page.
I found the problem. The issue was in the Adguard software installed on the machine. Since the app was on OS level tt was automatically blocking across all browsers and private or incognito mode.

Why Do I Get a Blank Page on an Error but other people don't

I am watching this video and when an error occurs he gets an actual error on the page and only a blank white screen when he deploys the site.
I see this a few times. However I only see white screen no matter if I am on local host or on production.
I see he is using chrome on Mac and I am using it on PC. Not sure if that is the difference.
While I can't say definitively, my suspicion is that you aren't using create-react-app to setup your project.
You will only see that error message if you have used CRA to set up your project, as that is a specific error handler that is baked into that project. If you're not using create-react-app, React should log an error to your console instead.
ReactJS smart enough to hide the errors to the users when the app is in production mode.
You will see only a blank page if the app gets crashed but if you inspect the page you will see small detail about the error in the console.
if you running the app in development mode you will see full details about the errors.
for this case cames componentDidCatch method to handle app crash errors, instead of the blank page display a “Something went wrong” message to the user or you can send XHR request to the server with the error info.
Check out this example of declaring and using an error boundary
https://reactjs.org/blog/2017/07/26/error-handling-in-react-16.html

Why am I getting a 'Failed to find a valid digest ' error?

In my reactapp created by create-react-app I suddenly have an error in chrome when I try to run my app:
Failed to find a valid digest in the 'integrity' attribute for resource 'http://localhost:3000/static/js/0.chunk.js' with computed
SHA-256 integrity 'hW0einVybma+FCDLYbayWASTmGI9JBE1dkrmPvDzJXQ='. The
resource has been blocked.
However in IE it works fine. All I did was changing a label on a Button component. How can I avoid this error on chrome?
It sounds like the feature is simply doing what it's intended to do.
Do you have compression enabled in your Chrome for Android browser?
Google may be minifiying your CSS before sending it to your phone causing the signature to be invalid.
SSL prevents this from happening. Maybe we should look for https in PUBLIC_URL and toggle this feature based on that.
https://developer.chrome.com/multidevice/data-compression

angularjs error on IE only with no debug option

I have an angular application that run ok on chrome and firefox.
But on IE the application does not work.
My Big problem is that I can't find the error reason. and got some generic error.
How can I debug the application on IE or how can I find the reason for the Error
This means that ng module is failing to load. :)
Please look at your browser's console to find if any files are missing or not being downloaded correctly. Also it helps if you click on the link to http://errors.angularjs.org in your console, it will give details about which particular module is failing to load.
Check below link for complete details for resolution:
http://blog.technovert.com/2014/10/dependency-injection-fails-angularjs/
IE Debugging : First of all you need to ensure your Angular application works on IE please consider the use ng-style tags instead of style="{{ someCss }}". The latter works in Chrome and Firefox but does not work in Internet Explorer <= 11. Arguably, this is the biggest annoyance of IE—the page just doesn’t load and doesn’t give any errors. Sometimes you need to view the page again in Firefox. If it’s not an IE specific error, Firebug will pick it up. If Firebug loads normally, the chances are it’s one of two IE specific errors: a trailing comma, or unsupported XML syntax.
For minimize the application files I use
bundles.Add(new ScriptBundle("~/app").IncludeDirectory("~/Assets/app", "*.js", true)
);
(Part of asp.net mvc)
And from the layout page I take all the application files
#Scripts.Render("~/app")
Like I said this part of code worked for me in some browsers, But on IE It fail.
By Changing the script src to all specific files, I resolve this problem. and now on IE it work like the other browsers.
Maybe I miss a comma or ";" (end row) or something like that.
Thanks
need to check this page or api
http://henriquat.re/appendix/angularjs-and-ie8/necessary-changes-for-ie8-compatibility.html
https://docs.angularjs.org/guide/ie

Resources