CheshireCaat / playwright-with-fingerprints

Anonymous automation via playwright with fingerprint replacement technology.
MIT License
140 stars 11 forks source link

Browser.version not correct set #9

Closed 1dy closed 1 year ago

1dy commented 1 year ago

Browser.version is undefined despite I have set plugin.version. This invalidates the browser.newContext because it depending on the existance of browser.version.

      const fingerprint = await plugin.fetch(this.fingerprintAuth, this.fetchOptions);
      plugin.version = '114.0.5735.91'; // or "default" or anything else 
      console.log('Plugin set chrome version as: ', plugin.version);
      const browser = await plugin.useProxy(proxy, {detectExternalIP: false}).useFingerprint(fingerprint).launchPersistentContext('', this.launchOptions);
      console.log('Browser Version is: ', browser.version);
      console.log('Browser.newContext: ', browser.newContext);

Output:

Plugin set chrome version as:  114.0.5735.91
Browser Version is:  undefined
Browser.newContext:  undefined
CheshireCaat commented 1 year ago

You're wrong, the plugin has nothing to do with it. The "launchPersistentContext" method returns an instance of the browser context, not the browser itself, so these methods are not available:

https://playwright.dev/docs/api/class-browsercontext

There are no such methods in this class.