I'm a bit in a similar boat: My wife's department (university) asked me for a 'little' favor, which I programmed in Java to get back into programming after ~4 years of being a stay-at-home dad. After finishing the prototype in 2019, we made the life-changing decision to focus on making it a program that we want to sell. Decided to go C++ and Electron, but with the corona virus and me taking forever to learn all the skills, I still haven't released it as of now. :(
However, I'm still working on it and hope to release it in time for a conference that I signed up for, so this will be a 'make or break' year for me.
They were not part of the development and have no financial involvement. Hmm, now that I think about it, I am going to the conference as affiliate of the university... :/
All it would take is that they specified what to build and claimed that you never sent them an invoice but that it was work for hire regardless.
Remember that they are much bigger than you and if there is money involved they may well act irrational, and as a smaller party this can be very unnerving and costly.
Best to make sure that you have it spelled out that the code is yours, stick a big fat copyright sign on top of it and if possible get them on the record that it is clear that the rights belong to you. When in doubt, consult and IP lawyer.
Again, thanks for taking the time to write! It is certainly good advice!
Luckily the situation is in this specific case is that I don't have to worry about it - I'm 100% sure of it. My nightmares come more from the fear that I will finish one day and find out that I took too long and I missed my window of opportunity.
However, I'm still working on it and hope to release it in time for a conference that I signed up for, so this will be a 'make or break' year for me.