now it handles a file and starts getting the version and type fields