Bluesky app fork with some witchin' additions 💫
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

Log post creation failures (#2205)

authored by

Eric Bailey and committed by
GitHub
a0d006a1 1111108e

+12
+6
src/lib/api/index.ts
··· 104 104 105 105 // add image embed if present 106 106 if (opts.images?.length) { 107 + logger.info(`Uploading images`, { 108 + count: opts.images.length, 109 + }) 110 + 107 111 const images: AppBskyEmbedImages.Image[] = [] 108 112 for (const image of opts.images) { 109 113 opts.onStateChange?.(`Uploading image #${images.length + 1}...`) 114 + logger.info(`Compressing image`) 110 115 await image.compress() 111 116 const path = image.compressed?.path ?? image.path 112 117 const {width, height} = image.compressed || image 118 + logger.info(`Uploading image`) 113 119 const res = await uploadBlob(agent, path, 'image/jpeg') 114 120 images.push({ 115 121 image: res.data.blob,
+6
src/view/com/composer/Composer.tsx
··· 62 62 import {useComposerControls} from '#/state/shell/composer' 63 63 import {emitPostCreated} from '#/state/events' 64 64 import {ThreadgateSetting} from '#/state/queries/threadgate' 65 + import {logger} from '#/logger' 65 66 66 67 type Props = ComposerOpts 67 68 export const ComposePost = observer(function ComposePost({ ··· 228 229 }) 229 230 ).uri 230 231 } catch (e: any) { 232 + logger.error(e, { 233 + message: `Composer: create post failed`, 234 + hasImages: gallery.size > 0, 235 + }) 236 + 231 237 if (extLink) { 232 238 setExtLink({ 233 239 ...extLink,