When importing media subtitles, if a subtitle has already existed in the system, trying to import the new ones throws a Error invoking subclass method error when trying to fetch or update the existing entry in the database for the subtitle. Adding the --override flag to the command does not do anything.
The error is being produced by a duplicate entry error from the database despite using the entity manager's merge and persist function.
Jul 03 17:02:13 media plexbot-runner[1362]: Caused by: org.mariadb.jdbc.internal.util.exceptions.MariaDbSqlException: Duplicate entry 'The Tomorrow War (2021) {imdb-tt9777666}.spa.srt' for key 'UK_6977c78sa0h7m38si42c2mh77'
Jul 03 17:02:13 media plexbot-runner[1362]: at org.mariadb.jdbc.internal.protocol.AbstractQueryProtocol.exceptionWithQuery(AbstractQueryProtocol.java:194)
Jul 03 17:02:13 media plexbot-runner[1362]: at org.mariadb.jdbc.internal.protocol.AbstractQueryProtocol.exceptionWithQuery(AbstractQueryProtocol.java:177)
Jul 03 17:02:13 media plexbot-runner[1362]: at org.mariadb.jdbc.internal.protocol.AbstractQueryProtocol.executeQuery(AbstractQueryProtocol.java:321)
Jul 03 17:02:13 media plexbot-runner[1362]: at org.mariadb.jdbc.ClientSidePreparedStatement.executeInternal(ClientSidePreparedStatement.java:220)
Jul 03 17:02:13 media plexbot-runner[1362]: ... 63 more
Jul 03 17:02:13 media plexbot-runner[1362]: Caused by: java.sql.SQLException: Duplicate entry 'The Tomorrow War (2021) {imdb-tt9777666}.spa.srt' for key 'UK_6977c78sa0h7m38si42c2mh77'
Jul 03 17:02:13 media plexbot-runner[1362]: at org.mariadb.jdbc.internal.protocol.AbstractQueryProtocol.readErrorPacket(AbstractQueryProtocol.java:1694)
Jul 03 17:02:13 media plexbot-runner[1362]: at org.mariadb.jdbc.internal.protocol.AbstractQueryProtocol.readPacket(AbstractQueryProtocol.java:1556)
Jul 03 17:02:13 media plexbot-runner[1362]: at org.mariadb.jdbc.internal.protocol.AbstractQueryProtocol.getResult(AbstractQueryProtocol.java:1519)
Jul 03 17:02:13 media plexbot-runner[1362]: at org.mariadb.jdbc.internal.protocol.AbstractQueryProtocol.executeQuery(AbstractQueryProtocol.java:318)
Jul 03 17:02:13 media plexbot-runner[1362]: ... 64 more
Jul 03 17:02:13 media plexbot-runner[1362]: 2021-07-03 17:02:13,690 WARN [org.hib.eng.jdb.spi.SqlExceptionHelper] (executor-thread-11) SQL Error: 1062, SQLState: 23000
Jul 03 17:02:13 media plexbot-runner[1362]: 2021-07-03 17:02:13,690 ERROR [org.hib.eng.jdb.spi.SqlExceptionHelper] (executor-thread-11) (conn=1057571) Duplicate entry 'The Tomorrow War (2021) {imdb-tt9777666}.eng.sdh.srt' for key 'UK_6977c78sa0h7m38si42c2mh77'
When importing media subtitles, if a subtitle has already existed in the system, trying to import the new ones throws a
Error invoking subclass method
error when trying to fetch or update the existing entry in the database for the subtitle. Adding the--override
flag to the command does not do anything.The error is being produced by a duplicate entry error from the database despite using the entity manager's merge and persist function.