I think the biggest danger here is that you can severely underestimate the time needed to complete it, both in terms of the learning curve and of how much the project itself may be worth. The project may take 2x just because of the learning curve and needing to build scaffolding you would otherwise have, so unless it's super niche you may consider using a lower hourly rate to account for the learning curve - or don't, because you will probably underestimate it anyway.
I don't think I would do it without making a related side project first where there's no time pressure and can pause anytime - and I don't really care if it takes 300h or 900h because it's a side project. I don't even have to finish it.