Git Product home page Git Product logo

book's People

Contributors

demndevel avatar dependabot[bot] avatar falcevor avatar fedorus avatar karb0f0s avatar mihazupan avatar poulad avatar smartis2812 avatar tuscen avatar vladden4 avatar wiz0u avatar wouterjanson avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

book's Issues

Possible small error in the documentation

I was following this tutorial I found that there is a chunk of code which shows errors when pasting it into a newly created project with the latest packages.

The code:

botClient.StartReceiving(
    new DefaultUpdateHandler(HandleUpdateAsync, HandleErrorAsync), // < Error 1
    cts.Token);                                                    // < Error 2

// Error 1:
// cannot convert from 'Telegram.Bot.Extensions.Polling.DefaultUpdateHandler' to 
// 'System.Func<Telegram.Bot.ITelegramBotClient, Telegram.Bot.Types.Update, System.Threading.CancellationToken, System.Threading.Tasks.Task>'
// [MyBot]csharp(CS1503)

// Error2:
// cannot convert from 'System.Threading.CancellationToken' to
// 'System.Func<Telegram.Bot.ITelegramBotClient, System.Exception, System.Threading.CancellationToken, System.Threading.Tasks.Task>'
// [MyBot]csharp(CS1503)

Solved it this way

botClient.StartReceiving(
    HandleUpdateAsync,
    HandleErrorAsync,
    null,
    cts.Token);

Environment data

Nugets:

  • Telegram.Bot 17.0.0-alpha.3
  • Telegram.Bot.Extensions.Polling 1.0.0-alpha.1

.NET Version: net5.0

IDE: VS2019 Version 16.11.2

The output.html.google-analytics field has been deprecated. It will be removed in a future release.

mdBook 0.4.19 gives this warning during build:

[WARN] (mdbook::book): The output.html.google-analytics field has been deprecated; it will be removed in a future release.
Consider placing the appropriate site tag code into the theme/head.hbs file instead.
The tracking code may be found in the Google Analytics Admin page.

According to documentation

google-analytics: This field has been deprecated and will be removed in a future release. Use the theme/head.hbs file to add the appropriate Google Analytics code instead.

mdBook guide on Themes

Topic: Games

Section: Intermediate

Topics to cover may include:

  • Intro to Telegram games
  • Creating a game
  • Sending the game to chat
  • High scores

Topic: Logging

Section: Logging

Topics to clover may include:

  • Logging to common sinks/providers (stdout, .NET logging providers, etc.)
  • Configuration options for controlling log verbosity/secret-scrubbing, if any

See also: TelegramBots/Telegram.Bot#1047

Topic: Text Formatting

Section: Beginner

Topics to cover may include:

  • Using parse_mode for message text and captions
  • Markdown-style formatting
  • HTML-style formatting
  • Message/caption entities

Fix release pipeline

We should fix our release pipeline and replace Travis CI with another CI/CD solution.

Topic: Chats

Section: Beginner

Topics to cover may include:

  • Different kinds of chats: private, group, supergroup, channel
  • Using chat identifiers(IDs and usernames) in methods(e.g. sendMessage)
  • Receiving updates from Channels vs. other chats

Topic: Service Messages

Section: Intermediate

Topics to cover may include:

  • Identifying each kind of service message briefly
  • Processing a service message update

Add a logo

Hi,

What should be the code to display a logo instead of the title?

Thanks for your help.

Topic: Inline Keyboard

Section: Beginner
Sub section: Reply Markup

Topics to cover may include:

  • A brief introduction to inline keyboards
  • Creating inline keyboard buttons
  • Switching to inline queries
  • Pay button (and a link to the payments page)
  • Receiving callback query (and a link to the callback queries page)
  • Receiving game callback query (and a link to the games page)

example-bot.md invalid using of Telegram.Bot.Polling

I'm try to use v17 package of the TGBot .NET API Client.

As I understand it, the Telegram.Bot.Polling space has been moved to a separate package
https://github.com/TelegramBots/Telegram.Bot.Extensions.Polling

I've just get code from:
https://telegrambots.github.io/book/1/example-bot.html
image

It is necessary to indicate this on the page "example-bot.md", as well as specify that you need to add an additional package:
dotnet add package Telegram.Bot.Extensions.Polling

broken voice message spectogram

I send a voice message with API but the spectrogram is flat. The audio file is .ogg and OPUS library.

` await using Stream stream = System.IO.File.OpenRead(@"C:\Users\magrega\YandexDisk\проги\audio.ogg");

await client.SendVoiceAsync(
chatId: message.Chat.Id,
voice: stream!,
duration: 1097);`

image

More pages to add

Add pages to the book:

  • Different chats(beginner): private, group, supergroup, channel. how to pass names
  • Chat migration update
  • Channel Chats: whatever is different about them e.g. field on Message object
  • ChatId: describe how to work with ChatId. how to pass channel names as string.
  • Forwarding messages from diff chats
  • Inviting users to chat and adding chat member updates

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.