star-39 / moe-sticker-bot

A Telegram bot that imports LINE/kakao stickers or creates/manages new sticker set.
GNU General Public License v3.0
272 stars 31 forks source link

convert: delegate failed `'dwebp' -pam '%i' -o '%o'' @ error/delegate.c/InvokeDelegate/1994 #23

Open Declarcall opened 1 year ago

Declarcall commented 1 year ago
$ ./moe-sticker-bot -bot_token=123456789:AAOTg3NjU0MzIxHMkJOVo3MTIzNDU2Nzg560 
Log level is set to: debug
DEBUG[0000] Warning: Log level below DEBUG might print sensitive information, including passwords. 
WARNING[0000] Following required executables not found!:   
WARNING[0000] exiv2                                        
WARNING[0000] Please install missing executables to your PATH, or some features will not work! 
INFO[0000] Attempting to initialize...                   token="123456789:AAOTg3NjU0MzIxHMkJOVo3MTIzNDU2Nzg560"
WARNING[0000] Not using database because --use_db is not set. 
INFO[0000] WebApp not enabled.                          
INFO[0000] Bot OK.                                       botName=Sticker_ImageBot dataDir=./Sticker_ImageBot_data
DEBUG[0011] User 123456789 entering command with message: /download 
DEBUG[0016] user 123456789 entered no session with message:  
DEBUG[0020] Sanitizing callback data...                  
DEBUG[0020] now: dsingle                                 
DEBUG[0020] user 123456789 entered no session with message: You can download this sticker or the whole sticker set, please select below.
您可以下載這個貼圖或者其所屬的整個貼圖包, 請選擇: 
DEBUG[0020] Downloading in pool: CAACAgUAAxkBAANqZMTSSR5AKaiUi0HBXGXp2x4c2g4AAhwBAAIVudck1jH2tQGV1RwvBA -> Sticker_ImageBot_data/c72192c0f493b8ad/mochadandan/mochadandan_😴 
WARNING[0021] imToPng ERROR: convert: unable to open image `Sticker_ImageBot_data/c72192c0f493b8ad/mochadandan/mochadandan_😴.webp': No such file or directory @ error/blob.c/OpenBlob/2960.
convert: delegate failed `'dwebp' -pam '%i' -o '%o'' @ error/delegate.c/InvokeDelegate/1994.
convert: unable to open file `/tmp/magick-jHFIDHwAydgW3teYSYJu73uAWM75xug0': No such file or directory @ error/constitute.c/ReadImage/620.
convert: no images defined `Sticker_ImageBot_data/c72192c0f493b8ad/mochadandan/mochadandan_😴.webp.png' @ error/convert.c/ConvertImageCommand/3229. 
WARNING[0021] download: error downloading sticker: chmod Sticker_ImageBot_data/c72192c0f493b8ad/mochadandan/mochadandan_😴.webp: no such file or directory 

Ubuntu 20.04 ARM64的机器, 调用 bot command /download 发了一张webp的sticker 产生的报错

Ubuntu 20.04 x86 的机器,将 GLIBC 升级到 2.32 以上,下载单张sticker正常,下载整个贴图包,报错如下:

...
...
WARNING[0020] ffToGif ERROR:
[paletteuse @ 0x7f626263b040] [Eval @ 0x7ffc8819cc80] Undefined constant or missing '(' in 'sierra3'
[paletteuse @ 0x7f626263b040] Unable to parse option value "sierra3"
[paletteuse @ 0x7f626263b040] [Eval @ 0x7ffc8819ccb0] Undefined constant or missing '(' in 'sierra3'
[paletteuse @ 0x7f626263b040] Unable to parse option value "sierra3"
[paletteuse @ 0x7f626263b040] Error setting option dither to value sierra3.
[Parsed_paletteuse_2 @ 0x56349a2f0b40] Error applying options to the filter.
[AVFilterGraph @ 0x56349a2eeb00] Error initializing filter 'paletteuse' with args 'dither=sierra3'
Error initializing complex filters.
Invalid argument 
...
...
star-39 commented 1 year ago

ubuntu 20.04 内建的ffmpeg版本太老了。

试试22.04的,或者用docker,或者下载静态编译的新版ffmpeg,比如 https://johnvansickle.com/ffmpeg/