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

Bump telegraf from 3.36.0 to 4.0.1 #104

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

dependabot-preview[bot]
Copy link
Contributor

Bumps telegraf from 3.36.0 to 4.0.1.

Release notes

Sourced from telegraf's releases.

4.0 Major Release

Changelog Telegraf 4.0

General

  • Port to TypeScript
  • Update to Bot API 5.0
  • Scenes now live in their own namespace called Scenes
  • Allow cancelling requests via AbortController
  • Add attachmentAgent option to provide an agent that is used for fetching files from the web before they are sent to Telegram (previously done through the same agent as used to connect to Telegram itself)

Apart from updating Telegraf to full Telegram Bot API 5.0 support, the most significant improvement is that we now have a code base that is written 100 % in TypeScript, which more or less required a rewrite of the complete library. Previously, the library was written in JavaScript and had a few type annotations to the side, but they were often incorrect or missing.

In working on the 4.0 release, we created type coverage of the complete Telegram Bot API. The benefit is that your editor can now autocomplete accross every single field in every single method or entity. Those who ever tried it out can confirm that this improves the development experience by an order of magnitude.

Note that this update brings 9 months worth of improvements, so while we did our best to summarise all important changes, it's possible that we forgot some!

Composer

  • Add Composer.guard
  • Deprecate static Composer.mount, prefer static Composer.on
  • Make Composer.entity and Composer.match private
  • Remove Composer.catchAll and Composer.safePassThru
  • Catch errors of both branches of Composer.fork
  • Listen to forwards using on('forward_date'), no longer on('forward')

Context

  • Make ctx.botInfo required, i.e. is is always available
  • Make ctx.state readonly
  • Add ctx.senderChat, ctx.unpinAllChatMessages, and ctx.copyMessage
  • ctx.deleteMessage no longer works for edited messages, channel posts, or edited channel posts
  • Remove ctx.updateSubTypes

Extra

Extra is removed entirely. You can now just specify any options directly, without having to create an Extra instance before.

Markup

Markup is largely reworked. Please check out the new documentation about Markup, this is much easier than trying to understand the differences between the old and the new version. The TypeScript autocompletion should help you a lot in case you have to change something about your code.

The main thing to watch out for is that all buttons (keyboard buttons and inline buttons) are now created via Markup.button.url and its siblings, no longer via Markup.urlButton.

Commits

Dependabot compatibility score

Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


Dependabot commands and options

You can trigger Dependabot actions by commenting on this PR:

  • @dependabot rebase will rebase this PR
  • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
  • @dependabot merge will merge this PR after your CI passes on it
  • @dependabot squash and merge will squash and merge this PR after your CI passes on it
  • @dependabot cancel merge will cancel a previously requested merge and block automerging
  • @dependabot reopen will reopen this PR if it is closed
  • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
  • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
  • @dependabot use these labels will set the current labels as the default for future PRs for this repo and language
  • @dependabot use these reviewers will set the current reviewers as the default for future PRs for this repo and language
  • @dependabot use these assignees will set the current assignees as the default for future PRs for this repo and language
  • @dependabot use this milestone will set the current milestone as the default for future PRs for this repo and language
  • @dependabot badge me will comment on this PR with code to add a "Dependabot enabled" badge to your readme

Additionally, you can set the following in your Dependabot dashboard:

  • Update frequency (including time of day and day of week)
  • Pull request limits (per update run and/or open at any time)
  • Out-of-range updates (receive only lockfile updates, if desired)
  • Security updates (receive only security updates, if desired)

Bumps [telegraf](https://github.com/telegraf/telegraf) from 3.36.0 to 4.0.1.
- [Release notes](https://github.com/telegraf/telegraf/releases)
- [Commits](telegraf/telegraf@3.36.0...v4.0.1)

Signed-off-by: dependabot-preview[bot] <[email protected]>
@dependabot-preview dependabot-preview bot added the dependencies Pull requests that update a dependency file label Jan 14, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
dependencies Pull requests that update a dependency file
Projects
None yet
Development

Successfully merging this pull request may close these issues.

0 participants