npwd icon indicating copy to clipboard operation
npwd copied to clipboard

Bug: "Failed to create your profile" when posting a tweet with image

Open Nanorithm opened this issue 2 years ago • 2 comments

Development Issue

Unsure

Phone Version

latest

Issue Description

I am on the latest release version of npwd, I set up discord webhook for image uploads and that seems to be working just fine by itself to take pictures with the camera app.

Upon further inspection it looks like when uploading from the phone's camera roll, it sets the URL as https://media.discordapp.net/attachments/ which doesn't work, but https://cdn.discordapp.com/attachments/ does work.

Issue Reproduction

  1. configure discord webhook as outlined in the documentation
  2. open twitter app
  3. new tweet
  4. attach image
  5. post tweet
  6. see error

Evidence

image

my config.json for reference:

{
	"PhoneAsItem": {
		"enabled": true,
		"exportResource": "qb-npwd",
		"exportFunction": "HasPhone"
	},
	"general": {
		"useResourceIntegration": true,
		"toggleKey": "f1",
		"toggleCommand": "phone",
		"defaultLanguage": "en"
	},
	"profanityFilter": {
		"enabled": false,
		"badWords": ["esx"]
	},
	"database": {
		"useIdentifierPrefix": false,
		"playerTable": "players",
		"identifierColumn": "citizenid",
		"identifierType": "license",
		"profileQueries": true,
		"phoneNumberColumn": "phone_number"
	},
	"debug": {
		"level": "error",
		"enabled": true,
		"sentryEnabled": true
	},
	"defaultContacts": [],
	"disabledApps": [],
	"apps": [
		"npwd_services",
		"npwd_qb_mail",
		"npwd_qb_banking",
		"npwd_qb_housing",
		"npwd_qb_racing"
	],
	"voiceMessage": {
		"enabled": false,
		"authorizationHeader": "PE-Secret",
		"url": "",
		"returnedDataIndexes": ["url"]
	},
	"images": {
		"useWebhook": true,
		"imageEncoding": "jpg"
	},
	"twitter": {
		"showNotifications": true,
		"generateProfileNameFromUsers": true,
		"allowEditableProfileName": true,
		"allowDeleteTweets": true,
		"allowReportTweets": true,
		"allowRetweet": true,
		"characterLimit": 160,
		"newLineLimit": 10,
		"enableAvatars": true,
		"enableEmojis": true,
		"enableImages": true,
		"maxImages": 3
	}
}

Nanorithm avatar Jan 14 '23 06:01 Nanorithm

I'm having the same error here

KaiKingStreams avatar Jul 05 '23 06:07 KaiKingStreams

same issue here, any fixes?

tris-ten avatar Jul 25 '23 05:07 tris-ten