Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
Johannes Milke
@JohannesMilke_twitter
Hello! I have created another video about "What is the BuildContext? (Flutter Builder Widget)" https://www.youtube.com/watch?v=upOiX1zrh9Y alt
Johannes Milke
@JohannesMilke_twitter
Hello! I have created another video about "Flutter Glass Morphism | Glass Effect" https://www.youtube.com/watch?v=WxP9ABzfgow alt
zzterrozz
@zzterrozz

I am facing an issue when I use firebase to authenticate with GCP Secret Manager in Flutter:

[VERBOSE-2:ui_dart_state.cc(209)] Unhandled Exception: Null check operator used on a null value
#0      clientViaApplicationDefaultCredentials (package:googleapis_auth/auth_io.dart:77:49)

On Mac I launch in iTerm:

export GOOGLE_APPLICATION_CREDENTIALS="PATH_TO_JSON_FILE/service-account-file.json"

Then my code is:


import 'package:googleapis/secretmanager/v1.dart';
import 'package:googleapis_auth/auth_io.dart' as auth;
import 'package:googleapis/firestore/v1.dart';

final client = await auth.clientViaApplicationDefaultCredentials(scopes: [FirestoreApi.cloudPlatformScope]);
final api = SecretManagerApi(client);
final secrets = await api.projects.secrets.versions.access('my_secret_key');
print(secrets.payload!.data.toString());

When I launch the app, I have Platform.environment['GOOGLE_APPLICATION_CREDENTIALS']: null

What is the proper ways to set this variable?

Johannes Milke
@JohannesMilke_twitter
Hello! I have created another video about "Flutter: Set Screen Background Image" https://www.youtube.com/watch?v=Yv4IvqKgWBE alt
Rohit Chandra
@Rohit-Chandra-007
how to remove padding from raw material button
Johannes Milke
@JohannesMilke_twitter
Hello! I have created another video about "Flutter Operators (Collection, Spread, Cascade Operators)" https://www.youtube.com/watch?v=Axj7CeU0nVE alt
Rohan sengupta
@RohanSengupta326

I am trying to copy an image file from app's Documents directory to assets folder in Flutter.

CODE SNIPPET:
Directory appDocumentsDirectory = await getApplicationDocumentsDirectory();
String appDocumentsPath = appDocumentsDirectory.path;

// copy to asset folder first
File sourceFile = File('$appDocumentsPath/${widget.basename}');
final copied = await sourceFile.copy('assets/images/${widget.basename}');
// copied file to assets folder

but its showing some error. Then how can i copy the imageFile ?

ERROR :
Restarted application in 4,309ms.
E/flutter ( 5930): [ERROR:flutter/lib/ui/ui_dart_state.cc(209)] Unhandled Exception: FileSystemException: Cannot copy file to 'assets/images/image1.png', path = '/data/user/0/com.example.photo_manager/app_flutter/image1.png' (OS Error: No such file or directory, errno = 2)

Hasan Kemal Türk
@kemalturk03
Hello everyone, How can I manage appLifeCycle in an app using provider state management?
Hasan Kemal Türk
@kemalturk03
Or as an alternative, can you suggest me how can I control if app is on background or is active or is paused?
Randal L. Schwartz
@RandalSchwartz
RiverPod hooks has a lifecycle hook and an onchange hook.
you should be using riverpod instead of provider anyway.
and that is information only. you cannot control foreground/background, or guarantee to continue running if backgrounded
@kemalturk03 ^^
Hasan Kemal Türk
@kemalturk03
hm I get it thanks a lot
but I found a package named flutter_fgbg. This will help me to understand user is on foregrounf
Randal L. Schwartz
@RandalSchwartz
yeah, although I find the riverpod hooks for this are built in and heavily tested and documented.
and you don’t have to remember to unsubscribe your stream when you leave the widget.
Hasan Kemal Türk
@kemalturk03
So, can I use flutter_hooks ato be implemented with stateless widgets as an alternative
Johannes Milke
@JohannesMilke_twitter
Hello! I have created another video about "Web Scraping with Flutter and HTTP Requests" https://www.youtube.com/watch?v=9ZfRE_DN9a0 alt
Johannes Milke
@JohannesMilke_twitter
Hello! I have created another video about "PARALLAX Scrolling Effect (Flutter Animation)" https://www.youtube.com/watch?v=EUli31dh6MM alt
Yash Dhoka
@YashmDhoka
Hello!
I'm making app to display a message to everyone at 5 am as a college project. I'm supposed to use firebase for it. I've developed the app in flutter. My problem is that I want to call a function written in dart in the js firebase functions file. How can I do that?
c_a-g_o
@c_a-g_o:matrix.org
[m]
skippy do
Innocent Tauzeni
@Telthem89
Anyone did unscrambled word app with Flutter
For example I wanna upload Word in firebase like OCNETNIN TO make it INNOCENT
Randal L. Schwartz
@RandalSchwartz
Probably only through brute force.
Generate all possible permutations. Then see if they are a valid word period.
Johannes Milke
@JohannesMilke_twitter
Hello! I have created another video about "Flutter Null Safety" https://www.youtube.com/watch?v=5Ro-CZ8Msno alt
Johannes Milke
@JohannesMilke_twitter
Hello! I have created another video about "Flutter ListView" https://www.youtube.com/watch?v=nDX638qatP0 alt
Darsh Kirtikumar Shah
@THALLIVA
image.png
Can such UI can be made in flutter?
ranjith
@ranjith-b
Johannes Milke
@JohannesMilke_twitter
Hello! I have created another video about "Flutter Common Widgets (Flutter Beginner/Intermediate)" https://www.youtube.com/watch?v=lat50F6Gjms alt
Andes Mts
@andesappal_gitlab
Hey @JohannesMilke_twitter I watched some of your videos trying to create a user document on Firestore from Firebase auth, but had no success.
Would you provide a Gist with that objetive?
This is what I have which does not create the user on Firestore:
image.png
variables:
image.png
@RandalSchwartz could you help me with any tips?
Andes Mts
@andesappal_gitlab
I need to copy the user once authenticated, into Firestore with the uid and email.
Andes Mts
@andesappal_gitlab
@JohannesMilke_twitter I would not like to only display the user and email on the homepage, but also write it to Firestore
rob_star
@jacobfung
Is there any way to connect metamask in flutter mobile?
Johannes Milke
@JohannesMilke_twitter
Hello! I have created another video about "Neon Light Button with Flutter" https://www.youtube.com/watch?v=gnmgoWYFoU8 alt
Daniel Ardison
@dardison
Hi guys, I was experimenting this error while downloading many images at once from firebase storage using http get thru downloadURL of the file: Connection closed before full header was received
I couldn't found much info about the issue in google, if if have any clues to share let me know, thanks
Johannes Milke
@JohannesMilke_twitter
Hello! I have created another video about "Beginning Flutter | Common Widgets" https://www.youtube.com/watch?v=ckDDXKSu3XQ alt
Sagar Jaiswal
@sagar448
Anyone know how to convert byte array into string? In python im using RNCryptor to encrypt stuff but I need to decrypt it in flutter but hex.decode gives a byte array however it needs to be a string