@@ -173,6 +173,7 @@ def create_publishable_entity(
173173 created : datetime ,
174174 # User ID who created this
175175 created_by : int | None ,
176+ can_stand_alone : bool = True ,
176177) -> PublishableEntity :
177178 """
178179 Create a PublishableEntity.
@@ -185,6 +186,7 @@ def create_publishable_entity(
185186 key = key ,
186187 created = created ,
187188 created_by_id = created_by ,
189+ can_stand_alone = can_stand_alone ,
188190 )
189191
190192
@@ -583,6 +585,7 @@ def create_container(
583585 key : str ,
584586 created : datetime ,
585587 created_by : int | None ,
588+ can_stand_alone : bool = True ,
586589 # The types on the following line are correct, but mypy will complain - https://github.com/python/mypy/issues/3737
587590 container_cls : type [ContainerModel ] = Container , # type: ignore[assignment]
588591) -> ContainerModel :
@@ -603,7 +606,7 @@ def create_container(
603606 assert issubclass (container_cls , Container )
604607 with atomic ():
605608 publishable_entity = create_publishable_entity (
606- learning_package_id , key , created , created_by
609+ learning_package_id , key , created , created_by , can_stand_alone
607610 )
608611 container = container_cls .objects .create (
609612 publishable_entity = publishable_entity ,
0 commit comments