Jump to content

My Browser Builds (Part 3)


Recommended Posts

6 hours ago, Art7220 said:

A rendering error occurred: e.attachShadow is not a function.

Part of Web Components, which UXP browsers don't support (fully). Partial implementation may be enabled by enabling dom.webcomponents.enabled on about:config page.

6 hours ago, Art7220 said:

How do I fix this?

Besides hoping it works by enabling the pref above (low chance)? I don't know, learn to program, help the upstream (Moonchild Productions) implement Web Components?

Link to comment
Share on other sites


UCyborg:

23 hours ago, UCyborg said:

Part of Web Components, which UXP browsers don't support (fully). Partial implementation may be enabled by enabling dom.webcomponents.enabled on about:config page.

Thanks but it only partially helped. It kind of worked on Xfinity but Youtube would only show videos without the side panels.

webcomponents.org/polyfills Would this work on New Moon?  Roytam1, what do you know about this problem?

Edited by Art7220
Add more info.
Link to comment
Share on other sites

On 3/11/2022 at 5:10 PM, TrevMUN said:

I've been having the same problems on Coinbase, BlockFi, and LinkedIn. Coinbase and BlockFi stopped working on New Moon 28 a few months ago. A few days ago LinkedIn stopped working as well. I had ONE tab that was still open which allowed me to still receive and send messages, but this morning Kaiser Permanente's website caused New Moon to lock up and I had to kill the process, which of course meant when I relaunched New Moon that my last remaining LinkedIn tab no longer works.

This sucks. New Moon 28 is the browser I turn to when sites stop working on my other browsers.

File complaints with all these websites.

They need to know that blindly using breakage-causing JS code is NOT okay!

I complained to GitHub and they reverted enough breakage that it now works in Chromium 70 again though New Moon 28 is still broken.

Though it's a losing battle for sure... as of a few days ago, GitHub file uploads are now once again broken... it's like whack-a-mole, you polyfill a "bug" in their JS, and soon enough, a new one crops up again that breaks the whole damn site again.

 

What we really need is some of extension to replace all the JS on websites with the JavaScript they used two years ago, pulling from the Internet Archive or something.

 

That might actually work - scrape the JS for sites that are broken now, using old JS, and see if they start working again...

Maybe we can get a list of changes going and replace the diffs we see.

Edited by InterLinked
  • Like 1
  • Upvote 1
Link to comment
Share on other sites

As long as their sites work in the latest versions of Edge and Google Chrome (and Safari for Macs), that's all the authors of a lot of sites care about now.
:realmad:

  • Like 1
  • Upvote 1
Link to comment
Share on other sites

5 minutes ago, Dave-H said:

As long as their sites work in the latest versions of Edge and Google Chrome (and Safari for Macs), that's all the authors of a lot of sites care about now.
:realmad:

