Changing uploader for Flutter/Dart on same machine - dart

I created package and uploaded via an account. i.e. uploader#outlook.com. I did not want to upload via this email address so I did:
pub uploader add new_uploader#outlook.com
Then I did
pub uploader remove uploader#outlook.com
The package displays correctly new_uploader#outlook.com now but I cannot figure out when I need to do a publish to use the new_uploader#outlook.com account. When I try:
flutter packages pub publish
It gives me this error:
UnauthorizedAccess: Unauthorized user: uploader#outlook.com is not allowed to upload versions to package flutter_platform_widgets.
pub finished with exit code 1
How do I tell flutter cli or the pub cli to use new_uploader#outlook.com and not uploader#outlook.com.
Both are google authorised accounts.
Also trying to do:
pub uploader add uploader#outlook.com
Gives an Unauthorized error.
Note: email addresses are not real, just for the purpose of the post

I did find the following as suggested by https://github.com/dart-lang/sdk/issues/14055
Delete the credential file:
.pub_cache/credentials.json
After doing this it asked for reauthentication which I used the new email address. I successfully uploaded the package with that email address.
Problem solved for me

Related

How do I log out from Dart's pub package manager?

I have uploaded packages to pub.dartlang.org under two different accounts (one of them work-related, the other personal).
The pub command line tool doesn't have any option to select with which account to publish, so once I log on with the tool, and try to upload a package that belongs to the other account, I see:
$ pub publish
UnauthorizedAccess: Unauthorized user: ___#example.com is not allowed to upload versions to package xyz..
How do I publish with a specific account? Failing that, how do I log out the pub tool in order to log on again under a different account?
There is currently no way in the command line pub tool to upload under different credentials (although there is a proposal).
If you have a fairly recent version of pub, you can log out with:
$ pub logout
Then try pub publish again. The tool will ask you for new credentials.
Could not find a command named "logout".
The pub logout command is an addition from January 2019. If pub tells you this command doesn't exist, you'll have to manually remove the credentials file.
$ rm ~/.pub-cache/credentials.json
If you want to temporarily publish with different credentials you can use a command like:
PUB_CACHE=~/.other_credentials_cache pub publish
This will create a entirely separate "profile" which is used whenever running any pub command with the PUB_CACHE environment variable pointing to a directory other than ~/.pub_cache. If you were to pub get with this cache you'd get entirely separate package downloaded.
With this approach you can toggle between credentials by specifying or not specifying the different cache directory. You'll need to authenticate the first time you use the new directory.

Migration from parse to azure not working for mobile app

i have migrated my iOS app parse DB to Azure, but had not finalised it yet.
I have changed end point to azure URL and its almost fine i mean i can login with my previous accounts.
But when i am querying anything to fetch or update data it giving me errors in response like:
[Error]: {"code":1,"message":"Internal server error."} (Code: 1, Version: 1.13.0)
[Error]: Response status code was unacceptable: 404
[Error]: This user is not allowed to access non-existent class: user (Code: 119, Version: 1.13.0)
Can anybody help me here that, will it be possible to update or fetch data to azure only after i finalize at parse migration or still there is something which i need to update from my code?
I had this issue. You just need to go to the parse dashboard and create the class
I found the solution from azure document.
I was getting error for fetching parse's PFFile object, and for that i need to add file key in azure settings. the value for the key can be find from azure settings.
image of azure settings
You can create a class in the ParseDashboard which will fix the problem. I was not able to open parse dashboard in browser (Only allowed remote https connection). I had to start it locally and finally was able to open the dashboard. Then i created the class there and it fixed my problem.
To launch the dashboard locally run the following commands
npm install -g parse-dashboard
and
parse-dashboard --appId yourAppId --masterKey yourMasterKey --serverURL "https://example.com/parse" --appName optionalName

Xcode CI and cocoapods private repo

I've been trying to setup OSX server to use Xcode CI. My project uses cocoapods and a private repo. I've been following this tutorial: http://papaanton.com/setting-up-xcode-6-and-apple-server-4-0-for-continues-integration-with-cocoapods/
But when I login as the _xcsbuildd user and run the command to add the private repo I get the following error message
fatal: could not create work tree dir '<repo name>': permission denied
I don't have much experience with users and command line tools. I've seen many comments online saying people need to change permissions to get it to work. But I have no idea what I need to change and where.
Can anyone tell me where / what / how I need to modify to give this user access to complete this process.
Just found the answer. Had no idea where cocoapods was storing these repos. I opened finder. Cmd + shift + g
typed in ~/.cocoapods/repos
right click on the repos folder and give "everyone" read & write access to the folder. All good now, CI working completely

Deployd setting up email

Hi I have a deployd application that is working fine with its dashboard localhost:2403/dashboard
I want to utilise email with the app the deployd instructions state that I run npm install dpd-email
which creates a dpd-email directory in your app's node_modules directory.
To set up the emails ports etc
Before using the email resource, you must go to its Dashboard page and configure it.
Is this the apps dashboard as I can see no reference to email in localhost:2403/dashboard
or is there a seperate dashboard for dpd-email module ?
After installing the dpd-email module (npm install dpd-email), the dashboard should propose a new type a resource:
After adding this new resource, you can configure the module:
You can send emails by sending requests (see the readme of the module for more information)

dart pub package upload user?

I've recently started using a new development machine and when I try to upload my pub package it fails saying "You aren't an uploader for package '\name\'." I've had a look on the pub site but haven't found away for me to find out A) who it thinks I am and B) how to give my current user access.
What is the package name?
You can take a look at the command pub uploader to modify your local uploader settings.

Resources