It is great that you solved the challenge, but instead of posting your full working solution, it is best to stay focused on answering the original poster’s question(s) and help guide them with hints and suggestions to solve their own issues with the challenge.
We are trying to cut back on the number of spoiler solutions found on the forum and instead focus on helping other campers with their questions and definitely not posting full working solutions.
As recommended i will encourage you to do more research on it, to make it easier for you, let me give you some hints.
See the key as a word or phrase that determines the shift applied to each letter in the message.
Then see the key_index as a variable used in keeping track of the current position in the key string. For better understanding please use chatGPT to look for demonstration, illustration or usage of those two in a more simpler code as that will aid your understanding.