From 6570588f68d20c8689685397310f9966150dd370 Mon Sep 17 00:00:00 2001 From: ghontolux <87199298+ghontolux@users.noreply.github.com> Date: Mon, 1 Nov 2021 13:38:35 +0100 Subject: [PATCH] Update to master (#9) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * Fixing Data Annotation Issues When uploading datasets, the code uses a `bulk_create` to upload Examples and Labels. It then filters the data from the database based on when it was created. However, [Django doesn't enforce the list order when calling filter](https://stackoverflow.com/questions/7163640/what-is-the-default-order-of-a-list-returned-from-a-django-filter-call) unless ordering is specified. The previous behavior mismatched labels and examples. When this was shown in the UI, the data would show labels for incorrect examples (i.e. a label for message #2 would be shown on message #1). This fix enforces that the data is returned in the order it was inserted so that the data, label pair is as expected. * move later to copy files in Dockerfile.prod * fix client-side types about comment as backend returns * add annotation link in commentList page * Add admin interface for AutoLabelingConfigs. Solves #1423 Thanks to @uklft for the idea. * Sort imports * Return a Response with a status if the task is not yet ready. * Remove unneeded query Bulk create returns the created objects in the same order as they have been added. In Postgres, the query was wrong, because ordering was not guaranteed. * Remove unneed import * removing debugging statement * iss1348: fix colors when importing labels Signed-off-by: Dimid Duchovny * Updated various dependency and image versions * Python version pinning fix * update cloudformation template to modify the sample env file, now that all the config params are stored in environment variables as per commit 57286362ce7545d469e110c20b0016387ee25abe * show a check button for annotators * filter by role in the confirm API * add a property to the ExampleState model * separate confirm status for each role or user * fix flake8 * fix TestExampleStateConfirmCollaborative * fix isort * move ExampleSerializer tests to test_document.py * add tests * Sequence labelling: fix background color in dark mode * add confirmed count to statistics api response * receive confirmed count value in frontend statistics models * make progress data per role * show progress of each role * not display legend of bar-chart * Increase the allowed max length for uploaded dataset filepath * Bump django from 3.2.4 to 3.2.5 Bumps [django](https://github.com/django/django) from 3.2.4 to 3.2.5. - [Release notes](https://github.com/django/django/releases) - [Commits](https://github.com/django/django/compare/3.2.4...3.2.5) --- updated-dependencies: - dependency-name: django dependency-type: direct:production ... Signed-off-by: dependabot[bot] * Add EntityEditor * Fix flake8 warnings * Update Dockerfiles * Add v-annotator * Update ner demo * Update sequence labeling page * Support RTL in sequence labeling * Update index.md * Update package * Add fields to SequenceLabelingProject * Update serializer in ProjectDetail * Enable to handle allowOverlapping and graphemeMode option in sequence labeling page * Enable to create project with allowOverlapping and graphemeMode option * Remove unused import * Update v-annotator to fix the problem The problem occurred when the user changes the state of RTL. Once the state changes, the entities are visually disappeared. * Show shortcut key on menu * Add explanation for nested mode * Add explanation for grapheme mode * Update shortcut on menu * Update package version * Enable to pass grapheme-mode to EntityEditor.vue * Add explanation for project creation * Support doccano init on windows * Fix cli * Add dependency, fix #1481 * Update cli, fix #1408 * Add explanation on create user, close #1410 * Update faq, close #1496 * Remove old tests * Update test config * Update components, fix #1541 * Add test for FormGuideline component * Update the name of test case * Apply linter * Update eslint config * Update docker-compose.dev.yml, fix #1536 * added merge * added merge * added merge * add merge * add merge Co-authored-by: zanussbaum Co-authored-by: youichiro Co-authored-by: ayanamizuta Co-authored-by: Roland Szabo Co-authored-by: Dimid Duchovny Co-authored-by: rcarew@xelerance.com Co-authored-by: Dale Evans Co-authored-by: Colin Darie Co-authored-by: Yosua Michael M Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Hironsan Co-authored-by: Hiroki Nakayama Co-authored-by: Talha Oz Co-authored-by: Gerhard Haß --- docker-compose.dev.yml | 2 +- frontend/.eslintrc.js | 3 +- frontend/components/comment/Comment.vue | 2 +- frontend/components/comment/CommentList.vue | 6 +- .../configAutoLabeling/ConfigList.vue | 2 +- .../form/ConfigTemplate.vue | 9 +- .../configAutoLabeling/form/LabelMapping.vue | 6 +- .../configAutoLabeling/form/ObjectField.vue | 6 +- frontend/components/example/AudioList.vue | 10 +- frontend/components/example/DocumentList.vue | 10 +- frontend/components/example/ImageList.vue | 10 +- frontend/components/label/LabelList.vue | 6 +- frontend/components/layout/LocaleMenu.vue | 2 +- .../components/layout/TheBottomBanner.vue | 2 +- frontend/components/layout/TheHeader.vue | 6 +- frontend/components/links/LinksList.vue | 6 +- frontend/components/member/FormCreate.vue | 16 +- frontend/components/member/MemberList.vue | 6 +- frontend/components/project/FormCreate.vue | 8 +- frontend/components/project/FormUpdate.vue | 8 +- frontend/components/project/ProjectList.vue | 8 +- .../tasks/metadata/ListMetadata.vue | 2 +- .../components/tasks/seq2seq/Seq2seqBox.vue | 8 +- .../tasks/sequenceLabeling/EntityItem.vue | 6 +- .../multiLabel/LabelSelect.vue | 4 +- .../singleLabel/LabelSelect.vue | 4 +- .../toolbar/buttons/ButtonAutoLabeling.vue | 2 +- .../tasks/toolbar/buttons/ButtonClear.vue | 2 +- .../tasks/toolbar/buttons/ButtonComment.vue | 2 +- .../tasks/toolbar/buttons/ButtonFilter.vue | 4 +- .../tasks/toolbar/buttons/ButtonGuideline.vue | 2 +- .../toolbar/buttons/ButtonPagination.vue | 2 +- .../tasks/toolbar/buttons/ButtonReview.vue | 2 +- .../tasks/toolbar/forms/FormComment.vue | 8 +- .../tasks/toolbar/forms/FormGuideline.vue | 2 +- frontend/components/utils/ActionMenu.vue | 2 +- frontend/jest.config.js | 6 +- frontend/layouts/default.vue | 4 +- frontend/layouts/demo.vue | 4 +- frontend/layouts/project.vue | 2 +- frontend/layouts/workspace.vue | 2 +- frontend/package.json | 4 +- .../pages/demo/image-classification/index.vue | 2 +- .../demo/named-entity-recognition/index.vue | 2 +- .../pages/demo/sentiment-analysis/index.vue | 2 +- frontend/pages/demo/speech-to-text/index.vue | 2 +- frontend/pages/demo/text-to-sql/index.vue | 2 +- frontend/pages/demo/translation/index.vue | 2 +- .../pages/projects/_id/comments/index.vue | 24 +- frontend/pages/projects/_id/dataset/index.vue | 21 +- .../pages/projects/_id/guideline/index.vue | 35 +- .../_id/image-classification/index.vue | 44 +- frontend/pages/projects/_id/index.vue | 8 +- frontend/pages/projects/_id/labels/index.vue | 30 +- frontend/pages/projects/_id/links/index.vue | 30 +- frontend/pages/projects/_id/members/index.vue | 28 +- .../projects/_id/sequence-labeling/index.vue | 41 +- .../_id/sequence-to-sequence/index.vue | 34 +- .../pages/projects/_id/settings/index.vue | 10 +- .../projects/_id/speech-to-text/index.vue | 36 +- .../pages/projects/_id/statistics/index.vue | 10 +- .../_id/text-classification/index.vue | 16 +- frontend/pages/projects/_id/upload/index.vue | 6 +- frontend/pages/projects/index.vue | 16 +- .../containers/ProjectCreationButton.spec.js | 40 - .../containers/ProjectDeletionButton.spec.js | 40 - .../components/containers/ProjectList.spec.js | 40 - .../test/unit/components/molecules/.gitkeep | 0 .../organisms/ProjecCreationForm.spec.js | 58 - .../components/organisms/ProjectList.spec.js | 64 - .../tasks/toolbar/forms/formGuideline.spec.js | 23 + frontend/test/unit/plugins/filters.spec.js | 18 - .../test/unit/services/api.service.spec.js | 56 - .../test/unit/services/csv.service.spec.js | 12 - .../unit/services/project.service.spec.js | 46 - frontend/yarn.lock | 1710 +++++++++++------ 76 files changed, 1404 insertions(+), 1312 deletions(-) delete mode 100644 frontend/test/unit/components/containers/ProjectCreationButton.spec.js delete mode 100644 frontend/test/unit/components/containers/ProjectDeletionButton.spec.js delete mode 100644 frontend/test/unit/components/containers/ProjectList.spec.js delete mode 100644 frontend/test/unit/components/molecules/.gitkeep delete mode 100644 frontend/test/unit/components/organisms/ProjecCreationForm.spec.js delete mode 100644 frontend/test/unit/components/organisms/ProjectList.spec.js create mode 100644 frontend/test/unit/components/tasks/toolbar/forms/formGuideline.spec.js delete mode 100644 frontend/test/unit/plugins/filters.spec.js delete mode 100644 frontend/test/unit/services/api.service.spec.js delete mode 100644 frontend/test/unit/services/csv.service.spec.js delete mode 100644 frontend/test/unit/services/project.service.spec.js diff --git a/docker-compose.dev.yml b/docker-compose.dev.yml index 70b2f524de..5cf9c01aba 100644 --- a/docker-compose.dev.yml +++ b/docker-compose.dev.yml @@ -53,7 +53,7 @@ services: - network-backend frontend: - image: node:16.5-alpine3.14 + image: node:16.13.0 command: ["/src/tools/dev-nuxt.sh"] working_dir: /src/frontend environment: diff --git a/frontend/.eslintrc.js b/frontend/.eslintrc.js index 9cf5a62521..84625c88e3 100644 --- a/frontend/.eslintrc.js +++ b/frontend/.eslintrc.js @@ -8,8 +8,7 @@ module.exports = { '@nuxtjs', 'plugin:nuxt/recommended', '@nuxtjs/eslint-config-typescript', - 'prettier', - 'prettier/vue' + 'prettier' ], rules: { 'no-console': 'off', diff --git a/frontend/components/comment/Comment.vue b/frontend/components/comment/Comment.vue index 83cad4cf3d..85b8457c3c 100644 --- a/frontend/components/comment/Comment.vue +++ b/frontend/components/comment/Comment.vue @@ -24,7 +24,7 @@ bottom left > -