A fully-searchable and accessible archive of court data including growing repositories of opinions, oral arguments, judges, judicial financial records, and federal filings.
This PR addresses the dependency of the make_dev_data command on AWS credentials for creating dummy database entries.
The docket and audio factories were creating fake files using the FileField class, which triggered unnecessary S3 uploads. To address this, the FileField is removed from both factories and post-generation hooks are implemented. These hooks attach a stub file to the fake object, ensuring that factories still return objects with files when requested and allowing developers to use familiar declarations like filepath__data for testing purposes.
This refinement maintains compatibility and flexibility for factory usage
This PR addresses the dependency of the
make_dev_data
command on AWS credentials for creating dummy database entries.The
docket
andaudio
factories were creating fake files using theFileField
class, which triggered unnecessary S3 uploads. To address this, theFileField
is removed from both factories and post-generation hooks are implemented. These hooks attach a stub file to the fake object, ensuring that factories still return objects with files when requested and allowing developers to use familiar declarations likefilepath__data
for testing purposes.This refinement maintains compatibility and flexibility for factory usage