prompt: We are currently solving the following issue within our repository. Here is the issue text:
  --- BEGIN ISSUE ---
  need to have fields of chant and sequence models synced 
  or else, it'll lead to errors, such as not being able to retrieve chants from /chant-search
  please fix
  
  --- END ISSUE ---
  
  Below are some code segments, each from a relevant file. One or more of these files may contain bugs.
  --- BEGIN FILES ---
  Path: `django/cantusdb_project/main_app/models/sequence.py`
  Content:
  ```
  1 from django.contrib.postgres.search import SearchVectorField
  2 from django.db import models
  3 from main_app.models import BaseModel
  4 from users.models import User
  5 
  6 
  7 class Sequence(BaseModel):
  8     visible_status = models.CharField(max_length=1, blank=True, null=True)
  9     title = models.CharField(blank=True, null=True, max_length=255)
  10     incipit = models.CharField(blank=True, null=True, max_length=255)
  11     siglum = models.CharField(blank=True, null=True, max_length=255)
  12     folio = models.CharField(blank=True, null=True, max_length=255)
  13     sequence = models.CharField(blank=True, null=True, max_length=255)
  14     genre = models.ForeignKey("Genre", blank=True, null=True, on_delete=models.PROTECT)
  15     rubrics = models.CharField(blank=True, null=True, max_length=255)
  16     analecta_hymnica = models.CharField(blank=True, null=True, max_length=255)
  17     indexing_notes = models.TextField(blank=True, null=True)
  18     date = models.CharField(blank=True, null=True, max_length=255)
  19     col1 = models.CharField(blank=True, null=True, max_length=255)
  20     col2 = models.CharField(blank=True, null=True, max_length=255)
  21     col3 = models.CharField(blank=True, null=True, max_length=255)
  22     ah_volume = models.CharField(blank=True, null=True, max_length=255)
  23     source = models.ForeignKey(
  24         "Source", on_delete=models.PROTECT, blank=True, null=True
  25     )
  26     cantus_id = models.CharField(blank=True, null=True, max_length=255)
  27     image_link = models.URLField(blank=True, null=True)
  28     json_info = models.JSONField(null=True, blank=True)
  29 
  30     # The following fields (dummy fields) are just for harmonizing the chant and sequence models to have the same fields
  31     # They should never be populated or displayed
  32     # The order of the fields must be exactly the same between the seq and chant models
  33     marginalia = models.CharField(max_length=63, null=True, blank=True)
  34     sequence_number = models.PositiveIntegerField(
  35         help_text='Each folio starts with "1"', null=True, blank=True
  36     )
  37     office = models.ForeignKey(
  38         "Office", on_delete=models.PROTECT, null=True, blank=True
  39     )
  40     position = models.CharField(max_length=63, null=True, blank=True)
  41     feast = models.ForeignKey("Feast", on_delete=models.PROTECT, null=True, blank=True)
  42     mode = models.CharField(max_length=63, null=True, blank=True)
  43     differentia = models.CharField(blank=True, null=True, max_length=63)
  44     finalis = models.CharField(blank=True, null=True, max_length=63)
  45     extra = models.CharField(blank=True, null=True, max_length=63)
  46     chant_range = models.CharField(
  47         blank=True,
  48         null=True,
  49         help_text='Example: "1-c-k-4". Optional field',
  50         max_length=255,
  51     )
  52     addendum = models.CharField(blank=True, null=True, max_length=255)
  53     manuscript_full_text_std_spelling = models.TextField(
  54         help_text="Manuscript full text with standardized spelling. Enter the words "
  55         "according to the manuscript but normalize their spellings following "
  56         "Classical Latin forms. Use upper-case letters for proper nouns, "
  57         'the first word of each chant, and the first word after "Alleluia" for '
  58         "Mass Alleluias. Punctuation is omitted.",
  59         null=True,
  60         blank=True,
  61     )
  62     manuscript_full_text_std_proofread = models.BooleanField(blank=True, null=True)
  63     manuscript_full_text = models.TextField(
  64         help_text="Enter the wording, word order and spellings as found in the manuscript"
  65         ", with abbreviations resolved to standard words. Use upper-case letters as found"
  66         " in the source. Retain “Xpistum” (Christum), “Ihc” (Jesus) and other instances of "
  67         "Greek characters with their closest approximations of Latin letters. Some punctuation"
  68         " signs and vertical dividing lines | are employed in this field. Repetenda and psalm "
  69         "cues can also be recorded here. For more information, contact Cantus Database staff.",
  70         null=True,
  71         blank=True,
  72     )
  73     manuscript_full_text_proofread = models.BooleanField(blank=True, null=True)
  74     manuscript_syllabized_full_text = models.TextField(null=True, blank=True)
  75     volpiano = models.TextField(null=True, blank=True)
  76     volpiano_proofread = models.BooleanField(blank=True, null=True)
  77     volpiano_notes = models.TextField(null=True, blank=True)
  78     volpiano_intervals = models.TextField(null=True, blank=True)
  79     # volpiano_intervals = ArrayField(base_field=models.IntegerField(), null=True, blank=True)
  80     cao_concordances = models.CharField(blank=True, null=True, max_length=63)
  81     proofread_by = models.ForeignKey(
  82         User, on_delete=models.PROTECT, null=True, blank=True
  83     )
  84     melody_id = models.CharField(blank=True, null=True, max_length=63)
  85     search_vector = SearchVectorField(null=True, editable=False)
  86     content_structure = models.CharField(
  87         blank=True,
  88         null=True,
  89         max_length=64,
  90         help_text="Additional folio number field, if folio numbers appear on the leaves but are not in the 'binding order'.",
  91     )
  92
  ```
  --- END FILES ---
  
  Please first localize the bug based on the issue statement, and then generate a patch according to the `git diff` format fenced by three backticks.
  
  Here is an example:
  
  ```diff
  diff --git a/examples/server_async.py b/examples/server_async.py
  --- a/examples/server_async.py
  +++ b/examples/server_async.py
  @@ -313,4 +313,4 @@
   
   
   if __name__ == "__main__":
  -    asyncio.run(run_async_server("."), debug=True)
  +    asyncio.run(run_async_server(), debug=True)
  diff --git a/examples/server_sync.py b/examples/server_sync.py
  --- a/examples/server_sync.py
  +++ b/examples/server_sync.py
  @@ -313,5 +313,5 @@
   
   
   if __name__ == "__main__":
  -    server = run_sync_server(".")
  +    server = run_sync_server()
       server.shutdown()
  
  ```
  
golden_diff: diff --git a/django/cantusdb_project/main_app/models/sequence.py b/django/cantusdb_project/main_app/models/sequence.py
  --- a/django/cantusdb_project/main_app/models/sequence.py
  +++ b/django/cantusdb_project/main_app/models/sequence.py
  @@ -41,6 +41,7 @@
       feast = models.ForeignKey("Feast", on_delete=models.PROTECT, null=True, blank=True)
       mode = models.CharField(max_length=63, null=True, blank=True)
       differentia = models.CharField(blank=True, null=True, max_length=63)
  +    differentia_id = models.CharField(blank=True, null=True, max_length=12)
       finalis = models.CharField(blank=True, null=True, max_length=63)
       extra = models.CharField(blank=True, null=True, max_length=63)
       chant_range = models.CharField(
  
verification_info: {"golden_diff": "diff --git a/django/cantusdb_project/main_app/models/sequence.py b/django/cantusdb_project/main_app/models/sequence.py\n--- a/django/cantusdb_project/main_app/models/sequence.py\n+++ b/django/cantusdb_project/main_app/models/sequence.py\n@@ -41,6 +41,7 @@\n     feast = models.ForeignKey(\"Feast\", on_delete=models.PROTECT, null=True, blank=True)\n     mode = models.CharField(max_length=63, null=True, blank=True)\n     differentia = models.CharField(blank=True, null=True, max_length=63)\n+    differentia_id = models.CharField(blank=True, null=True, max_length=12)\n     finalis = models.CharField(blank=True, null=True, max_length=63)\n     extra = models.CharField(blank=True, null=True, max_length=63)\n     chant_range = models.CharField(\n", "issue": "need to have fields of chant and sequence models synced \nor else, it'll lead to errors, such as not being able to retrieve chants from /chant-search\r\nplease fix\n", "before_files": [{"content": "from django.contrib.postgres.search import SearchVectorField\nfrom django.db import models\nfrom main_app.models import BaseModel\nfrom users.models import User\n\n\nclass Sequence(BaseModel):\n    visible_status = models.CharField(max_length=1, blank=True, null=True)\n    title = models.CharField(blank=True, null=True, max_length=255)\n    incipit = models.CharField(blank=True, null=True, max_length=255)\n    siglum = models.CharField(blank=True, null=True, max_length=255)\n    folio = models.CharField(blank=True, null=True, max_length=255)\n    sequence = models.CharField(blank=True, null=True, max_length=255)\n    genre = models.ForeignKey(\"Genre\", blank=True, null=True, on_delete=models.PROTECT)\n    rubrics = models.CharField(blank=True, null=True, max_length=255)\n    analecta_hymnica = models.CharField(blank=True, null=True, max_length=255)\n    indexing_notes = models.TextField(blank=True, null=True)\n    date = models.CharField(blank=True, null=True, max_length=255)\n    col1 = models.CharField(blank=True, null=True, max_length=255)\n    col2 = models.CharField(blank=True, null=True, max_length=255)\n    col3 = models.CharField(blank=True, null=True, max_length=255)\n    ah_volume = models.CharField(blank=True, null=True, max_length=255)\n    source = models.ForeignKey(\n        \"Source\", on_delete=models.PROTECT, blank=True, null=True\n    )\n    cantus_id = models.CharField(blank=True, null=True, max_length=255)\n    image_link = models.URLField(blank=True, null=True)\n    json_info = models.JSONField(null=True, blank=True)\n\n    # The following fields (dummy fields) are just for harmonizing the chant and sequence models to have the same fields\n    # They should never be populated or displayed\n    # The order of the fields must be exactly the same between the seq and chant models\n    marginalia = models.CharField(max_length=63, null=True, blank=True)\n    sequence_number = models.PositiveIntegerField(\n        help_text='Each folio starts with \"1\"', null=True, blank=True\n    )\n    office = models.ForeignKey(\n        \"Office\", on_delete=models.PROTECT, null=True, blank=True\n    )\n    position = models.CharField(max_length=63, null=True, blank=True)\n    feast = models.ForeignKey(\"Feast\", on_delete=models.PROTECT, null=True, blank=True)\n    mode = models.CharField(max_length=63, null=True, blank=True)\n    differentia = models.CharField(blank=True, null=True, max_length=63)\n    finalis = models.CharField(blank=True, null=True, max_length=63)\n    extra = models.CharField(blank=True, null=True, max_length=63)\n    chant_range = models.CharField(\n        blank=True,\n        null=True,\n        help_text='Example: \"1-c-k-4\". Optional field',\n        max_length=255,\n    )\n    addendum = models.CharField(blank=True, null=True, max_length=255)\n    manuscript_full_text_std_spelling = models.TextField(\n        help_text=\"Manuscript full text with standardized spelling. Enter the words \"\n        \"according to the manuscript but normalize their spellings following \"\n        \"Classical Latin forms. Use upper-case letters for proper nouns, \"\n        'the first word of each chant, and the first word after \"Alleluia\" for '\n        \"Mass Alleluias. Punctuation is omitted.\",\n        null=True,\n        blank=True,\n    )\n    manuscript_full_text_std_proofread = models.BooleanField(blank=True, null=True)\n    manuscript_full_text = models.TextField(\n        help_text=\"Enter the wording, word order and spellings as found in the manuscript\"\n        \", with abbreviations resolved to standard words. Use upper-case letters as found\"\n        \" in the source. Retain \u201cXpistum\u201d (Christum), \u201cIhc\u201d (Jesus) and other instances of \"\n        \"Greek characters with their closest approximations of Latin letters. Some punctuation\"\n        \" signs and vertical dividing lines | are employed in this field. Repetenda and psalm \"\n        \"cues can also be recorded here. For more information, contact Cantus Database staff.\",\n        null=True,\n        blank=True,\n    )\n    manuscript_full_text_proofread = models.BooleanField(blank=True, null=True)\n    manuscript_syllabized_full_text = models.TextField(null=True, blank=True)\n    volpiano = models.TextField(null=True, blank=True)\n    volpiano_proofread = models.BooleanField(blank=True, null=True)\n    volpiano_notes = models.TextField(null=True, blank=True)\n    volpiano_intervals = models.TextField(null=True, blank=True)\n    # volpiano_intervals = ArrayField(base_field=models.IntegerField(), null=True, blank=True)\n    cao_concordances = models.CharField(blank=True, null=True, max_length=63)\n    proofread_by = models.ForeignKey(\n        User, on_delete=models.PROTECT, null=True, blank=True\n    )\n    melody_id = models.CharField(blank=True, null=True, max_length=63)\n    search_vector = SearchVectorField(null=True, editable=False)\n    content_structure = models.CharField(\n        blank=True,\n        null=True,\n        max_length=64,\n        help_text=\"Additional folio number field, if folio numbers appear on the leaves but are not in the 'binding order'.\",\n    )\n", "path": "django/cantusdb_project/main_app/models/sequence.py"}], "after_files": [{"content": "from django.contrib.postgres.search import SearchVectorField\nfrom django.db import models\nfrom main_app.models import BaseModel\nfrom users.models import User\n\n\nclass Sequence(BaseModel):\n    visible_status = models.CharField(max_length=1, blank=True, null=True)\n    title = models.CharField(blank=True, null=True, max_length=255)\n    incipit = models.CharField(blank=True, null=True, max_length=255)\n    siglum = models.CharField(blank=True, null=True, max_length=255)\n    folio = models.CharField(blank=True, null=True, max_length=255)\n    sequence = models.CharField(blank=True, null=True, max_length=255)\n    genre = models.ForeignKey(\"Genre\", blank=True, null=True, on_delete=models.PROTECT)\n    rubrics = models.CharField(blank=True, null=True, max_length=255)\n    analecta_hymnica = models.CharField(blank=True, null=True, max_length=255)\n    indexing_notes = models.TextField(blank=True, null=True)\n    date = models.CharField(blank=True, null=True, max_length=255)\n    col1 = models.CharField(blank=True, null=True, max_length=255)\n    col2 = models.CharField(blank=True, null=True, max_length=255)\n    col3 = models.CharField(blank=True, null=True, max_length=255)\n    ah_volume = models.CharField(blank=True, null=True, max_length=255)\n    source = models.ForeignKey(\n        \"Source\", on_delete=models.PROTECT, blank=True, null=True\n    )\n    cantus_id = models.CharField(blank=True, null=True, max_length=255)\n    image_link = models.URLField(blank=True, null=True)\n    json_info = models.JSONField(null=True, blank=True)\n\n    # The following fields (dummy fields) are just for harmonizing the chant and sequence models to have the same fields\n    # They should never be populated or displayed\n    # The order of the fields must be exactly the same between the seq and chant models\n    marginalia = models.CharField(max_length=63, null=True, blank=True)\n    sequence_number = models.PositiveIntegerField(\n        help_text='Each folio starts with \"1\"', null=True, blank=True\n    )\n    office = models.ForeignKey(\n        \"Office\", on_delete=models.PROTECT, null=True, blank=True\n    )\n    position = models.CharField(max_length=63, null=True, blank=True)\n    feast = models.ForeignKey(\"Feast\", on_delete=models.PROTECT, null=True, blank=True)\n    mode = models.CharField(max_length=63, null=True, blank=True)\n    differentia = models.CharField(blank=True, null=True, max_length=63)\n    differentia_id = models.CharField(blank=True, null=True, max_length=12)\n    finalis = models.CharField(blank=True, null=True, max_length=63)\n    extra = models.CharField(blank=True, null=True, max_length=63)\n    chant_range = models.CharField(\n        blank=True,\n        null=True,\n        help_text='Example: \"1-c-k-4\". Optional field',\n        max_length=255,\n    )\n    addendum = models.CharField(blank=True, null=True, max_length=255)\n    manuscript_full_text_std_spelling = models.TextField(\n        help_text=\"Manuscript full text with standardized spelling. Enter the words \"\n        \"according to the manuscript but normalize their spellings following \"\n        \"Classical Latin forms. Use upper-case letters for proper nouns, \"\n        'the first word of each chant, and the first word after \"Alleluia\" for '\n        \"Mass Alleluias. Punctuation is omitted.\",\n        null=True,\n        blank=True,\n    )\n    manuscript_full_text_std_proofread = models.BooleanField(blank=True, null=True)\n    manuscript_full_text = models.TextField(\n        help_text=\"Enter the wording, word order and spellings as found in the manuscript\"\n        \", with abbreviations resolved to standard words. Use upper-case letters as found\"\n        \" in the source. Retain \u201cXpistum\u201d (Christum), \u201cIhc\u201d (Jesus) and other instances of \"\n        \"Greek characters with their closest approximations of Latin letters. Some punctuation\"\n        \" signs and vertical dividing lines | are employed in this field. Repetenda and psalm \"\n        \"cues can also be recorded here. For more information, contact Cantus Database staff.\",\n        null=True,\n        blank=True,\n    )\n    manuscript_full_text_proofread = models.BooleanField(blank=True, null=True)\n    manuscript_syllabized_full_text = models.TextField(null=True, blank=True)\n    volpiano = models.TextField(null=True, blank=True)\n    volpiano_proofread = models.BooleanField(blank=True, null=True)\n    volpiano_notes = models.TextField(null=True, blank=True)\n    volpiano_intervals = models.TextField(null=True, blank=True)\n    # volpiano_intervals = ArrayField(base_field=models.IntegerField(), null=True, blank=True)\n    cao_concordances = models.CharField(blank=True, null=True, max_length=63)\n    proofread_by = models.ForeignKey(\n        User, on_delete=models.PROTECT, null=True, blank=True\n    )\n    melody_id = models.CharField(blank=True, null=True, max_length=63)\n    search_vector = SearchVectorField(null=True, editable=False)\n    content_structure = models.CharField(\n        blank=True,\n        null=True,\n        max_length=64,\n        help_text=\"Additional folio number field, if folio numbers appear on the leaves but are not in the 'binding order'.\",\n    )\n", "path": "django/cantusdb_project/main_app/models/sequence.py"}]}