What are the requirements for filing a writ petition?