Skip to content

Commit

Permalink
Release 3.0.4
Browse files Browse the repository at this point in the history
Release 3.0.4
  • Loading branch information
alexandrebouthinon authored Mar 27, 2024
2 parents 2400c5f + 026dc1e commit 7a2a1eb
Show file tree
Hide file tree
Showing 15 changed files with 45 additions and 49 deletions.
38 changes: 18 additions & 20 deletions .ci/doc/config.yml
Original file line number Diff line number Diff line change
@@ -1,22 +1,20 @@
---
snippets:
mount: /mnt
path: "doc/**/snippets/*.test.yml"
templates: /mnt/.ci/doc/templates
protocols:
- http
- websocket

snippets:
mount: /mnt
path: 'doc/**/snippets/*.test.yml'
templates: /mnt/.ci/doc/templates
protocols:
- http
- websocket

runners:
default: dart

dart:
service: doc-runner-dart
path: /var/snippets/dart
build:
cmd: cd /mnt
run:
before: timeout 600 bash -c 'until stat /tmp/runner_is_ready && curl -f -s -o /dev/null http://kuzzle:7512/_now; do sleep 1; done && cp *.dart /mnt/.ci/doc/project/ && cd /mnt/.ci/doc/project/ && pub get'
cmd: cd /mnt/.ci/doc/project/ && SNIPPET_PROTOCOL="{{ snippet.protocol }}" dart {{ snippet.source }}

runners:
default: dart

dart:
service: doc-runner-dart
path: /var/snippets/dart
build:
cmd: cd /mnt
run:
before: timeout 600 bash -c 'until stat /tmp/runner_is_ready && curl -f -s -o /dev/null http://kuzzle:7512/_now; do sleep 1; done && cp *.dart /mnt/.ci/doc/project/ && cd /mnt/.ci/doc/project/ && dart pub get'
cmd: cd /mnt/.ci/doc/project/ && SNIPPET_PROTOCOL="{{ snippet.protocol }}" dart {{ snippet.source }}
2 changes: 1 addition & 1 deletion .ci/doc/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ services:
- CONFIG_FILE=/mnt/.ci/doc/config.yml

doc-runner-dart:
image: google/dart
image: dart:3
command: >
bash -c '
mkdir -p /var/snippets/dart;
Expand Down
2 changes: 1 addition & 1 deletion .ci/doc/project/pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ version: 1.0.0
description: Dart SDK doc snippet test project

environment:
sdk: ">=2.7.0 <3.0.0"
sdk: ">=2.12.0 <4.0.0"

dependencies:
kuzzle:
Expand Down
2 changes: 1 addition & 1 deletion .ci/doc/templates/catch.tpl.dart
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ void main() async {
await kuzzle.connect();
[snippet-code]
} catch(e, s) {
print(e.message);
print(e);
} finally {
kuzzle.disconnect();
}
Expand Down
4 changes: 2 additions & 2 deletions doc/3/core-classes/profile/next/snippets/fromsize.dart
Original file line number Diff line number Diff line change
Expand Up @@ -9,14 +9,14 @@ for (var i = 1; i <= 5; i++) {
);
}

var res = await kuzzle.security.searchProfiles(
SearchResult? res = await kuzzle.security.searchProfiles(
query:{ 'roles': [ 'default' ] },
from: 1,
size: 1);

final result = [];

while (res != null) {
result.addAll(res.hits);
result.addAll(res.hits as Iterable<dynamic>);
res = await res.next();
}
4 changes: 2 additions & 2 deletions doc/3/core-classes/profile/next/snippets/scroll.dart
Original file line number Diff line number Diff line change
Expand Up @@ -9,14 +9,14 @@ for (var i = 1; i <= 5; i++) {
);
}

var res = await kuzzle.security.searchProfiles(
SearchResult? res = await kuzzle.security.searchProfiles(
query:{ 'roles': [ 'default' ] },
scroll: '10s',
size: 1);

final result = [];

while (res != null) {
result.addAll(res.hits);
result.addAll(res.hits as Iterable<dynamic>);
res = await res.next();
}
4 changes: 2 additions & 2 deletions doc/3/core-classes/role/next/snippets/fromsize.dart
Original file line number Diff line number Diff line change
Expand Up @@ -14,14 +14,14 @@ for (var i = 1; i <= 5; i++) {
);
}

var res = await kuzzle.security.searchRoles(
SearchResult? res = await kuzzle.security.searchRoles(
query:{ 'controllers': [ 'auth' ] },
from: 1,
size: 1);

final result = [];

while (res != null) {
result.addAll(res.hits);
result.addAll(res.hits as Iterable<dynamic>);
res = await res.next();
}
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ await kuzzle.document.mCreate('nyc-open-data', 'yellow-taxi', documents,
waitForRefresh: true
);

var res = await kuzzle.document.search(
SearchResult? res = await kuzzle.document.search(
'nyc-open-data',
'yellow-taxi',
query: { 'query': { 'match': { 'category': 'suv' } } },
Expand All @@ -18,6 +18,6 @@ var res = await kuzzle.document.search(
final result = [];

while (res != null) {
result.addAll(res.hits);
result.addAll(res.hits as Iterable<dynamic>);
res = await res.next();
}
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ await kuzzle.document.mCreate('nyc-open-data', 'yellow-taxi', documents,
waitForRefresh: true
);

var res = await kuzzle.document.search(
SearchResult? res = await kuzzle.document.search(
'nyc-open-data',
'yellow-taxi',
query: { 'query': { 'equals': { 'category': 'suv' } } },
Expand All @@ -18,6 +18,6 @@ var res = await kuzzle.document.search(
final result = [];

while (res != null) {
result.addAll(res.hits);
result.addAll(res.hits as Iterable<dynamic>);
res = await res.next();
}
4 changes: 2 additions & 2 deletions doc/3/core-classes/search-result/next/snippets/scroll-es.dart
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ await kuzzle.document.mCreate('nyc-open-data', 'yellow-taxi', documents,
waitForRefresh: true
);

var res = await kuzzle.document.search(
SearchResult? res = await kuzzle.document.search(
'nyc-open-data',
'yellow-taxi',
query: { 'query': { 'match': { 'category': 'suv' } } },
Expand All @@ -18,6 +18,6 @@ var res = await kuzzle.document.search(
final result = [];

while (res != null) {
result.addAll(res.hits);
result.addAll(res.hits as Iterable<dynamic>);
res = await res.next();
}
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ await kuzzle.document.mCreate('nyc-open-data', 'yellow-taxi', documents,
waitForRefresh: true
);

var res = await kuzzle.document.search(
SearchResult? res = await kuzzle.document.search(
'nyc-open-data',
'yellow-taxi',
query: { 'query': { 'equals': { 'category': 'suv' } } },
Expand All @@ -18,6 +18,6 @@ var res = await kuzzle.document.search(
final result = [];

while (res != null) {
result.addAll(res.hits);
result.addAll(res.hits as Iterable<dynamic>);
res = await res.next();
}
4 changes: 2 additions & 2 deletions doc/3/core-classes/user/next/snippets/fromsize.dart
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ for (var i = 1; i <= 5; i++) {
});
}

var res = await kuzzle.security.searchUsers(
SearchResult? res = await kuzzle.security.searchUsers(
query: {
'query': {
'term': {
Expand All @@ -27,6 +27,6 @@ var res = await kuzzle.security.searchUsers(
final result = [];

while (res != null) {
result.addAll(res.hits);
result.addAll(res.hits as Iterable<dynamic>);
res = await res.next();
}
4 changes: 2 additions & 2 deletions doc/3/core-classes/user/next/snippets/scroll.dart
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ for (var i = 1; i <= 5; i++) {
});
}

var res = await kuzzle.security.searchUsers(
SearchResult? res = await kuzzle.security.searchUsers(
query: {
'query': {
'term': {
Expand All @@ -27,6 +27,6 @@ var res = await kuzzle.security.searchUsers(
final result = [];

while (res != null) {
result.addAll(res.hits);
result.addAll(res.hits as Iterable<dynamic>);
res = await res.next();
}
8 changes: 3 additions & 5 deletions doc/3/getting-started/.flutter/pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ description: A new Flutter project.

# The following line prevents the package from being accidentally published to
# pub.dev using `pub publish`. This is preferred for private packages.
publish_to: 'none' # Remove this line if you wish to publish to pub.dev
publish_to: "none" # Remove this line if you wish to publish to pub.dev

# The following defines the version and build number for your application.
# A version number is three numbers separated by dots, like 1.2.43
Expand All @@ -18,13 +18,12 @@ publish_to: 'none' # Remove this line if you wish to publish to pub.dev
version: 1.0.0+1

environment:
sdk: ">=2.7.0 <3.0.0"
sdk: ">=2.12.0 <4.0.0"

dependencies:
flutter:
sdk: flutter
kuzzle: ^2.0.1

kuzzle: ^3.0.3

# The following adds the Cupertino Icons font to your application.
# Use with the CupertinoIcons class for iOS style icons.
Expand All @@ -39,7 +38,6 @@ dev_dependencies:

# The following section is specific to Flutter.
flutter:

# The following line ensures that the Material Icons font is
# included with your application, so that you can use the icons in
# the material Icons class.
Expand Down
6 changes: 3 additions & 3 deletions pubspec.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
name: kuzzle
version: 3.0.3
version: 3.0.4
description: A library to interact with kuzzle API. A backend software,
self-hostable and ready to use to power modern cross-platform apps.
homepage: https://github.com/kuzzleio/sdk-dart
Expand All @@ -8,8 +8,8 @@ environment:
dependencies:
pedantic: ^1.11.1
meta: ^1.4.0
uuid: ^3.0.4
http: ^0.13.3
uuid: ^4.3.3
http: ^1.2.1
mockito: ^5.0.10
dev_dependencies:
test: ^1.17.8
Expand Down

0 comments on commit 7a2a1eb

Please sign in to comment.