Skip to content

Commit

Permalink
Update to master (#9)
Browse files Browse the repository at this point in the history
* 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 doccano#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 <dimidd@localize.city>

* 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
5728636

* 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](django/django@3.2.4...3.2.5)

---
updated-dependencies:
- dependency-name: django
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>

* 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 doccano#1481

* Update cli, fix doccano#1408

* Add explanation on create user, close doccano#1410

* Update faq, close doccano#1496

* Remove old tests

* Update test config

* Update components, fix doccano#1541

* Add test for FormGuideline component

* Update the name of test case

* Apply linter

* Update eslint config

* Update docker-compose.dev.yml, fix doccano#1536

* added merge

* added merge

* added merge

* add merge

* add merge

Co-authored-by: zanussbaum <zanussbaum@gmail.com>
Co-authored-by: youichiro <cinnamon416@gmail.com>
Co-authored-by: ayanamizuta <ayanamizuta832@gmail.com>
Co-authored-by: Roland Szabo <rolisz@gmail.com>
Co-authored-by: Dimid Duchovny <dimidd@localize.city>
Co-authored-by: rcarew@xelerance.com <rcarew@xelerance.com>
Co-authored-by: Dale Evans <dale.evans@mycanadapayday.com>
Co-authored-by: Colin Darie <colin@darie.eu>
Co-authored-by: Yosua Michael M <yosua.maranatha@grabtaxi.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Hironsan <light.tree.1.13@gmail.com>
Co-authored-by: Hiroki Nakayama <hiroki.nakayama.py@gmail.com>
Co-authored-by: Talha Oz <oztalha@users.noreply.github.com>
Co-authored-by: Gerhard Haß <gerhard.hass@neofonie.de>
  • Loading branch information
15 people committed Nov 1, 2021
1 parent 120d9af commit 6570588
Show file tree
Hide file tree
Showing 76 changed files with 1,404 additions and 1,312 deletions.
2 changes: 1 addition & 1 deletion docker-compose.dev.yml
Expand Up @@ -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:
Expand Down
3 changes: 1 addition & 2 deletions frontend/.eslintrc.js
Expand Up @@ -8,8 +8,7 @@ module.exports = {
'@nuxtjs',
'plugin:nuxt/recommended',
'@nuxtjs/eslint-config-typescript',
'prettier',
'prettier/vue'
'prettier'
],
rules: {
'no-console': 'off',
Expand Down
2 changes: 1 addition & 1 deletion frontend/components/comment/Comment.vue
Expand Up @@ -24,7 +24,7 @@
bottom
left
>
<template v-slot:activator="{ on, attrs }">
<template #activator="{ on, attrs }">
<v-btn
icon
v-bind="attrs"
Expand Down
6 changes: 3 additions & 3 deletions frontend/components/comment/CommentList.vue
Expand Up @@ -17,10 +17,10 @@
show-select
@input="$emit('input', $event)"
>
<template v-slot:[`item.createdAt`]="{ item }">
<template #[`item.createdAt`]="{ item }">
<span>{{ item.createdAt | dateParse('YYYY-MM-DDTHH:mm:ss') | dateFormat('DD/MM/YYYY HH:mm') }}</span>
</template>
<template v-slot:top>
<template #top>
<v-text-field
v-model="search"
prepend-inner-icon="search"
Expand All @@ -30,7 +30,7 @@
filled
/>
</template>
<template v-slot:[`item.action`]="{ item }">
<template #[`item.action`]="{ item }">
<v-btn
small
color="primary text-capitalize"
Expand Down
2 changes: 1 addition & 1 deletion frontend/components/configAutoLabeling/ConfigList.vue
Expand Up @@ -9,7 +9,7 @@
:loading-text="$t('generic.loading')"
show-select
>
<template v-slot:top>
<template #top>
<div class="ma-4">
<v-btn
class="primary text-capitalize"
Expand Down
Expand Up @@ -41,9 +41,10 @@
If you want to know the Jinja2 notation, please refer to the site.
</p>
<v-textarea
v-model="value"
:value="value"
outlined
label="Mapping Template"
@change="$emit('input', $event)"
/>
<v-alert
v-for="(error, index) in errorMessages"
Expand Down Expand Up @@ -128,12 +129,6 @@ export default Vue.extend({
default: () => [],
required: true
}
},
watch: {
value(val) {
this.$emit('input', val)
}
}
})
</script>
6 changes: 3 additions & 3 deletions frontend/components/configAutoLabeling/form/LabelMapping.vue
Expand Up @@ -3,12 +3,12 @@
:headers="headers"
:items="value"
>
<template v-slot:top>
<template #top>
<v-dialog
v-model="dialog"
max-width="800px"
>
<template v-slot:activator="{ on, attrs }">
<template #activator="{ on, attrs }">
<v-btn
color="primary"
dark
Expand Down Expand Up @@ -84,7 +84,7 @@
</v-card>
</v-dialog>
</template>
<template v-slot:[`item.actions`]="{ item }">
<template #[`item.actions`]="{ item }">
<v-icon
small
class="mr-2"
Expand Down
6 changes: 3 additions & 3 deletions frontend/components/configAutoLabeling/form/ObjectField.vue
Expand Up @@ -3,7 +3,7 @@
:headers="headers"
:items="value"
>
<template v-slot:top>
<template #top>
<v-toolbar
class="toolbar-control"
flat
Expand All @@ -16,7 +16,7 @@
v-model="dialog"
max-width="800px"
>
<template v-slot:activator="{ on, attrs }">
<template #activator="{ on, attrs }">
<v-btn
color="primary"
dark
Expand Down Expand Up @@ -90,7 +90,7 @@
</v-dialog>
</v-toolbar>
</template>
<template v-slot:[`item.actions`]="{ item }">
<template #[`item.actions`]="{ item }">
<v-icon
small
class="mr-2"
Expand Down
10 changes: 5 additions & 5 deletions frontend/components/example/AudioList.vue
Expand Up @@ -19,7 +19,7 @@
show-select
@input="$emit('input', $event)"
>
<template v-slot:top>
<template #top>
<v-text-field
v-model="search"
prepend-inner-icon="search"
Expand All @@ -29,7 +29,7 @@
filled
/>
</template>
<template v-slot:[`item.url`]="{ item }">
<template #[`item.url`]="{ item }">
<audio
controls
:src="item.url"
Expand All @@ -39,13 +39,13 @@
<code>audio</code> element.
</audio>
</template>
<template v-slot:[`item.meta`]="{ item }">
<template #[`item.meta`]="{ item }">
{{ JSON.stringify(item.meta, null, 4) }}
</template>
<template v-slot:[`item.commentCount`]="{ item }">
<template #[`item.commentCount`]="{ item }">
<span> {{ item.commentCount }} </span>
</template>
<template v-slot:[`item.action`]="{ item }">
<template #[`item.action`]="{ item }">
<v-btn
small
color="primary text-capitalize"
Expand Down
10 changes: 5 additions & 5 deletions frontend/components/example/DocumentList.vue
Expand Up @@ -19,7 +19,7 @@
show-select
@input="$emit('input', $event)"
>
<template v-slot:top>
<template #top>
<v-text-field
v-model="search"
prepend-inner-icon="search"
Expand All @@ -29,17 +29,17 @@
filled
/>
</template>
<template v-slot:[`item.text`]="{ item }">
<template #[`item.text`]="{ item }">
<span class="d-flex d-sm-none">{{ item.text | truncate(50) }}</span>
<span class="d-none d-sm-flex">{{ item.text | truncate(200) }}</span>
</template>
<template v-slot:[`item.meta`]="{ item }">
<template #[`item.meta`]="{ item }">
{{ JSON.stringify(item.meta, null, 4) }}
</template>
<template v-slot:[`item.commentCount`]="{ item }">
<template #[`item.commentCount`]="{ item }">
<span> {{ item.commentCount }} </span>
</template>
<template v-slot:[`item.action`]="{ item }">
<template #[`item.action`]="{ item }">
<v-btn
small
color="primary text-capitalize"
Expand Down
10 changes: 5 additions & 5 deletions frontend/components/example/ImageList.vue
Expand Up @@ -19,7 +19,7 @@
show-select
@input="$emit('input', $event)"
>
<template v-slot:top>
<template #top>
<v-text-field
v-model="search"
prepend-inner-icon="search"
Expand All @@ -29,7 +29,7 @@
filled
/>
</template>
<template v-slot:[`item.url`]="{ item }">
<template #[`item.url`]="{ item }">
<v-img
:src="item.url"
aspect-ratio="1"
Expand All @@ -39,13 +39,13 @@
class="grey lighten-2"
/>
</template>
<template v-slot:[`item.meta`]="{ item }">
<template #[`item.meta`]="{ item }">
{{ JSON.stringify(item.meta, null, 4) }}
</template>
<template v-slot:[`item.commentCount`]="{ item }">
<template #[`item.commentCount`]="{ item }">
<span> {{ item.commentCount }} </span>
</template>
<template v-slot:[`item.action`]="{ item }">
<template #[`item.action`]="{ item }">
<v-btn
small
color="primary text-capitalize"
Expand Down
6 changes: 3 additions & 3 deletions frontend/components/label/LabelList.vue
Expand Up @@ -16,7 +16,7 @@
show-select
@input="$emit('input', $event)"
>
<template v-slot:top>
<template #top>
<v-text-field
v-model="search"
prepend-inner-icon="search"
Expand All @@ -26,15 +26,15 @@
filled
/>
</template>
<template v-slot:[`item.backgroundColor`]="props">
<template #[`item.backgroundColor`]="props">
<v-chip
:color="props.item.backgroundColor"
:text-color="$contrastColor(props.item.backgroundColor)"
>
{{ props.item.backgroundColor }}
</v-chip>
</template>
<template v-slot:[`item.actions`]="{ item }">
<template #[`item.actions`]="{ item }">
<v-icon
small
@click="$emit('edit', item)"
Expand Down
2 changes: 1 addition & 1 deletion frontend/components/layout/LocaleMenu.vue
Expand Up @@ -3,7 +3,7 @@
open-on-hover
offset-y
>
<template v-slot:activator="{ on }">
<template #activator="{ on }">
<v-btn
text
v-on="on"
Expand Down
2 changes: 1 addition & 1 deletion frontend/components/layout/TheBottomBanner.vue
Expand Up @@ -32,7 +32,7 @@
</h1>
<div class="mt-4">
<v-menu open-on-hover offset-y>
<template v-slot:activator="{ on }">
<template #activator="{ on }">
<v-btn
class="blue lighten-2"
dark
Expand Down
6 changes: 3 additions & 3 deletions frontend/components/layout/TheHeader.vue
Expand Up @@ -44,7 +44,7 @@
open-on-hover
offset-y
>
<template v-slot:activator="{ on }">
<template #activator="{ on }">
<v-btn
text
v-on="on"
Expand Down Expand Up @@ -74,7 +74,7 @@
v-if="isAuthenticated"
offset-y
>
<template v-slot:activator="{ on }">
<template #activator="{ on }">
<v-btn on icon v-on="on">
<v-icon>mdi-dots-vertical</v-icon>
</v-btn>
Expand All @@ -86,8 +86,8 @@
<v-switch
:input-value="isRTL"
:label="direction"
@change="toggleRTL"
class="ms-1"
@change="toggleRTL"
/>
</v-list-item-content>
</v-list-item>
Expand Down
6 changes: 3 additions & 3 deletions frontend/components/links/LinksList.vue
Expand Up @@ -17,7 +17,7 @@
show-select
@input="$emit('input', $event)"
>
<template v-slot:top>
<template #top>
<v-text-field
v-model="search"
prepend-inner-icon="search"
Expand All @@ -27,15 +27,15 @@
filled
/>
</template>
<template v-slot:[`item.color`]="props">
<template #[`item.color`]="props">
<v-chip
:color="props.item.color"
:text-color="$contrastColor(props.item.color)"
>
{{ props.item.color }}
</v-chip>
</template>
<template v-slot:[`item.actions`]="{ item }">
<template #[`item.actions`]="{ item }">
<v-icon
small
@click="$emit('edit', item)"
Expand Down
16 changes: 8 additions & 8 deletions frontend/components/member/FormCreate.vue
Expand Up @@ -32,10 +32,10 @@
return-object
prepend-icon="mdi-credit-card-outline"
>
<template v-slot:item="props">
<template #item="props">
{{ $translateRole(props.item.rolename, $t('members.roles')) }}
</template>
<template v-slot:selection="props">
<template #selection="props">
{{ $translateRole(props.item.rolename, $t('members.roles')) }}
</template>
</v-select>
Expand Down Expand Up @@ -78,12 +78,6 @@ export default Vue.extend({
}
},
async fetch() {
this.isLoading = true
this.users = await this.$services.user.list(this.username)
this.isLoading = false
},
data() {
return {
isLoading: false,
Expand All @@ -98,6 +92,12 @@ export default Vue.extend({
}
},
async fetch() {
this.isLoading = true
this.users = await this.$services.user.list(this.username)
this.isLoading = false
},
computed: {
user: {
get(): UserDTO {
Expand Down
6 changes: 3 additions & 3 deletions frontend/components/member/MemberList.vue
Expand Up @@ -16,7 +16,7 @@
show-select
@input="$emit('input', $event)"
>
<template v-slot:top>
<template #top>
<v-text-field
v-model="search"
prepend-inner-icon="search"
Expand All @@ -26,10 +26,10 @@
filled
/>
</template>
<template v-slot:[`item.rolename`]="{ item }">
<template #[`item.rolename`]="{ item }">
{{ $translateRole(item.rolename, $t('members.roles')) }}
</template>
<template v-slot:[`item.actions`]="{ item }">
<template #[`item.actions`]="{ item }">
<v-icon
small
@click="$emit('edit', item)"
Expand Down

0 comments on commit 6570588

Please sign in to comment.