* [project-history] add support for resync of history-ot ranges
* [project-history] avoid compressing sharejs and history-ot upgrades
* [document-updater] improve error message of some assertions
... by migrating the assertions like this:
```diff
-stub.calledWith().should.equal(true)
+stub.should.have.been.calledWith()
```
```diff
-stub.called.should.equal(false)
+stub.should.not.have.been.called
```
* [document-updater] move content field in resyncDocContent
* [document-updater] add support for resync of history-ot ranges
GitOrigin-RevId: e6104686a26934a5f25a8f095cbe00c163fbbaa7
* [document-updater] flush history for projects with short queues ASAP
* [k8s] document-updater: enable short history queue for history-ot demo
* [project-history] flush history for projects with short queues ASAP
* [project-history] wait for mongo before running acceptance tests
* [k8s] project-history: enable short history queue for history-ot demo
* [project-history] change wait-for-mongo step in tests
Co-authored-by: Eric Mc Sween <eric.mcsween@overleaf.com>
---------
Co-authored-by: Eric Mc Sween <eric.mcsween@overleaf.com>
GitOrigin-RevId: 3e989c409e8e9887655b35f2659ce0829e61b357
* [history-ot] rename remaining history-v1-ot references to history-ot
* [web] rename History-v1 OT -> History OT in admin panel
* [web] rename OT Migration -> History OT Migration in admin panel
GitOrigin-RevId: 103ce816d5320d6379d51009cdc08b8a71aa48e6
* Run `bin/update_node 20.18.2 22.15.0`
* Remove expects on `fetchMock.callHistory.done()` to fix tests: are they necessary?
* Set node version to `22.x` in linked-url-proxy
* Increase test timeout to 30s in `github-sync`, Add waiting steps
* Define `navigator.onLine` in tests setup
GitOrigin-RevId: 75eb556e9f51b665e57497a0879b6915d14069ce
* [document-updater] Don't return promises within functions with callbacks
Remove the errors:
DeprecationWarning: Calling promisify on a function that returns a Promise is likely a mistake
https://cloudlogging.app.goo.gl/YHDhoarvLEw2w9rXA
* Remove some more unnecessary returns in functions with callbacks, for consistency
* Add `sendCanaryAppliedOp` to excluded methods for promisification
GitOrigin-RevId: fa6d3e47c4e6561dc29d4c15e57c3289fc1f3dfa
* [history-v1-ot] initial implementation of using doc-level history-v1-ot
* [web] fix advancing of the otMigrationStage
Use 'nextStage' for the user provided, desired stage when advancing.
Co-authored-by: Brian Gough <brian.gough@overleaf.com>
* [document-updater] document size check in editor-core
* [history-ot] rename history-v1-ot to history-ot and add types
* [history-ot] apply review feedback
- remove extra !!
- merge variable assignment when processing diff-match-match output
- add helper function for getting docstore lines view of StringFileData
Co-authored-by: Alf Eaton <alf.eaton@overleaf.com>
* Revert "[document-updater] add safe rollback point for history-ot (#25283)"
This reverts commit d7230dd14a379a27d2c6ab03a006463a18979d06
Signed-off-by: Jakob Ackermann <jakob.ackermann@overleaf.com>
---------
Signed-off-by: Jakob Ackermann <jakob.ackermann@overleaf.com>
Co-authored-by: Brian Gough <brian.gough@overleaf.com>
Co-authored-by: Alf Eaton <alf.eaton@overleaf.com>
GitOrigin-RevId: 89c497782adb0427635d50d02263d6f535b12481
- Remove settings ignore, they are inconsistent and break local prettier
- Remove .dockerignore files, only root ignore file is used
- Move .idea/.run/*.swp/coverage to root
- Remove .npmrc entries, we are no longer writing the rc file
- Remove node_modules/.DS_Store, is contained in root
- Remove cruft
GitOrigin-RevId: 3025fd5acaef343312f55149466c638e759a6e1f
- use beforeEach to ensure tests do not interfere with each other
Notably, the 'when the ops come in a single linear order' test suite
had state-changing tests that were dependent on the correct order.
Also, the assigment of 'this.firstOpTimestamp' was in a test.
- consolidate populating project and doc ids
The doc reference in this.update was undefined.
- fix doc reference in updates
There were two misuses of 'doc_id' instead of 'doc'.
- Move mocking of MockWebApi.getDocument to the top and use
sinon.resetHistory() or sinon.restore() for controlling the stub.
- Add another test for simple transforming of updates
See 'when another client is sending a concurrent update'.
GitOrigin-RevId: 61ca8a1b0172920ad6ab1b604a9b9259cebddaad
* [document-updater] fix acceptance test for sending two updates
The Object.create() invocation yields an empty object. The following v
assignment works as expected. The effective update is { v: 43 }.
Processing that fails as no operations were included.
* [document-updater] add endpoint project wide last updated timestamp
* [document-updater] apply review feedback
Co-authored-by: Eric Mc Sween <eric.mcsween@overleaf.com>
---------
Co-authored-by: Eric Mc Sween <eric.mcsween@overleaf.com>
GitOrigin-RevId: 81397537bfd85c2077f19669860b1391c15b34a3
* Update shellcheck files to include non ".sh" files having the sh shebang
* Add shellcheck to root Makefile
* `make shellcheck_fix`
* Add shellcheck to server-ce and server-pro
* Exclude SC1091 (Not following) in SP/CE
* Fix errors in SP
* Fix errors in CE
* Update root shellcheck to ignore all failing rules. We can later remove rules one by one.
* Add shellcheck to web
* Add shellcheck step for server-ce and server-pro in cloudbuild.yaml
* Revert "Add shellcheck to root Makefile"
This reverts commit e0fa56f2
* Revert "`make shellcheck_fix`"
This reverts commit eb179245c109a9e742a7fdeeb75a4bdd03963587.
* `make shellcheck_fix` in server-ce
* Fix: Use $(...) notation instead of legacy backticked
```
In init_scripts/100_set_docker_host_ipaddress.sh line 5:
echo "`route -n | awk '/UG[ \t]/{print $2}'` dockerhost" >> /etc/hosts
^-- SC2006 (style): Use $(...) notation instead of legacy backticks `...`.
Did you mean:
echo "$(route -n | awk '/UG[ \t]/{print $2}') dockerhost" >> /etc/hosts
For more information:
https://www.shellcheck.net/wiki/SC2006 -- Use $(...) notation instead of le...
```
* `make shellcheck_fix` in web
* Manual corrections on autofix
* Update SHELLCHECK_FILES to Perl regex so it matches at start of file
GitOrigin-RevId: 815d53f319a3792efa22703beb75570de5977450
* [misc] silence logger when running tests
* [misc] re-enable logging in some tests for scripts
* [misc] make it easy to turn on verbose logging for tests
```
LOG_LEVEL=debug make test_unit
LOG_LEVEL=debug make test_acceptance
```
GitOrigin-RevId: 219bc6d1f9cbdb89ddd7d94742920913ddde4514