Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,7 @@
from tenacity.asyncio import AsyncRetrying
from tenacity.retry import retry_if_exception_type

from ..application_settings import get_application_settings
from ..models import ClientSessionID
from ..utils import now_str
from ._comments_repository import (
Expand Down Expand Up @@ -957,19 +958,23 @@ async def _update_project_workbench_with_lock_and_notify(
allow_workbench_changes=allow_workbench_changes,
)

(
project_document,
document_version,
) = await create_project_document_and_increment_version(self._app, project_uuid)
app_settings = get_application_settings(self._app)
if app_settings.WEBSERVER_REALTIME_COLLABORATION is not None:
(
project_document,
document_version,
) = await create_project_document_and_increment_version(
self._app, project_uuid
)

await notify_project_document_updated(
app=self._app,
project_id=project_uuid,
user_primary_gid=user_primary_gid,
client_session_id=client_session_id,
version=document_version,
document=project_document,
)
await notify_project_document_updated(
app=self._app,
project_id=project_uuid,
user_primary_gid=user_primary_gid,
client_session_id=client_session_id,
version=document_version,
document=project_document,
)
return updated_project, changed_entries

async def _update_project_workbench(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -205,18 +205,20 @@ async def patch_project_and_notify_users(
new_partial_project_data=patch_project_data,
)

(
project_document,
document_version,
) = await create_project_document_and_increment_version(app, project_uuid)
await notify_project_document_updated(
app=app,
project_id=project_uuid,
user_primary_gid=user_primary_gid,
client_session_id=client_session_id,
version=document_version,
document=project_document,
)
app_settings = get_application_settings(app)
if app_settings.WEBSERVER_REALTIME_COLLABORATION is not None:
(
project_document,
document_version,
) = await create_project_document_and_increment_version(app, project_uuid)
await notify_project_document_updated(
app=app,
project_id=project_uuid,
user_primary_gid=user_primary_gid,
client_session_id=client_session_id,
version=document_version,
document=project_document,
)


def _is_node_dynamic(node_key: str) -> bool:
Expand Down
Loading