xmtp / botkit

botkit
MIT License
6 stars 3 forks source link

Bug: Test `create-xmtp-bot` #7

Closed fabriguespe closed 5 months ago

fabriguespe commented 5 months ago

Describe the bug

If I attempt to run the command for local testing, as I previously did.

fabrizioguespe@fabrizios-MacBook-Pro create-xmtp-bot % create-xmtp-bot test2

The folder is generated but I'm getting:

file:///Users/fabrizioguespe/DevRel/Cursor-Bots/botkit/node_modules/execa/lib/error.js:60
                error = new Error(message);
                        ^

Error: Command failed with exit code 1: yarn install
Usage Error: The nearest package directory (/Users/fabrizioguespe/DevRel/Cursor-Bots/botkit/packages/create-xmtp-bot/test2) doesn't seem to be part of the project declared in /Users/fabrizioguespe/DevRel/Cursor-Bots/botkit.

- If /Users/fabrizioguespe/DevRel/Cursor-Bots/botkit isn't intended to be a project, remove any yarn.lock and/or package.json file there.
- If /Users/fabrizioguespe/DevRel/Cursor-Bots/botkit is intended to be a project, it might be that you forgot to list packages/create-xmtp-bot/test2 in its workspace configuration.
- Finally, if /Users/fabrizioguespe/DevRel/Cursor-Bots/botkit is fine and you intend packages/create-xmtp-bot/test2 to be treated as a completely separate project (not even a workspace), create an empty yarn.lock file in it.

$ yarn install [--json] [--immutable] [--immutable-cache] [--refresh-lockfile] [--check-cache] [--check-resolutions] [--inline-builds] [--mode #0]
    at makeError (file:///Users/fabrizioguespe/DevRel/Cursor-Bots/botkit/node_modules/execa/lib/error.js:60:11)
    at handlePromise (file:///Users/fabrizioguespe/DevRel/Cursor-Bots/botkit/node_modules/execa/index.js:124:26)
    at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
    at async Command.<anonymous> (file:///Users/fabrizioguespe/DevRel/Cursor-Bots/botkit/packages/create-xmtp-bot/byob.js:31:5) {
  shortMessage: 'Command failed with exit code 1: yarn install',
  command: 'yarn install',
  escapedCommand: 'yarn install',
  exitCode: 1,
  signal: undefined,
  signalDescription: undefined,
  stdout: "\x1B[31m\x1B[1mUsage Error\x1B[22m\x1B[39m: The nearest package directory (/Users/fabrizioguespe/DevRel/Cursor-Bots/botkit/packages/create-xmtp-bot/test2) doesn't seem to be part of the project declared in /Users/fabrizioguespe/DevRel/Cursor-Bots/botkit.\n" +
    '\n' +
    "- If /Users/fabrizioguespe/DevRel/Cursor-Bots/botkit isn't intended to be a project, remove any yarn.lock and/or package.json file there.\n" +
    '- If /Users/fabrizioguespe/DevRel/Cursor-Bots/botkit is intended to be a project, it might be that you forgot to list packages/create-xmtp-bot/test2 in its workspace configuration.\n' +
    '- Finally, if /Users/fabrizioguespe/DevRel/Cursor-Bots/botkit is fine and you intend packages/create-xmtp-bot/test2 to be treated as a completely separate project (not even a workspace), create an empty yarn.lock file in it.\n' +
    '\n' +
    '\x1B[1m$ \x1B[22myarn install [--json] [--immutable] [--immutable-cache] [--refresh-lockfile] [--check-cache] [--check-resolutions] [--inline-builds] [--mode #0]',
  stderr: '',
  cwd: '/Users/fabrizioguespe/DevRel/Cursor-Bots/botkit/packages/create-xmtp-bot/test2',
  failed: true,
  timedOut: false,
  isCanceled: false,
  killed: false
}

Also the i noticed that botkit bump is not updated in the template folder

fabriguespe commented 5 months ago

Latest version is not working

npx create-xmtp-bot@latest bot-name

CleanShot 2024-05-02 at 10 18 41@2x

fabriguespe commented 5 months ago

Also when i try to run yarn inside the template folder

CleanShot 2024-05-02 at 10 25 23@2x

rygine commented 5 months ago

fixed by #13