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

Not stripping url arguments for discord images #51

Closed
oskarbukovsky opened this issue Jul 15, 2024 · 12 comments
Closed

Not stripping url arguments for discord images #51

oskarbukovsky opened this issue Jul 15, 2024 · 12 comments
Labels
🔩enhancement New feature or request

Comments

@oskarbukovsky
Copy link

It looks like chatimage ignore parameters in url and for discord images it doesnt work
image

@kitUIN
Copy link
Owner

kitUIN commented Jul 15, 2024

could you give me raw url?

@oskarbukovsky
Copy link
Author

oskarbukovsky commented Jul 18, 2024

Examples:

image
https://media.discordapp.net/attachments/1243302804802633728/1263505132276940860/image.png?ex=669a7a5a&is=669928da&hm=9ee4b06fc189006b7a81e9730649a4cea750cc87d12149ec18008466c5431512&=&format=webp&quality=lossless

image
https://cdn.discordapp.com/attachments/1243302804802633728/1263506347371135048/IMG_20240718_164152.jpg?ex=669a7b7c&is=669929fc&hm=05e84327f7171b3ce5fe3b5c42e1ecc7a74bc50988228faef40e8a75e6b08cf4&

image

image
The last is a result of /chatimage url https://media.discordapp.net/attachments/1243302804802633728/1263505132276940860/image.png?ex=669a7a5a&is=669928da&hm=9ee4b06fc189006b7a81e9730649a4cea750cc87d12149ec18008466c5431512&=&format=webp&quality=lossless

@kitUIN
Copy link
Owner

kitUIN commented Jul 19, 2024

minecraft version is ?

also,we don't support .webp image

@oskarbukovsky
Copy link
Author

oskarbukovsky commented Jul 19, 2024

Minecraft 1.20.1
Forge 47.3.1
ChatImage 1.2.4+1.20.1+forge

Ok, but one is .jpg, also why not?

@kitUIN
Copy link
Owner

kitUIN commented Jul 19, 2024

now, not support url with parameters
a better way is to use CICode
maybe it has a bug

@oskarbukovsky
Copy link
Author

Any chance to adding suport for parameters to mod? We are using discordsrv and it will be super cool to not switch windows and enjoy image content ingame.

@kitUIN
Copy link
Owner

kitUIN commented Jul 19, 2024

It is very difficult to determine the valid length of the url when the url with parameters is in a sentence.

A better way is for discordsrv to support CICode usage

@oskarbukovsky
Copy link
Author

Why just not to look at url as one word from http/etc. and try first if it is a valid image response else use current behavior?

@oskarbukovsky
Copy link
Author

oskarbukovsky commented Jul 19, 2024

I'll try to make feature suggestion od discordsrv github, but i think not that much people will use CICode functionality. So probably time to find some workaround on discord to download and upload images elsewhere and send link to them into channel as bot, idk :(

//Why am i stupid, it will not help on discordsrv supporting cicode

@kitUIN
Copy link
Owner

kitUIN commented Jul 19, 2024

I'll try to implement a url with parameters

@kitUIN kitUIN added the 🔩enhancement New feature or request label Jul 19, 2024
@oskarbukovsky
Copy link
Author

After 2 days learning discordjs from scratch, it's working what i needed 😅
Such a pain, but good excuse to learn something new

@kitUIN
Copy link
Owner

kitUIN commented Dec 5, 2024

Support in 1.3.0

@kitUIN kitUIN closed this as completed Dec 5, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🔩enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants