I need help with jukebox

I have no idea how to create datapacks or code in java. So I am asking for some help. I would like a data pack that allows hoppers to insert and take out music discs from the jukebox, or something.

My only problem i can fore see is that the jukebox will kick out the disc early prior to it completing its play because of the way hoppers pull things automatically unless you lock them.

Pretty much want the jukebox to finally work in some way that is useful, allowing continuous play or looping play, or even just being able to create back ground music in certain builds.

I’ve been looking for this for years. Not even a lot of mods do things for the jukebox. Its like the forgotten block, besides cauldrons and poisonous potatoes.