Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support 1.20.4 #3310

Merged
merged 18 commits into from
Feb 26, 2024
Merged

Support 1.20.4 #3310

merged 18 commits into from
Feb 26, 2024

Conversation

rom1504
Copy link
Member

@rom1504 rom1504 commented Feb 16, 2024

No description provided.

Copy link

socket-security bot commented Feb 22, 2024

New and removed dependencies detected. Learn more about Socket for GitHub ↗︎

Package New capabilities Transitives Size Publisher

🚮 Removed packages: npm/[email protected]

View full report↗︎

@extremeheat
Copy link
Member

extremeheat commented Feb 22, 2024

There was an issue with chat command params fixed with PrismarineJS/minecraft-data#850
Currently failing on this error

     Error: Error: crafting: non craftingTable used as craftingTable: minecraft:enchantment
      at EventEmitter.craft (lib/plugins/craft.js:32:13)
      at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
      at async /workspaces/mineflayer/test/externalTests/crafting.js:57:3

This might be fixed by @wgaylord's recipes PR in PrismarineJS/minecraft-data#843

and playerlist

playerlist header
{
  header: { type: 'end', value: undefined },
  footer: { type: 'end', value: undefined }
}

because tag.type end isn't handled, just fixed in prismarine-chat

I added some extra context to the error messages and swapped Node.js once() with a mineflayer one with a default 20s timeout (only place that needed unlimited time seems to be bot.flyTo()) to make errors more obvious. Seems that flakiness in some of the tests seems to be caused by windows not opening: https://github.com/PrismarineJS/mineflayer/actions/runs/7999230618/job/21846700577?pr=3310

  1) mineflayer_external 1.13.2v
       useChests:
     Error: Event windowOpen did not fire within timeout of 20000ms
      at onceWithCleanup (lib/promise_utils.js:62:26)
      at once (lib/promise_utils.js:76:10)
      at EventEmitter.openBlock (lib/plugins/inventory.js:366:28)
      at EventEmitter.openContainer (lib/plugins/chest.js:19:25)
      at withdrawBones (test/externalTests/useChests.js:54:29)
      at /home/runner/work/mineflayer/mineflayer/test/externalTests/useChests.js:119:9
      at process.processTicksAndRejections (node:internal/process/task_queues:95:5)

@wgaylord
Copy link
Contributor

wgaylord commented Feb 23, 2024

     Error: Error: crafting: non craftingTable used as craftingTable: minecraft:enchantment
      at EventEmitter.craft (lib/plugins/craft.js:32:13)
      at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
      at async /workspaces/mineflayer/test/externalTests/crafting.js:57:3

This might be fixed by @wgaylord's recipes PR in PrismarineJS/minecraft-data#843

After a bit of poking around this looks more like an issue in https://github.com/PrismarineJS/prismarine-windows/blob/master/index.js then with the recipes stuff itself. (I didn't actually read the error well when I suggested that my PR to fix the recipes may fix it) Looks like for some reason it thinks it opened an enchantment table instead of a crafting table.

Looking at the src looks like the crafter screen was inserted into the middle of the list for some reason, we may want to look into adding a json file (or edit the existing windows one) to include the network ID of the screen / window.

@wgaylord
Copy link
Contributor

wgaylord commented Feb 23, 2024

This should fix the crafting issue. PrismarineJS/prismarine-windows#105 Probably want to add a new inventory related feature now that I think about it.

@shroomjaks
Copy link

2024-02-23T06:26:42.7567449Z   1 failing
2024-02-23T06:26:42.7567669Z 
2024-02-23T06:26:42.7570657Z   1) mineflayer_external 1.17.1v
2024-02-23T06:26:42.7571226Z        exampleBlockFinder:
2024-02-23T06:26:42.7571772Z      Error: Promise timed out.
2024-02-23T06:26:42.7574286Z       at /home/runner/work/mineflayer/mineflayer/lib/promise_utils.js:83:13
2024-02-23T06:26:42.7575604Z       at async Object.runExample (test/externalTests/plugins/testCommon.js:211:7)
2024-02-23T06:26:42.7576683Z       at async /home/runner/work/mineflayer/mineflayer/test/externalTests/exampleBlockFinder.js:4:3
2024-02-23T06:26:42.7577303Z 
2024-02-23T06:26:42.7577311Z 
2024-02-23T06:26:42.7577318Z 
2024-02-23T06:26:42.7897291Z ##[error]Process completed with exit code 1.

How can I help contribute and fix this error?


bot._client.on('playerChat', (data) => {
console.log('playerChat')
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

please remove

@@ -107,8 +107,12 @@ function inject (bot, options) {
})

addDefaultPatterns()
bot._client.on('player_chat', (msg) => console.dir(msg, { depth: null }))
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

debug code

@3jq
Copy link

3jq commented Feb 25, 2024

hoorah when though?

@rom1504 rom1504 merged commit aa99daa into master Feb 26, 2024
4 checks passed
@rom1504
Copy link
Member Author

rom1504 commented Feb 26, 2024

/makerelease

@rom1504bot rom1504bot mentioned this pull request Feb 26, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Closed
Development

Successfully merging this pull request may close these issues.

5 participants