jagrosh / jagtag Goto Github PK
View Code? Open in Web Editor NEW๐ JagTag is a simple - yet powerful and customizable - interpretted text parsing language!
License: Apache License 2.0
๐ JagTag is a simple - yet powerful and customizable - interpretted text parsing language!
License: Apache License 2.0
[18:50:25] [ERROR] [LocalAudioTrackExecutor]: Error in playback of 9YU4gN42fkI
com.sedmelluq.discord.lavaplayer.tools.FriendlyException: Something broke when playing the track.
at com.sedmelluq.discord.lavaplayer.tools.ExceptionTools.wrapUnfriendlyExceptions(ExceptionTools.java:43)
at com.sedmelluq.discord.lavaplayer.track.playback.LocalAudioTrackExecutor.execute(LocalAudioTrackExecutor.java:103)
at com.sedmelluq.discord.lavaplayer.player.DefaultAudioPlayerManager.lambda$executeTrack$1(DefaultAudioPlayerManager.java:349)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
at java.lang.Thread.run(Thread.java:748)
Caused by: java.io.IOException: Received non-success response code 404
at com.sedmelluq.discord.lavaplayer.source.youtube.YoutubeSignatureCipherManager.validateResponseCode(YoutubeSignatureCipherManager.java:158)
at com.sedmelluq.discord.lavaplayer.source.youtube.YoutubeSignatureCipherManager.getCipherKeyFromScript(YoutubeSignatureCipherManager.java:143)
at com.sedmelluq.discord.lavaplayer.source.youtube.YoutubeSignatureCipherManager.resolveFormatUrl(YoutubeSignatureCipherManager.java:103)
at com.sedmelluq.discord.lavaplayer.source.youtube.YoutubeAudioTrack.loadBestFormatWithUrl(YoutubeAudioTrack.java:87)
at com.sedmelluq.discord.lavaplayer.source.youtube.YoutubeAudioTrack.process(YoutubeAudioTrack.java:42)
at com.sedmelluq.discord.lavaplayer.track.playback.LocalAudioTrackExecutor.execute(LocalAudioTrackExecutor.java:91)
... 4 common frames omitted
When using the following syntax I get a stack trace like the one below it.
{if:{argslen}|<|3|then:Please supply 4 words|else:Your 3rd word was: {arg:2}}
java.lang.ArithmeticException: / by zero
at com.jagrosh.jagtag.libraries.Arguments.lambda$getMethods$2(Arguments.java:67)
at com.jagrosh.jagtag.Method.parseComplex(Method.java:161)
at com.jagrosh.jagtag.Parser.parse(Parser.java:118)
at ml.duncte123.skybot.CommandManager.dispatchCommand(CommandManager.java:300)
at ml.duncte123.skybot.CommandManager.dispatchCommand(CommandManager.java:278)
at ml.duncte123.skybot.CommandManager.runCommand(CommandManager.java:270)
at ml.duncte123.skybot.BotListener.onGuildMessageReceived(BotListener.java:270)
at net.dv8tion.jda.core.hooks.ListenerAdapter.onEvent(ListenerAdapter.java:380)
at ml.duncte123.skybot.EventManager.handle(EventManager.java:69)
at net.dv8tion.jda.core.handle.MessageCreateHandler.handleInternally(MessageCreateHandler.java:95)
at net.dv8tion.jda.core.handle.SocketHandler.handle(SocketHandler.java:36)
at net.dv8tion.jda.core.requests.WebSocketClient.onDispatch(WebSocketClient.java:999)
at net.dv8tion.jda.core.requests.WebSocketClient.onEvent(WebSocketClient.java:904)
at net.dv8tion.jda.core.requests.WebSocketClient.handleEvent(WebSocketClient.java:883)
at net.dv8tion.jda.core.requests.WebSocketClient.onBinaryMessage(WebSocketClient.java:1037)
at com.neovisionaries.ws.client.ListenerManager.callOnBinaryMessage(ListenerManager.java:368)
at com.neovisionaries.ws.client.ReadingThread.callOnBinaryMessage(ReadingThread.java:270)
at com.neovisionaries.ws.client.ReadingThread.handleBinaryFrame(ReadingThread.java:990)
at com.neovisionaries.ws.client.ReadingThread.handleFrame(ReadingThread.java:749)
at com.neovisionaries.ws.client.ReadingThread.main(ReadingThread.java:108)
at com.neovisionaries.ws.client.ReadingThread.runMain(ReadingThread.java:64)
at com.neovisionaries.ws.client.WebSocketThread.run(WebSocketThread.java:45)
The arguments supplied are:
user: JDA User
channel: JDA TextChannel
guild: JDA Guill
splitargs: String[]
args: splitargs joined with |
as separator
On February 1st, 2022, this dependency will no longer be able to resolve for new projects. Please migrate from jcenter to maven central.
Working with lists of almost any sort is usually difficult in JagTag. Some very basic tools are provided with the Arguments Library, but other than this special case, most list/array usage is done via regex.
Right now, a single Parser can only parse in a synchronized format, and the Parser only has one Environment that is used during parsing. On the other hand, all Methods are immutable and would work perfectly fine in an asynchronous environment.
In most cases, JagTag is used just for text processing, and thus async processing is not needed (and would mean more overhead to create additional Environments). However, JagTag is perfectly viable for actions beyond text processing that may take more time (web requests, image manipulation), and forcing creation of a new Parser for each parse is unnecessary.
Allowing asynchronous parsing would mean re-using the Parser but doing one of the following:
Currently, the only way to interact with the Environment object (from outside Methods) is via the Parser#put and Parser#clear methods. Both of these are effectively 'setters' and don't allow access to any content within the Environment.
Currently the only way to get data back out of the Environment (after parsing) is to save a reference to an object, put it into the Environment, and then use the reference after parsing has occurred. However, it would be trivial to add Parser#get (or similar) to allow retrieving objects out of the Parser's Environment.
While this is not very useful for text processing (where generally only the final output matters), this would be highly useful for systems that use JagTag for parsing values for later use (ie configs) or to allow lazy creation of objects at parse-time.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.