ROpdebee's userscripts support thread

I randomly saw this, and reminded myself that I made a standalone script to do this, and you helped me with the CSS! (I also just fixed now that it should select by default cover type front)

Made a pull request to add it to the original MB: Enhanced Cover Art Uploads. (Built it locally and it works)

Any chance we can get the art uploading script to work with uploading event art? :slightly_smiling_face:

Just the part where you paste in the link to the image file so that you don’t have to download the file and then upload it again, also so that edit note explains exactly where you got it. Omit all the stuff with the music services but keep maxurl stuff in there so we get the largest possible, great for image links copied from twitter etc.

5 Likes

Every time I try to upload from Spotify it says the release doesn’t exist. Even though Harmony & a-tisket links to it fine and I can open the image from there in a new tab and copy & paste the URL and it works.

2 Likes

still having this issue :frowning:

example: Release ā€œSpacesuitā€ by Degs & Gabriella Bongo - MusicBrainz

1 Like

It seems Spotify is messing with the Open Graph tags depending on how or who is requesting a page. Some ā€œtestingā€ sites receive the necessary elements, some don’t. I also don’t receive them in my browser hence the failure.

1 Like

Patched it with Gemini. Just replace the entire class SpotifyProvider extends HeadMetaPropertyProvider block with the code below:

class SpotifyProvider extends HeadMetaPropertyProvider {
    constructor() {
      super(...arguments);
      _defineProperty(this, "supportedDomains", ['open.spotify.com']);
      _defineProperty(this, "favicon", 'https://open.spotifycdn.com/cdn/images/favicon32.8e66b099.png');
      _defineProperty(this, "name", 'Spotify');
      _defineProperty(this, "urlRegex", /\/album\/(\w+)/);
    }
    is404Page(document_) {
      return qsMaybe('head > meta[property="og:title"]', document_) === null;
    }
    fetchPage(url, options) {
      return super.fetchPage(url, {
        ...options,
        headers: {
          ...(options === null || options === void 0 ? void 0 : options.headers),
          'User-Agent': 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/101.0.4951.67 Safari/537.36 OpenGraphXYZBot/1.0',
          Accept: '*/*'
        }
      });
    }
  }

I’ve used webhook.site to gain info how the successful requests look like.

Made a pull request. Please bear with me this is Neuland for me

2 Likes

The script to format work codes at the touch of a button no longer works. I can format the codes by clicking the button, but the changes will not submit on MB’s end. Did a recent server update break it or something?

do you mean this script? MB: Bulk copy-paste work codes

This one is still working for me

The script to copy and enter work codes still works, but the one that alters them to fit the correct formats does not.

1 Like