INNER CODE UNIT · JavaScript

lazyCreateAdapter

chadbyte/clay · lib/yoke/index.js:435

async function lazyCreateAdapter(adapters, vendor, opts) {
  opts = opts || {};

  var vendorInfo = vendorRegistry.getVendorInfo(vendor);
  if (vendorInfo && !vendorInfo.osUserIsolation && (opts.osUsers || opts.linuxUser)) {
    console.log("[yoke] Refusing lazy " + vendorInfo.displayName + " adapter creation for OS-isolated user " + (opts.linuxUser || "unknown"));
    return null;
  }

  // Force re-check since user may have logged in after server start
  invalidateAuthCache();
  var installed = checkInstalled();
  if (!installed[vendor]) return null;

  try {
    var ad = createAdapter({
      vendor: vendor,
      cwd: opts.cwd,

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…