Random unexplained modulescript bug where some functions won't show up in scripts

I’m relatively new to using modulescripts, and just today I’ve had this peculiar error where certain functions aren’t being recognised.

I cleared everything and started from scratch just to see if it was my terrible scripting skills.
I knew I was using . instead of :, as well

local testModule = {}

testModule.Test = function(text: string)
	print(text)
end

return testModule

I fixed this by making a new modulescript, and copying all the code and children into it.
But I still would like to know how this bug happened in the first place and how I can avoid it in the future.

Thanks!

I think you might’ve forgotten to add require()

Nope, other functions were showing up. It could’ve just been some random bug with no real reason, but I hope that’s not the case.

This is my first time seeing a weird function appearance. Is it available in studio?
If yes then the the cause might be something else.

If you were testing in the command bar, it’s because it loads a copy and retains that old copy, reloading the module by pressing Ctrl + R only works once for some odd reason. I recommend testing during a playtest instead.