Skip to content
Snippets Groups Projects
Commit c72fd22a authored by Samuel GAIST's avatar Samuel GAIST Committed by Samuel GAIST
Browse files

[experiments][serializers] Fix fork_of field type

It was a JSONField however it should be a CharField.
It worked because the DRF JSONField does not actually
do type checks so a string can be dumped and it passes
the validation successfully.
parent c00e509c
No related branches found
No related tags found
No related merge requests found
...@@ -54,7 +54,7 @@ from .models import Experiment, Block ...@@ -54,7 +54,7 @@ from .models import Experiment, Block
class ExperimentCreationSerializer(serializers.ModelSerializer): class ExperimentCreationSerializer(serializers.ModelSerializer):
declaration = beat_fields.JSONField() declaration = beat_fields.JSONField()
description = serializers.CharField(required=False, allow_blank=True) description = serializers.CharField(required=False, allow_blank=True)
fork_of = beat_fields.JSONField(required=False) fork_of = serializers.CharField(required=False)
toolchain = serializers.CharField() toolchain = serializers.CharField()
class Meta: class Meta:
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment