Questions tagged [aqueduct]
Aqueduct is an open-source, server-side framework written in Google’s Dart language.
139
questions
0
votes
0
answers
16
views
How to filter data in a many-to-many relationship in aqueduct?
If I have a many-to-many relationship
table A:
int? orgid;
String? orgname;
ManagedSet<B>? b;
table B:
int? type; // value = 1,2....
@Relate(#b)
A? a;
@Relate(#b)
C? c;
...
0
votes
0
answers
16
views
Erro for Deploy in Heroku with Aqueduct API Dart
I trying deploy with dart, I use aqueduct for my API
I use command git push heroku master after try builder, this message is displayed.
enter image description here
"No active package aqueduct.&...
-1
votes
1
answer
297
views
Dart Aqueduct Rest API Unit Testing: Null Safety Error
I have created a simple REST Api using aqueduct and dart and I am attempting to run unit tests. However, I get the following error when trying to do so:
Failed to load "test\example_test.dart&...
1
vote
1
answer
37
views
Get user from the middleware in Aqueduct
How to expose information from an authorization middleware, such as the logged-in user to the subsequent request controllers with Aqueduct?
Eg my route is:
.route('/events/[:id]')
.link(() => ...
0
votes
1
answer
152
views
What would be a good Flutter client for an Aqueduct server? [closed]
Writing my frontend app in Flutter/Dart, and my backend server using Aqueduct being written in Dart too, is there a tailored client that could e.g. reuse the models of Aqueduct?
1
vote
0
answers
30
views
Using third-parties id providers sign-in credentials to create a user in Aqueduct server
I'm trying to wrap my head around the whole Auth process as I'm building my first API/DB in Aqueduct, but I only found out on docs and other posts how to register users with email/password combination....
0
votes
1
answer
26
views
How to list/delete Clients in Aqueduct auth?
I'm following the Aqueduct docs for auth and I see that a Client is added like so:
aqueduct auth add-client \
--id com.food_app.mobile \
--connect postgres://user:password@dbhost:5432/food_app
...
0
votes
1
answer
55
views
POST request fails with missing required Body Aqueduct + PostgreSQL
I'm building my first API with Aqueduct and a PostgreSQL db. To test my endpoint I'm using Postman on the locally running server. GET requests works as expected, but the POST request fails with ...
0
votes
1
answer
27
views
Aqueduct routing behaviour unexpected results
I am trying to create a backend server with Aqueduct in dart. I am trying to create a resource controller that will deal with account issues.
routing code is like this;
router
.route("/$...
0
votes
1
answer
62
views
Two questions about real time observers and Stripe on server side Dart with Aqueduct
I'm going to switch from using Firebase only for back end to using my own server using Aqueduct with a PostgreSQL db for most functionalities and keep using only Google Cloud Storage and Firebase ...
1
vote
1
answer
30
views
Aqueduct ignores conroller
I have two controllers, one resource, the other normal. They are in the same thread and both must run.
I deliberately inserted a sudden return in a normal controller to make sure it was simply ignored....
0
votes
0
answers
165
views
Dart Aqueduct which version to use?
Im having Dart SDK 2.10.4
Aqueduct in version 3.3.1
but for me it seems that those two don't work together well, e.g. do not connect to Postgres...
When i downgrade Dart to 2.7.2 the DB connection ...
1
vote
2
answers
2k
views
How to install two different version of dart for flutter and aqueduct in a macos
Currently I have dart installed with flutter, versions as below:
Flutter 1.23.0-18.1.pre • channel beta • https://github.com/flutter/flutter.git
Framework • revision 198df796aa (2 weeks ago) • 2020-10-...
0
votes
1
answer
37
views
Aqueduct template db_and_auth not rendering login form
I am working on setting up OAuth 2.0 for aqueduct and want to start with a working example. The template db_and_auth is suppose to serve this purpose.
I have followed the readme instructions and ...
0
votes
1
answer
151
views
Aqueduct failed to execute db migration file
I'm trying to learn Dart and Aqueduct. I'm following the Aqueduct tutorial. Up to now everything worked ok. But when connecting to the database I get an error.
I'm using:
Windows 10
PostreSQL 13
Dart ...
0
votes
1
answer
315
views
aqueduct db upgrade can't connect to database
windows 10
postgres version - 13.0
aqueduct version - 3.3.0+1
created the database and user correctly
created the migration
I can connect to database using psql.
postgresql.conf contains ...
0
votes
1
answer
341
views
aqueduct db upgrade cannot connect to database
I have problem with connecting my aqueduct server to postgres database.
Informations and things i have done:
postgres version is 13.0
system is Windows 10
I am using AndroidStudio and internal ...
-3
votes
2
answers
171
views
Why can't I install this aqueduct
Why can't I install this aqueduct?
Although I have installed dart before as shown in the picture:
0
votes
1
answer
156
views
Aqueduct server quits working after upgrading to 4.0.0
I upgraded Dart to 2.8.4 and Aqueduct to 4.0.0-b1.
On the linux server I was starting the server with a daemon like this:
[Unit]
Description=My server
[Service]
User=web
WorkingDirectory=/home/web/...
5
votes
4
answers
721
views
Aqueduct db generate error: Bad state: NoSuchMethodError: The getter 'length' was called on null
On the system:
Dart VM version: 2.9.0-14.0.dev.flutter-2b917f5b6a (be) (Wed Jun 10 15:46:47 2020 +0000) on "windows_x64"
It is OK when run "aqueduct db generate" to create ...
0
votes
1
answer
771
views
aqueduct : how to solve Bad state: No element error
when I followed the steps to create new project of aqueducts at Getting Started with Aqueduct I got error when I create a new project
Error :
C:\Users\khalifa>aqueduct create store1
-- Aqueduct CLI ...
0
votes
0
answers
210
views
Why does Dart have so many silent runtime exceptions/errors?
I have been getting very frustrated with Dart as runtime exceptions seem to fail silently. Program execution will continue after some type of failure and leave me totally stumped about what is not ...
3
votes
1
answer
423
views
Cannot create a aqueduct project
This is the error I get when I run aqueduct create project. Aqueduct is activated.
-- Aqueduct CLI Version: 3.3.0+1
*** Uncaught error
Bad state: No element
**** Stacktrace
* #0 ...
0
votes
1
answer
716
views
Cannot create Aqueduct project from command line
So I installed the aqueduct package using pub global activate aqueduct, and I added the directory of the pub bin to the Path in environment variables. However, when I try to create a new project by ...
0
votes
1
answer
59
views
Struggling with type Document on seeding. There was an issue. Reason: Could not infer type of value
I have an column defined like this:
@Column(nullable: true)
Document openHours; // List "openHours": ["Tuesday - Sunday: 11.00 - 21.00"],
In my migration file i use seed():
@override
Future seed() ...
-1
votes
1
answer
50
views
Add additional properties to response
Using addResponseModifier is it possible to fetch user property and add it to the response body, before the final response?
https://pub.dev/documentation/aqueduct/latest/aqueduct/Request/...
0
votes
0
answers
403
views
Dart aqueduct Error: Not found: 'dart:html'
I have been using aqueduct for a simple server that if it gets HTTP request, analyze it, and send an HTTP request to other apps. However, whenever I tried to import dart:HTML, it gives an error.
-- ...
0
votes
1
answer
42
views
When using aqueduct is oauth appropriate to authorize access to html pages
I am serving up HTML pages with Aqueduct and I would like the authorization of accessed pages to work without setting manually the authorization header with javascript for each link. How is this done?
...
4
votes
2
answers
890
views
How can I deploy aqueduct application to web hosting plan using cpanel?
HI im very new to back end and Im learning aqueduct since I know dart programming. My question is how can I deploy the aqueduct to my webserver? I have a hosting plan to a2hosting which Im currently ...
3
votes
2
answers
2k
views
How to downgrade Dart with Homebrew
I'm on a Mac and I upgraded to Dart 2.8 from Dart 2.7.1 by running
brew upgrade dart
as it describes in the documentation.
However, version 2.8 contains some breaking changes for the Aqueduct ...
0
votes
1
answer
659
views
Aqueduct: IsolateSpawnException: Unable to spawn isolate
When I try to generate a migration file in Aqueduct
aqueduct db generate
I get the following error
IsolateSpawnException: Unable to spawn isolate ...
I'm running Aqueduct 3.2.1.
How do I fix ...
1
vote
1
answer
190
views
Downgrade migration version in aqueduct
Is there any way to downgrade migration version in aqueduct. Problem is if I delete migration file which is no longer needed then by running
aqueduct db generate
it will create migration version ...
1
vote
1
answer
375
views
Register to aqueduct backend from Flutter frontend
I'm having a bit of difficulty with registering to aqueduct backend from my Flutter frontend
Here is my code in my frontend:
Future<void> signUp(String email, String password) async {
...
2
votes
2
answers
1k
views
RangeError: Invalid value: Not in range 0..1114111, inclusive: -1 when trying to use upgrade command
aqueduct db upgrade....
-- Aqueduct CLI Version: 3.3.0
-- Aqueduct project version: 3.3.0-b1
*** Uncaught error
RangeError: Invalid value: Not in range 0..1114111, inclusive: -1
**** Stacktrace
...
1
vote
1
answer
74
views
Aqueduct - How to save client data without the user ID in my backend
How can I save data for a user when I don't know their user ID? I want to save it in my Aqueduct back end so I can protect and query current user data?
@Operation.post()
Future<Response> ...
2
votes
1
answer
1k
views
sign in The method '_mulFromInteger' was called on null
I've got sign in methode in my provider.
Future<void> signIn(
String email, String password, BuildContext context) async {
SharedPreferences sharedPreferences = await ...
2
votes
1
answer
446
views
Passing user id with AuthController
I just made simple authentication app using aqueduct as a back end. I used codes from aqueduct documentation pages for login and registering. When I login with this code in backend
router
.route(...
0
votes
0
answers
203
views
Aqueduct authentication requests {"error":"invalid_client"}
I try to set up authentication via oauth 2.0 in my aqueduct app. I have followed step by step tutorial at aqueduct.io addjusting it to my app.
Unfortunately I have stuck after creating client at ...
12
votes
4
answers
10k
views
zsh: command not found: pub
I'm getting this error message when try to install aqueduct on macOS Catalina with this command.
pub global activate aqueduct
I managed to install it by putting flutter in front of it but now I ...
1
vote
0
answers
108
views
Axios fetch token from dart's aqueduct
Using javascript axios am trying to fetch a token from dart's aqueduct.
https://aqueduct.io/docs/auth/controllers/ aqueduct uses oauth2 specification on the backend, and it has sample code for ...
0
votes
1
answer
85
views
Files served with Aqueduct don't have a Content-Length header
I am writing a backend for my Flutter app using Aqueduct. I have Aqueduct set up so that Nginx proxies requests to it like this:
server {
root /home/web/my_server/web;
index index.html index....
0
votes
2
answers
639
views
Error: Getter not found: 'defaultType'. aqueduct , dart, vscode
I just started with Aqueduct for creating APIs.
I encountered with some error while running aqueduct serve in VS Code terminal
-- Aqueduct CLI Version: 3.2.1
-- Aqueduct project version: 3.3....
1
vote
1
answer
59
views
Change naming strategy in Aqueduct ORM
Is it possible to setup Aqueduct ORM to use underscored names for database columns (so if I have field "someField" in model class it will be stored as "some_field" in the database)? Or may be it is at ...
1
vote
1
answer
174
views
Creating a middleware controller to handle all requests to Aqueduct in Dart
I want to make a logger that will log certain information from every request to the database. I know how to make a controller and I could link it to every route like this:
@override
Controller ...
0
votes
1
answer
205
views
Unhandled Exception: Exception: {error: entity validation failed, reasons: [invalid input type for 'brand']}
I'm trying to pass a Json body inside a Json body using flutter.
The function is as follow:
Future<String> postItem(Item item, Brand brand) async {
var jsonob = jsonEncode(<String, ...
1
vote
1
answer
964
views
How to get filename in multipart post request using Dart/Aqueduct
I am trying to upload image from client (flutter) to server (Aqueduct.io) using MultipartRequest.
It's working, but currently file names are assigned the current time, how can I pass the filename from ...
0
votes
1
answer
127
views
Question about ldap in dart, can we create aqueduct API with ldap authen?
Im newbie in flutter and code, Im using Aqueduct to create API. Now i want to use ldap server to authen my app, i search about dartdap and it can run good in flutter app, but how to create an API with ...
0
votes
1
answer
405
views
How to connect Dart Aqueduct API with Google Firestore?
I want to connect Aqueduct API with Google Firestore and perform Post/Get operations via API to Firestore.
1
vote
1
answer
355
views
How to get the IP address of a client request in an Aqueduct Dart server
I'm making an Aqueduct server. I'd like to know the IP address of the client request for monitoring logs and for providing general location based content.
In Aqueduct I don't see how to get the IP ...
0
votes
1
answer
79
views
Aqueduct framework fetch Query where by document
@Operation.get()
Future<Response> getAllCoworking({@Bind.query('l') String location}) async {
final query = Query<Coworking>(context);
/*if (location != null) {
query.where(...