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

feat: bun related docs (@stonega) #1129

Draft
wants to merge 19 commits into
base: main
Choose a base branch
from
Draft

feat: bun related docs (@stonega) #1129

wants to merge 19 commits into from

Conversation

MasedMSD
Copy link
Collaborator

@MasedMSD MasedMSD commented Oct 1, 2024

Originally PR was created by @stonega, but it looks like he's not going to continue with this PR. So, I think we should mention Bun as a possible way to work with a bot, even though Bun has a large number of issues. Also Bun finally supports conversations plugin and a decent part of Russian language chat users use it for their projects.

I made some changes and added Bun mentions to the hosting files documentation

- changed bot.ts to index.ts
- mention bun at hosting docs
@MasedMSD MasedMSD requested a review from KnorpelSenf October 1, 2024 13:45
Copy link

github-actions bot commented Oct 1, 2024

@github-actions github-actions bot temporarily deployed to pull request October 1, 2024 13:47 Inactive
@MasedMSD
Copy link
Collaborator Author

MasedMSD commented Oct 2, 2024

Should we leave index.ts or should we tell the user to create a bot.ts file each time in order for the NodeJS and Deno examples to be the same?

@KnorpelSenf
Copy link
Member

I have now wasted more time on this than I ever wanted, maybe I'll get back to this in a week or so

Copy link
Member

@KnorpelSenf KnorpelSenf left a comment

Choose a reason for hiding this comment

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

The bottom line of this is still that whatever we do with the tutorial, the output must look exactly like

Create a new empty text file, e.g. called `bot.ts`.
Your folder structure should now look like this:
```asciiart:no-line-numbers
.
├── bot.ts
├── node_modules/
├── package.json
├── package-lock.json
└── tsconfig.json
```
and the file contents need to be the same, too. I still do not really care how that is achieved, the point is that as long as the bun guide does not lead to the correct setup, then this cannot be merged.

@github-actions github-actions bot temporarily deployed to pull request October 15, 2024 15:41 Inactive
@MasedMSD
Copy link
Collaborator Author

I'll get into this page in more detail tomorrow

@KnorpelSenf
Copy link
Member

Remember to merge main in order to fix CI

@KnorpelSenf
Copy link
Member

Scratch that, it already happened

@KnorpelSenf
Copy link
Member

I even did it myself *facepalm*

@github-actions github-actions bot temporarily deployed to pull request October 15, 2024 19:31 Inactive
@github-actions github-actions bot temporarily deployed to pull request October 16, 2024 09:48 Inactive
@github-actions github-actions bot temporarily deployed to pull request October 16, 2024 09:58 Inactive
@github-actions github-actions bot temporarily deployed to pull request October 16, 2024 11:11 Inactive
Copy link
Member

@KnorpelSenf KnorpelSenf left a comment

Choose a reason for hiding this comment

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

This still does not create the same TS config as tsc --init if I understand this correctly

@MasedMSD
Copy link
Collaborator Author

Unfortunately we can't fix it. We will have to ask the user to change it manually every time.
But I don't understand the point of this, because everything works with the current tsconfig O.O

@KnorpelSenf
Copy link
Member

Yeah but I don't want to go through all the code examples and make sure that they compile even with the non-standard TS config that bun introduces. It can be fixed very easily by running tsc --init in the getting started guide.

@github-actions github-actions bot temporarily deployed to pull request November 4, 2024 07:28 Inactive
@KnorpelSenf
Copy link
Member

Is that in any way related to the current pull request?

@MasedMSD
Copy link
Collaborator Author

MasedMSD commented Nov 6, 2024

I mean that we should have some kind of tests to make sure that the bot and the code work. For example, as for the situation now, when we can't be sure that bun will pass all type-checks

@KnorpelSenf
Copy link
Member

That's why you have to test it, or adjust the TS config. But I'm beginning to repeat myself a little

@winstxnhdw
Copy link
Member

winstxnhdw commented Nov 6, 2024

I mean that we should have some kind of tests to make sure that the bot and the code work. For example, as for the situation now, when we can't be sure that bun will pass all type-checks

It’ll be hard to write integration tests for Bun and grammY because the existing test suite is in Deno. We’d have to spend a lot of time instrumenting some Docker CI test just specifically for Bun, and I am not sure if it’s worth the effort.

@KnorpelSenf
Copy link
Member

There's no need to actually run any tests, why do you think this? I can't follow

@github-actions github-actions bot temporarily deployed to pull request November 17, 2024 11:23 Inactive
@MasedMSD
Copy link
Collaborator Author

@KnorpelSenf still confused. We don't gonna use this?

@MasedMSD MasedMSD marked this pull request as draft November 20, 2024 17:05
@KnorpelSenf
Copy link
Member

I don't have strong opinions on what exactly you're gonna do. I just need you to make sure that the code examples are correct. It doesn't matter to me if you achieve this by making people use the setup that is known to work, or if you want to test all present and future code snippets against a new setup.

@github-actions github-actions bot temporarily deployed to pull request November 20, 2024 17:17 Inactive
@MasedMSD
Copy link
Collaborator Author

What I mean is that this command generates the typescript config that we use in all the examples. I think we should add Bun, but if there are any problems (which I'm not sure about at all, Bun is quite stable) we should deal with them as they come up.

@KnorpelSenf
Copy link
Member

So is there still a question? If yes then I don't understand it

@MasedMSD
Copy link
Collaborator Author

Yes.
We will merge this PR into main if we leave the command to generate the config we use everywhere else?
We should mention the Bun's support, because a lot of users in our community use it

@MasedMSD
Copy link
Collaborator Author

I mean, this PR has been hanging around for a long time and we need to do something about it. Either put it on hold or get on with it

@KnorpelSenf
Copy link
Member

I don't care if you use the command or not and I'm not opposed to mentioning bun support

@MasedMSD
Copy link
Collaborator Author

I'm not opposed to mentioning bun support

Great, I'll take care of that PR

@KnorpelSenf
Copy link
Member

I mean, this PR has been hanging around for a long time and we need to do something about it. Either put it on hold or get on with it

That's true, what was stopping you?

@KnorpelSenf
Copy link
Member

I'm not opposed to mentioning bun support

Great, I'll take care of that PR

Nice

@github-actions github-actions bot temporarily deployed to pull request November 21, 2024 15:59 Inactive
:::

#### Uploading Raw Binary Data

You can also send a `Buffer` object, or an iterator that yields `Buffer` objects.
On Deno, you can send `Blob` objects, too.
On Deno and Bun you can send `Blob` objects, too.
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
On Deno and Bun you can send `Blob` objects, too.
On Deno and Bun, you can send `Blob` objects, too.

@github-actions github-actions bot temporarily deployed to pull request January 16, 2025 19:11 Inactive
@github-actions github-actions bot temporarily deployed to pull request January 27, 2025 22:52 Inactive
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants