Skip to content

Commit

Permalink
fix: Data too long for column 'resource_id'
Browse files Browse the repository at this point in the history
when the course id is a little bit long, the lti xblock id becomes too long for resource_id to handle
  • Loading branch information
shadinaif committed Jan 24, 2024
1 parent 44d0126 commit ab4df99
Show file tree
Hide file tree
Showing 4 changed files with 24 additions and 2 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,10 @@ Please See the `releases tab <https://github.com/openedx/xblock-lti-consumer/rel
Unreleased
~~~~~~~~~~

9.9.0 - 2024-01-15
------------------
* Fix Data too long for column 'resource_id'. Increase column size to 255.

9.8.1 - 2023-11-17
------------------
* Fix custom_parameters xblock field validation.
Expand Down
2 changes: 1 addition & 1 deletion lti_consumer/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@
from .apps import LTIConsumerApp
from .lti_xblock import LtiConsumerXBlock

__version__ = '9.8.1'
__version__ = '9.9.0'
18 changes: 18 additions & 0 deletions lti_consumer/migrations/0018_increase_length_of_resource_id.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
# Generated by Django 3.2.23 on 2023-12-25 10:56

from django.db import migrations, models


class Migration(migrations.Migration):

dependencies = [
('lti_consumer', '0017_lticonfiguration_lti_1p3_redirect_uris'),
]

operations = [
migrations.AlterField(
model_name='ltiagslineitem',
name='resource_id',
field=models.CharField(blank=True, max_length=255),
),
]
2 changes: 1 addition & 1 deletion lti_consumer/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -692,7 +692,7 @@ class LtiAgsLineItem(models.Model):
)

# Tool resource identifier, not used by the LMS.
resource_id = models.CharField(max_length=100, blank=True)
resource_id = models.CharField(max_length=255, blank=True)

# LMS Resource link
# Must be the same as the one sent in the tool's LTI launch.
Expand Down

0 comments on commit ab4df99

Please sign in to comment.