Not even that - but only the *latest* versions of those browsers! (Technically, I'm using "Chrome", but a 3 year old version).

Maybe this will be a wakeup call to the WWW: stop using useless JS libraries you don't need and write all your damn code yourself. If you can't understand it, and you don't know what it does, and you don't know why you need, then don't use it!!!

This has never failed to serve me well as a webmaster. And of course, none of my websites randomly break.

jquery is pretty much the only JS library I ever use, and even then, only on pages that actually "need" JS. Everything else on top of that, I write if I need it. And if I don't need JS, I don't use it.

It's not "simplistic", it's called "resilient progressive web development".

  • Like 2
  • Upvote 1
Link to comment
Share on other sites

2 hours ago, InterLinked said:

File complaints with all these websites.

They need to know that blindly using breakage-causing JS code is NOT okay!

2 hours ago, Dave-H said:

As long as their sites work in the latest versions of Edge and Google Chrome (and Safari for Macs), that's all the authors of a lot of sites care about now.
:realmad:

Dave's right. I did reach out to LinkedIn's support staff on the 12th and submitted a ticket notifying them of this: "Since last week, LinkedIn is no longer usable on any of my browsers and I am completely unable to access any of the features of the site. Attempting to navigate to any page leaves me stuck at the LinkedIn loading animation. One of my browser consoles reported these errors:

'unreachable code after return statement[Learn More]  
bn6mu4p20im96zhacyvmtecyc:6735
unreachable code after return statement[Learn More]  
bn6mu4p20im96zhacyvmtecyc:19064
SyntaxError: expected expression, got '.'[Learn More]  
bn6mu4p20im96zhacyvmtecyc:32717:41
unreachable code after return statement[Learn More]  
1lwbhppaad1owcov8hethjyoa:6
ReferenceError: runningTests is not defined[Learn More]  
8b1tthssubm76w215rk7nc4o2:2530:14
unreachable code after return statement[Learn More]  
1lwbhppaad1owcov8hethjyoa:6'""

Unfortunately, the support staff didn't take this as a bug report. Instead they gave me the usual: telling me to try logging in and out, clear my browser cache and cookies, only use the browsers they support,and the like.

Is there anything we can do on our end? Because I doubt these companies are going to fix their own code.

Link to comment
Share on other sites

Just came by to see if there was any reaction to the new release of Pale Moon 30.  It appears that, while it runs on the Goanna engine, Pale Moon is no longer built on UXP.  I'm just trying it right now to see if any sites I was using before run now.

 

  • Like 1
Link to comment
Share on other sites

4 hours ago, InterLinked said:

Not even that - but only the *latest* versions of those browsers! (Technically, I'm using "Chrome", but a 3 year old version).

I'm using a v69 (late 2018) and it works for 90% or so of everything I've thrown at it.

Regarding the other 10%, and to be as blunt as possible, "nobody cares".

I mean that towards the web masters running those 10% of web sites - "none of them care".

As much as we (myself included) "live in the past", we are unrealistic to expect web masters to remain in the past.

Web masters know what browsers are visiting their web site.

They know that for every 10,000 visits, they have 1 using a four-year old web browser or a twenty-year old operating system.

LIFE GOES ON if they "lose" that ONE visitor.  Plain and simple.

  • Like 2
Link to comment
Share on other sites

3 hours ago, Jody Thornton said:

Just came by to see if there was any reaction to the new release of Pale Moon 30.  It appears that, while it runs on the Goanna engine, Pale Moon is no longer built on UXP.  I'm just trying it right now to see if any sites I was using before run now.

 

Yeah, will be wondering myself as most of use couldn't run it on our old computers.

 

1 hour ago, NotHereToPlayGames said:

<OT>

As much as we (myself included) "live in the past"...

<OT>

Am I too old to skateboard at almost 50? Would somebody (kindly) point me to this "fountain of youth" I hear of. :lol:

In contrast:

On this (Dell Dimension 3000 ... very slow) the only browsers that will run (somewhat) ok(ish) is Arctic Fox and New Moon; while on my Dell Optiplex, your 360 V11 is my default 2nd to Serpent. I only fire this thing up a few times a year to keep it going, but wouldn't be able to use it to do much.

Edited by XPerceniol
Link to comment
Share on other sites

6 hours ago, InterLinked said:

I complained to GitHub and they reverted enough breakage that it now works in Chromium 70 again

In my 360EEv11 (Chromium-69-based) copy, to get GitHub (that I use a lot...) fully functional, I had to polyfill:

globalThis (implemented in Chrome 71)
Object.fromEntries (implemented in Chrome 73)
Promise.any (implemented in Chrome 85)
Promise.allSettled (implemented in Chrome 76)
queueMicrotask (implemented in Chrome 71)
String.replaceAll (implemented in Chrome 85)
replaceChildren (implemented in Chrome 86)

I'm using a local fork of your original extension, BTW, so many thanks! :thumbup
However, even those 7 polyfills won't be enough, it seems :realmad: , because, over the last couple of months, those M$ employees :angry: have been trialing ECMAScript2020/2022 syntax with unsupported (by both UXP+Chromium<85) operators (Nullish coalescing, "??", and optional chaining, "?.") which can't be polyfilled; thus, GitHub becomes severely broken (to the point of unusable); at the time of this writing, they have reverted that breaking code, but it's dead certain it'll come back (since it's supported by M$'s sweet child, ChrEdge) ... :angry:

6 hours ago, InterLinked said:

though New Moon 28 is still broken.

NM28 is UXP-based, to get GH functional, use any of

https://github.com/JustOff/github-wc-polyfill

https://github.com/SeaHOH/github-wc-polyfill

https://github.com/martok/palefill

Those only support officially Pale Moon (but NOT v30.0), so to install in NM28 you have to modify maxVersion inside install.rdf; GH+GL break the extension constantly, so make sure you're always on the latest stable/beta build... ;)

Edited by VistaLover
Link to comment
Share on other sites

1 minute ago, VistaLover said:

In my 360EEv11 (Chromium-69-based) copy, to get GitHub (that I use a lot...) fully functional, I had to polyfill:

globalThis (implemented in Chrome 71)
Object.fromEntries (implemented in Chrome 73)
Promise.any (implemented in Chrome 85)
Promise.allSettled (implemented in Chrome 76)
queueMicrotask (implemented in Chrome 71)
String.replaceAll (implemented in Chrome 85)
replaceChildren (implemented in Chrome 86)

I'm using a local fork of your original extension, BTW, so many thanks! :thumbup

 

Ah, nice! Any chance you're able to contribute your additions back? I could probably benefit from that a lot myself!

 

1 minute ago, VistaLover said:


However, even those 7 polyfills won't be enough, it seems :realmad: , because, over the last couple of months, those M$ employees :angry: have been trialing ECMAScript2020/2022 syntax with unsupported (by both UXP+Chromium<85) operators (Nullish coalescing, "??", and optional chaining, "?.") which can't be polyfilled; thus, GitHub becomes severely broken, to the point of unusable); at the time of this writing, they have reverted that breaking code, but it's dead certain it'll come back (since it's supported by M$'s sweet child, ChrEdge) ... :angry:

 

Yup, I've been noticing a lot of that "unexpected syntax ?" type of stuff myself... real shame...

 

1 minute ago, VistaLover said:

NM28 is UXP-based, to get GH functional, use any of

https://github.com/JustOff/github-wc-polyfill

https://github.com/SeaHOH/github-wc-polyfill

https://github.com/martok/palefill

Those only support officially Pale Moon (but NOT v30.0), so to install in NM28 you have to modify maxVersion inside install.rdf; GH+GL break the extension constantly, so make sure you're always on the latest stable/beta build... ;)

Interesting, it seemed like NM was more broken than Chromium 70, but sounds like with polyfills it can be better than it!

Link to comment
Share on other sites

20 minutes ago, InterLinked said:

Any chance you're able to contribute your additions back? I could probably benefit from that a lot myself!

Here's my copy of file "polyfills.js" inside my local fork of your extension:

var actualCode = `
// https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/globalThis
// implemented in Chrome 71
// https://mathiasbynens.be/notes/globalthis
(function() {
	if (typeof globalThis === 'object') return;
	Object.defineProperty(Object.prototype, '__magic__', {
		get: function() {
			return this;
		},
		configurable: true
	});
	__magic__.globalThis = __magic__;
	delete Object.prototype.__magic__;
}());
// https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/fromEntries
// implemented in Chrome 73
// https://stackoverflow.com/a/68655198
// https://gitlab.com/moongoal/js-polyfill-object.fromentries/-/blob/master/index.js
// -> https://vanillajstoolkit.com/polyfills/objectfromentries/
if (!Object.fromEntries) {
	Object.fromEntries = function (entries) {
		if (!entries || !entries[Symbol.iterator]) { 
      throw new Error('Object.fromEntries() requires a single iterable argument');
    }
		let obj = {};
		for (let [key, value] of entries) {
			obj[key] = value;
		}
		return obj;
	};
}
// https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise/any
// implemented in Chrome 85 
// https://github.com/ungap/promise-any
// copied from github-wc-polyfill
if (!('any' in Promise && typeof Promise.any == 'function')) Promise.any = function($) {
  return new Promise(function(D, E, A, L) {
    A = [];
    L = $.map(function($, i) {
      return Promise.resolve($).then(D, function(O) {
        return ((A[i] = O), --L) || E({
          errors: A
        });
      });
    }).length;
  });
};
// https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise/allSettled
// implemented in Chrome 76
// https://95yashsharma.medium.com/polyfill-for-promise-allsettled-965f9f2a003
if (!('allSettled' in Promise && typeof Promise.allSettled == 'function')) Promise.allSettled = function (promises) {
  let mappedPromises = promises.map((p) => {
    return p
      .then((value) => {
        return {
          status: 'fulfilled',
          value,
        };
      })
      .catch((reason) => {
        return {
          status: 'rejected',
          reason,
        };
      });
  });
  return Promise.all(mappedPromises);
};
// https://developer.mozilla.org/en-US/docs/Web/API/queueMicrotask
// implemented in Chrome 71
// https://stackoverflow.com/a/61569775
(function() {
'use strict';
// lazy get globalThis, there might be better ways
const globalObj = typeof globalThis === "object" ? globalThis :
  typeof global === "object" ? global :
  typeof window === "object" ? window :
  typeof self === 'object' ? self :
  Function('return this')();

if (typeof queueMicrotask !== "function") {

  const checkIsCallable = (callback) => {
    if (typeof callback !== "function") {
      throw new TypeError("Failed to execute 'queueMicrotask': the callback provided as parameter 1 is not a function");
    }  
  };

  if (typeof Promise === "function" && typeof Promise.resolve === "function") {
    globalObj.queueMicrotask = (callback) => {
      checkIsCallable(callback);
      Promise.resolve()
        .then(() => callback()) // call with no arguments
        // if any error occurs during callback execution,
        // throw it back to globalObj (using setTimeout to get out of Promise chain)
        .catch((err) => setTimeout(() => {throw err;}));
   };
  }
  else if (typeof MutationObserver === "function") {
    globalObj.queueMicrotask = (callback) => {
      checkIsCallable(callback);
      const observer = new MutationObserver(function() {
        callback();
        observer.disconnect();
      });
      const target = document.createElement('div');
      observer.observe(target, {attributes: true});
      target.setAttribute('data-foo', '');
    };
  }
  else if (typeof process === "object" && typeof process.nextTick === "function") {
    globalObj.queueMicrotask = (callback) => {
      checkIsCallable(callback);
      process.nextTick(callback);
    };
  }
  else {
    globalObj.queueMicrotask = (callback) => {
      checkIsCallable(callback);
      setTimeout(callback, 0);
    }
  }
}
})();

queueMicrotask(() => console.log('microtask'));
console.log('sync');
// https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String/replaceAll
// implemented in Chrome 85
// https://vanillajstoolkit.com/polyfills/stringreplaceall/
if (!String.prototype.replaceAll) {
  String.prototype.replaceAll = function(str, newStr) {
    // If a regex pattern
    if (Object.prototype.toString.call(str).toLowerCase() === '[object regexp]') {
      return this.replace(str, newStr);
    }
    // If a string
    return this.replace(new RegExp(str, 'g'), newStr);
  };
};
// https://developer.mozilla.org/en-US/docs/Web/API/ParentNode/replaceChildren
// implemented in Chrome 86
// https://github.com/XboxYan/dom-polyfill
// copied from github-wc-polyfill
(function() {
  if (Element.prototype.replaceChildren === undefined) {
    Element.prototype.replaceChildren = function(...nodesOrDOMStrings) {
      while (this.lastChild) {
        this.removeChild(this.lastChild)
      }
      if (nodesOrDOMStrings.length) {
        this.append(...nodesOrDOMStrings)
      }
    }
  }
}());
`;

var script = document.createElement('script');
script.textContent = actualCode;
(document.head||document.documentElement).appendChild(script);
script.remove();

As you can see, it's a patchwork of code "borrowed" from you, various polyfill authors and portions from github-wc-polyfill extension, by JustOff; I couldn't be arsed to make a proper fork and publish on GH... FWIW, I use a different (smaller) version of that file for my 360EEv12 (Chromium-78-based) copy (only the polyfills for JS code implemented in Chromium > 78.0). But I fear I'm derailing this thread... :P

Link to comment
Share on other sites

So MCP pushed GRE (Goanna5/PM30) to their repo, with crazy huge directory structure rearrangements. tracking is still ongoing in roytam1/palemoon-source-tracking/commits/tracking-gre but for now I'm exhausted while trying to figure out how files are moved.

  • Like 1
Link to comment
Share on other sites

@roytam1 : I've left NM28 behind me several months ago, now exclusively (from the browsers you are compiling) using Serpent 52.9.0 (32-bit) in this Vista SP2 x86 laptop; what is the future for Serpent 52 with the advent of GRE ? Could platform enhancements implemented in GRE be still backported to St52's UXP?

And I don't know whether NM28 users are aware, but GRE fully removes the Pale Moon GUID (also used in NM27/NM28) and a restructure of MCP's add-ons site is currently in progress, will you also adopt this change for future NM28 versions?

https://www.palemoon.org/releasenotes.shtml

  • Like 1
Link to comment
Share on other sites

17 minutes ago, VistaLover said:

Could platform enhancements implemented in GRE be still backported to St52's UXP?

thats the thing I want to do, by backporting their changes to my not-rearranged tree.

  • Like 2
  • Upvote 5
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   1 member



×
×
  • Create New...