Code Monkey home page Code Monkey logo

extensions's People

Contributors

agau4779 avatar apascal07 avatar bkendall avatar cabljac avatar chrisbianca avatar dackers86 avatar dependabot[bot] avatar ehesp avatar elvisun avatar fredzqm avatar huangjeff5 avatar jauntybrain avatar jhuleatt avatar jmwski avatar joehan avatar kevinthecheung avatar laurenzlong avatar mbleigh avatar nguymichael avatar pavelgj avatar posiek07 avatar pr-mais avatar rachelsaunders avatar rafikhan avatar russellwheatley avatar salakar avatar taeold avatar tinaliang avatar yamankatby avatar yuchenshi avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

extensions's Issues

[FR] Add resized image names to original image meta info

[REQUIRED] Step 2: Extension name

This feature request is for extension: _ (storage-resize-images)

Add resized image names as meta info to the original image

To help discovering if resized images were created for an image add resized image path/name(s) as a meta information to the original image
Will help finding thumbnails without extra queries even with changing configurations.

[BUG] Define custom bucket for extention Resize Image

[REQUIRED] Step 2: Describe your configuration

Resize Image, default settings
set Bucket to name of any other bucket that is not your default

Deployment location Description
us-central1
Cloud Storage bucket for images Description
new-second-bucket
Sizes of resized images Description
128x128
Cloud Storage path for resized images (Optional) Description
Parameter not set
Cache-Control header for resized images (Optional) Description
Parameter not set

[REQUIRED] Step 3: Describe the problem

Cloud Storage Bucket is not clear on the naming convention
should it be "new-second-bucket" per "gs://new-second-bucket"
or <bucket>.<project>.appspot.com/
or something else?
needs to be clearer on how to define your custom bucket

Steps to reproduce:

Install new extention "Resize Image"
configure the bucket to match the url of the second or alternative bucket
ie "gs://new-second-bucket" to "new-second-bucket"
or other respectable forms

Expected result

it should use the defined bucket

Actual result

Error occurred while deploying resources: RESOURCE_ERROR: /deployments/firebase-ext-storage-resize-images/resources/generateResizedImage {"ResourceType":"gcp-types/cloudfunctions-v1:projects.locations.functions","ResourceErrorCode":"400","ResourceErrorMessage":{"code":400,"message":"The request has errors","status":"INVALID_ARGUMENT","details":[{"@type":"type.googleapis.com/google.rpc.BadRequest","fieldViolations":[{"field":"event_trigger.resource","description":"GCS bucket resource projects/_/buckets/https://console.cloud.google.com/storage/browser/new-second-bucket does not match the expected pattern, which is projects/{project}/buckets/{bucket}"}]}],"statusMessage":"Bad Request","requestPath":"https://cloudfunctions.googleapis.com/v1/projects/worldsbeyond-1/locations/us-central1/functions/ext-storage-resize-images-generateResizedImage","httpMethod":"PATCH"}}There was an unknown error while processing the request. Try again.

Resize Image: creates recursive resizes also for thumbnails

I activated the resize extention on my Storage bucket.
I have photos inside a folder in the storage.

When uploading a picture, the extension keeps creating thumb in thumb folders and images

folder has a file named: _200x200.jpg and another folder thumb inside which has the same content.

Extension and bucket are in Europe-West

Thank you,
Bogdan

[FR] delete-user-data: Delete subcollections

[REQUIRED] Step 2: Extension name

This feature request is for extension: delete-user-data

What feature would you like to see?

It would be helpful if the delete-user-data extension could delete all documents in subcollections as well.

How would you use it?

Often you would have one or more subcollections below a user profile document.
Example: /users/{UID}/stories or /users/{UID}/likes.

In this case it would be really nice if the extension could delete all documents in a specified subcollection, or maybe all documents in any subcollections (recursively). This is not trivial to implement, and therefore fits very nicely in the delete-user-data extension.

[FR] Make Translate Text even cooler!

[READ] Step 1: Are you in the right place?

Yes

[REQUIRED] Step 2: Extension name

This feature request is for extension: firestore-translate-text

What feature would you like to see?

I want Translate Text to get its own mascot! Perhaps an olympics bear?

How would you use it?

I would make stickers out of the new mascot.

Full-text Search

What feature would you like to see?

Full-text Search

How would you use it?

Currently, we'd have to use Algolia. It's not that hard to implement but having to manage both the data between Firebase and Algolia gives some sort of overhead. Maybe Firebase Extensions can bridge the two?

[Bug] Translate Text is too cool!

[READ] Step 1: Are you in the right place?

Issues filed here should be about bugs for a specific extension in this repository.
If you have a general question, need help debugging, or fall into some
other category use one of these other channels:

  • For general technical questions, post a question on StackOverflow
    with the firebase tag.
  • For general Firebase discussion, use the firebase-talk
    google group.
  • To file a bug against the Firebase Extensions platform, or for an issue affecting multiple extensions, please reach out to
    Firebase support directly.

[REQUIRED] Step 2: Describe your configuration

  • Extension name: firestore-translate-text
  • Configuration values (redact info where appropriate):
    • Languages: en,es,fr,de,it
    • Location: London
    • Collection: shoes
    • field: description

[REQUIRED] Step 3: Describe the problem

Steps to reproduce:

I installed it and it returned translated results!

[BUG] fs-bq-import-collection does not import private collections

[READ] Step 1: Are you in the right place?

Yes

[REQUIRED] Step 2: Describe your configuration

fs-bq-import-collection does not import collection that have the following security rule:

    match /private_collection/{userId}/{document=**} {
      allow read: if request.auth.uid == userId;
      allow write, create: if false;
    }

[REQUIRED] Step 3: Describe the problem

I am trying to import existing documents in a collection that can be read by the currently auth'ed user. However, the import script does not import any documents.

Finished importing 0 Firestore rows to BigQuery

Steps to reproduce:

  1. Create a collection with the security rule above.
  2. Add documents to the collection
  3. Run import script
Expected result

Existing data imported to BigQuery.

Actual result

No data imported to BigQuery.

Thanks for looking into this!

Make `firestore-counter` nodejs safe

[READ] Step 1: Are you in the right place?

Issues filed here should be about a feature request for a specific extension in this repository. To file a feature request that affects multiple extensions or the Firebase Extensions platform, please reach out to
Firebase support directly.

[REQUIRED] Step 2: Extension name

This feature request is for extension: firestore-counter

What feature would you like to see?

The current web client code is not safe for use in nodejs cloud function environment due to the reliance on document, specifically, document.cooke for the storage of the shard id.

How would you use it?

var sharded = require('sharded-counter')
...
I would expect that other folks have need to be able to update counters in a more secure fashion rather than exposed on the client. In my case, updating inventory counts.

Possible solution

I've already tested the below as a possible solution

change /extensions/firestore-counter/clients/web/src/index.ts to:

  function getShardId(cookie: string): string {
    const shardId = uuid.v4();
    // make node env friendly...
    if (typeof document !== 'undefined') {
      const result = new RegExp(
        "(?:^|; )" + encodeURIComponent(cookie) + "=([^;]*)"
      ).exec(document.cookie);
      if (result) return result[1];

      const date = new Date();
      date.setTime(date.getTime() + 30 * 24 * 60 * 60 * 1000);
      const expires = "; expires=" + date.toUTCString();

      document.cookie =
        encodeURIComponent(cookie) + "=" + shardId + expires + "; path=/";
    }
    return shardId;
  }

change: /extensions/firestore-counter/clients/web/webpack.config.js:

change: libraryTarget: 'var',
to:

   libraryTarget: 'umd',
   globalObject: 'this',

I can make the above as a PR since I've already done this locally for my testing to use.
I wanted to ask about this before just submitting a PR since you all might have a really good reason not to have a node friendly option that I'm not aware of - for example is there a terrible thing not to re-use shardId's?

Firebase extension for transactional mails

What feature would you like to see?

I see transactional e-mails as a common use case firebase users will implement. If this feature gets picked I'd be happy to contribute to its development. However I'd appreciate some guidelines as to how a function technically differs from an extension.

How would you use it?

In my company we currently use mailjet in combination with firebase functions. This is a minimal example to send welcome mails on authentication events, but other triggers could be useful as well.

firestore-bigquery-export schema type record for data?

[REQUIRED] Step 2: Extension name

firestore-bigquery-export

What feature would you like to see?

When browsing the records I noticed they return the payload in a catchall data field. If I want to query on this field as if it were parsed into a record from json what is the best practice here?

How would you use it?

Use big query more effectively on collection attributes.

Uninstall or change Deployment Location

Excelent extension the Resize Images, really usefull!

How can I uninstall it or change the location from US to Europe as to be near my storage bucket location?

Best regards,
Bogdan

[FR] Add option to make video and GIF thumbnails to the existing Resize Images extension or make a new extension

[READ] Step 1: Are you in the right place?

Issues filed here should be about a feature request for a specific extension in this repository. To file a feature request that affects multiple extensions or the Firebase Extensions platform, please reach out to
Firebase support directly.

[REQUIRED] Step 2: Extension name

This feature request is for extension: storage-resize-images

What feature would you like to see?

I would like to have an option to make it so that instead of just resizing GIFs, it would generate a still frame of that GIF.

Furthermore, extending the extension to be able to generate video thumbnails or making a new extension for that purpose would be greatly appreciated as well.

How would you use it?

This would greatly improve workflow for social platforms where users upload a mix of GIFs, images and video.

Firebase extension for STT

What feature would you like to see?

Similar to how there is an extension for Google Translate, I was wondering
if there are any plans to make an extension for Google Cloud Speech To Text?

I'd be happy to contribute to the open source development, if this gets picked up and there are some general directions on how to go about developing a firebase extensions etc..

I've already raised it through Firebase support directly, and they mentioned to raise it here as well.

How would you use it?

I'd use it to make Apps that have a transcription service component with Firebase, eg bbc/digital-paper-edit, autoedit2.

[BUG] Multiple thumbnails folder creation (critical)

[READ] Step 1: Are you in the right place?

yes

[REQUIRED] Step 2: Describe your configuration

  • Extension name: storage-resize-images

[REQUIRED] Step 3: Describe the problem

When uploading an image to the storage bucket, seemingly infinite thumbnails folders are created, which exceeded my quota for SocketConnectNonbillable within seconds.

Steps to reproduce:

Upload an image to storage bucket.

Expected result

Image should be resized inside one lowRes folder.

Actual result

The folder was created multiple times, each containing the resized image, which probably lead to my quota exceeding.

Logs i managed to get before my quota was exceeded:
(shortened paths with ... in order to make it more readable)

Function execution started
Billing account not configured. External network is not accessible and quotas are severely limited. Configure billing account to remove these restrictions
Started execution of extension with configuration { bucket: '[...]', cacheControlHeader: undefined, imageSizes: [ '200x200' ], resizedImagesPath: 'lowRes' }
Creating temporary directory: '/tmp/[...]/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes'
Created temporary directory: '/tmp/[...]/lowRes/.../lowRes'
Downloading image file: '[...]/lowRes.../lowRes/_200x200'
Downloaded image file: '[...]/lowRes/.../lowRes/_200x200' to '/tmp/[...]/lowRes/.../lowRes/_200x200'
Resizing image at path '/tmp/_200x200' to size: 200x200
Resized image created at '/tmp/_200x200'
Uploading resized image to '[...]/lowRes/.../lowRes/_200x200'
Uploaded resized image to '[...]/lowRes/.../lowRes/_200x200'
Deleting temporary resized file: '[...]/lowRes/.../lowRes/_200x200'
Deleted temporary resized file: '[...]/lowRes/.../lowRes/_200x200'
Completed execution of extension
Deleting temporary original file: '[...]/lowRes/.../lowRes/_200x200'
Deleted temporary original file: '[...]/lowRes/.../lowRes/_200x200'
Function execution took 465 ms, finished with status: 'ok'
Error: quota exceeded (Quota exceeded for quota group 'SocketConnectNonbillable' and limit 'CLIENT_PROJECT-100s' of service 'cloudfunctions.googleapis.com' for consumer 'project_number:[...]'.);

In conclusion, the cloud function was called ~500 times which can be seen in my statistics.
(I never used cloud functions before and only tried to upload an image two times)
Later i also got this error, probably as a result:

    at Util.parseHttpRespBody (/srv/node_modules/@google-cloud/common/build/src/util.js:191:38)
    at Util.handleResp (/srv/node_modules/@google-cloud/common/build/src/util.js:135:117)
    at retryRequest (/srv/node_modules/@google-cloud/common/build/src/util.js:423:22)
    at onResponse (/srv/node_modules/retry-request/index.js:206:7)
    at /srv/node_modules/teeny-request/build/src/index.js:158:17
    at <anonymous>
    at process._tickDomainCallback (internal/process/next_tick.js:229:7)
  code: 400,
  errors: 
   [ { domain: 'global',
       reason: 'invalid',
       message: 'The maximum object length is 1024 characters, but got a name with 1025 characters: \'\'[...]/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRe...\'\'' } ],
  response: undefined,
  message: 'The maximum object length is 1024 characters, but got a name with 1025 characters: \'\'[...]/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRes/lowRe...\'\'' }```

Error on cold start firestore-send-email

[READ] Step 1: Are you in the right place?

Issues filed here should be about bugs for a specific extension in this repository.
If you have a general question, need help debugging, or fall into some
other category use one of these other channels:

  • For general technical questions, post a question on StackOverflow
    with the firebase tag.
  • For general Firebase discussion, use the firebase-talk
    google group.
  • To file a bug against the Firebase Extensions platform, or for an issue affecting multiple extensions, please reach out to
    Firebase support directly.

[REQUIRED] Step 2: Describe your configuration

  • Extension name: firestore-send-email
  • Configuration values (redact info where appropriate):
    • all config require (extension is working, except after a cold start)

[REQUIRED] Step 3: Describe the problem

Steps to reproduce:

firestore-send-email throw an unhandled error at cold start :

Unhandled error occurred during processing: { Error
    at Http2CallStream.call.on (/srv/node_modules/@grpc/grpc-js/build/src/client.js:96:45)
    at emitOne (events.js:121:20)
    at Http2CallStream.emit (events.js:211:7)
    at process.nextTick (/srv/node_modules/@grpc/grpc-js/build/src/call-stream.js:71:22)
    at _combinedTickCallback (internal/process/next_tick.js:132:7)
    at process._tickDomainCallback (internal/process/next_tick.js:219:9)
  code: 13,
  details: '',
  metadata: Metadata { options: undefined, internalRepr: Map {} },
  note: 'Exception occurred in retry method that was not classified as transient' }
Expected result

Mail send / or send retry

Actual result

Mail not sent and not retried

Target languages field fails to accept one language

  • Extension name: firestore-translate-text
  • Configuration values (redact info where appropriate):
    • Target langs: ar

Steps to reproduce:

  1. Use the console or CLI to install the firestore-translate-text extension.
  2. In the target languages field list only one language for example ar
Expected result

I except for the target languages field to be able to accept ONE target languages

Actual result

The target languages field only accepts MORE than one language

image

OR

image

Send mails with custom headers with firestore-send-email extension

Extension name

firestore-send-email

What feature would you like to see?

the ability to add custom header in a mail

How would you use it?

We use Mandrill API to send emails and we can add some custom metadata to every message.

We can also add metadata sending email with Mandrill smtp but we need to pass them in the X-MC-Metadata header.

It would be great if we can specify in each message and at template level some headers to include in the message

[BUG] Image Resizing caught in infinite loop

My issue:

  • Extension name: storageresize-images
  • Configuration values (redact info where appropriate):
  • Defaults for all values except: sizes and cloud storage path
  • Sizes: 50x50,200x200,400x400,800x800
  • Cloud Storage Path: images

[REQUIRED] Step 3: Describe the problem

A few days ago I tried and the below occurred. I just tried again tonight and I'm facing the same issue, so figure this is the best place for this. I've just set the Resize Image extension up and the test run (just uploading an image) is causing an infinite loop of uploads and deletes (and error messages), where the newly resized images appear to be attempting to create new images, or something similar. My input for Cloud Storage path for resized images is images and this is leading to this error:

Deleting temporary resized file: 'images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/_200x200'

I'm currently seeing an issue where a single image is causing the function to run until it hits:

Error when resizing image { Error: Backend Error
...
code: 503,
errors:
[ { domain: 'global',
reason: 'backendError',
message: 'Backend Error' } ],
response: undefined,
message: 'Backend Error' }

Any ideas for a solution to this? I uninstalled the extension to stop the infinite loop but not sure how to make the extension run smoothly.

The only steps I've taken so far were the setup guide of accepting a few things and changing the path to images.

Steps to reproduce:

What happened? How can we make the problem occur?

Configure extension for images folder.
Upload image to images folder.
Watch logs explode!

Here's an example of the logs:

12:10:59.174 AM
ext-storage-resize-images-generateResizedImage
Function execution took 18269 ms, finished with status: 'ok'
12:10:59.169 AM
ext-storage-resize-images-generateResizedImage
Deleted temporary original file: 'images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/_50x50'
12:10:59.169 AM
ext-storage-resize-images-generateResizedImage
Deleting temporary original file: 'images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/_50x50'
12:10:59.169 AM
ext-storage-resize-images-generateResizedImage
Failed execution of extension
12:10:59.169 AM
ext-storage-resize-images-generateResizedImage
Deleted temporary resized file: 'images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/_50x50'
12:10:59.168 AM
ext-storage-resize-images-generateResizedImage
Deleting temporary resized file: 'images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/_50x50'
12:10:59.168 AM
ext-storage-resize-images-generateResizedImage
Uploaded resized image to 'images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/_50x50'
12:10:57.072 AM
ext-storage-resize-images-generateResizedImage
Function execution took 11315 ms, finished with status: 'ok'
12:10:57.058 AM
ext-storage-resize-images-generateResizedImage
Deleted temporary original file: 'images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/_50x50'
12:10:57.058 AM
ext-storage-resize-images-generateResizedImage
Deleting temporary original file: 'images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/images/_50x50'
12:10:57.058 AM
ext-storage-resize-images-generateResizedImage
Failed execution of extension
Expected result

Resized images at /images.

Actual result

Mayhem, as detailed above. I know the functionality is new, only let out into the wild 2 weeks ago! Definitely will be patient with it.*

Attach file in email when using trigger email extension.

[READ] Step 1: Are you in the right place?

Issues filed here should be about a feature request for a specific extension in this repository. To file a feature request that affects multiple extensions or the Firebase Extensions platform, please reach out to
Firebase support directly.

[REQUIRED] Step 2: Extension name

This feature request is for extension: firestore-send-email

What feature would you like to see?

If would like to be able to attach files when I use the send email extension.

How would you use it?

I want to send my users some files when they request them.

Mail subject encoding in firestore-send-email

[READ] Step 1: Are you in the right place?

Issues filed here should be about bugs for a specific extension in this repository.
If you have a general question, need help debugging, or fall into some
other category use one of these other channels:

  • For general technical questions, post a question on StackOverflow
    with the firebase tag.
  • For general Firebase discussion, use the firebase-talk
    google group.
  • To file a bug against the Firebase Extensions platform, or for an issue affecting multiple extensions, please reach out to
    Firebase support directly.

[REQUIRED] Step 2: Describe your configuration

  • Extension name: firestore-send-email
  • Configuration values (redact info where appropriate):
    • A working configuration

[REQUIRED] Step 3: Describe the problem

Steps to reproduce:

If the mail subject contains specials characters, they are printed in html code.

Expected result

Exemple :
A field name: "Jack o'neill" used in mail subject : "Welcome to {{name}}"should be printed Welcome Jack o'neill in mail subject.

Actual result

Welcome Jack o&#x27;neill

Maybe I miss something ?

PS : It works well in email's body

[FR] only storing resized image

[READ] Step 1: Are you in the right place?

yes

[REQUIRED] Step 2: Extension name

This feature request is for extension: storage-resize-images

What feature would you like to see?

I would like to only store the resized image.

How would you use it?

This could be useful for profile pictures, which are never seen in full resolution.

[FR]: firestore-limit-child-nodes

[REQUIRED] Step 2: Extension name

This feature request is for extension: firestore-limit-child-nodes

What feature would you like to see?

I would like a firestore-limit-child-nodes to be created, just like rtdb-limit-child-nodes.

How would you use it?

Same use-case as for rtdb-limit-child-nodes, but for Firestore.

firebaseStorageDownloadTokens from object metadata

[READ] Step 1: Are you in the right place?

Yes

[REQUIRED] Step 2: Extension name

This feature request is for extension: _ (storage-resize-images)

What feature would you like to see?

Any object on firebase storage contains firebaseStorageDownloadTokens from object metadata. However this is not available for resized images

How would you use it?

I use firebaseStorageDownloadTokens to construct the downloadUrl for the object

Resize Images: Missing original filename when uploaded file doesn't include a file extension

  • Extension name: storage-resize-images
  • Configuration values (redact info where appropriate):
    Resize Image, default settings
    set Bucket to name of any other bucket that is not your default
    Deployment location Description
    us-central1
    Cloud Storage bucket for images Description
    [bucket-name]
    Sizes of resized images Description
    200x200
    Cloud Storage path for resized images (Optional) Description
    Parameter not set
    Cache-Control header for resized images (Optional) Description
    Parameter not set

Describe the problem

When an image is uploaded to the storage bucket using the Firestore Javascript client library (I didn't test it with other libraries), if the image doesn't have an extension (e.g .jpg) in its filename, the name of the resized image is just "_200x200". It is missing the actual original filename. If multiple images are uploaded, each resized image overwrites the previous one because they all have the exact same "_200x200" as the filename.

Steps to reproduce:

1 - Setup Resize Images Firebase Extension using standard config settings.
2 - Use the Firebase Javascript library to upload an image with a filename that does not contain an extension (e.g. "uploaded_file") to the Firebase storage bucket.

Expected result

The filename of the resized image should contain the original filename with the size appended to the name.

Actual result

The filename of the resized image is just the file size without the original filename

[QUESTION] Using templates with Trigger Email extension

Hi,

Can you provide and example of how to use templates with Trigger Email extension ?

What I'm not sure about :

  • how to format the "template" collection in firestore
  • how can I define variables in the template
  • is it possible to use logic in template (if, else, loop, ...) (you specified Handlebar so I imagine the answer is yes)
  • how to pass variables and template name when creating an email

Some code example would be great :)

Thanks a lot

delete-user-data should allow for deleting by value

[READ] Step 1: Are you in the right place?

Yes

[REQUIRED] Step 2: Extension name

This feature request is for extension: delete-user-data

What feature would you like to see?

When setting up delete-user-data, it would be great if we could also delete items by a value. In the friendlymarket codelab for example, we store items in the forsale collection. Each item then contains the uid of the user in the seller field. The path here is forsale/{Item UID}/seller

Right now, the extension only allows us to delete items if the UID is part of the path. It would be great if we could also delete items that have a UID as a value.

How would you use it?

In the friendlymarket example, I could delete all items a user is selling when the user wants their account deleted

Allow multiple documents for "Trigger Email" extension

[READ] Step 1: Are you in the right place?

Issues filed here should be about a feature request for a specific extension in this repository. To file a feature request that affects multiple extensions or the Firebase Extensions platform, please reach out to
Firebase support directly.

[REQUIRED] Step 2: Extension name

This feature request is for extension: **\firestore-send-email

What feature would you like to see?

Allow multiple collections to trigger emails. I tried adding "mail, contactMe" and got the following message:
Error installing. Some extension resources may not be fully provisioned or ready to use.

How would you use it?

Multiple collections to trigger emails through comma separated list.

Resize Image too cool!

OMG I know this is not a BUG or REPORT post but I gotta let the team behind this knows that this extensions works very wonderful. Tried upload a JPG image of 787kB and after a refresh it resize the size to a freaking 13kB! That's a massive reduction of pixel as well as sizes. I wonder what happens if I reupload all my WEBP format.

firestore-bigquery-export fs-bq-import-collection doesn't allow {widecard} path

[READ] Step 1: Are you in the right place?

Issues filed here should be about bugs for a specific extension in this repository.
If you have a general question, need help debugging, or fall into some
other category use one of these other channels:

  • For general technical questions, post a question on StackOverflow
    with the firebase tag.
  • For general Firebase discussion, use the firebase-talk
    google group.
  • To file a bug against the Firebase Extensions platform, or for an issue affecting multiple extensions, please reach out to
    Firebase support directly.

[REQUIRED] Step 2: Describe your configuration

  • Extension name: firestore-bigquery-export
  • Configuration values (redact info where appropriate):
    • fs-bq-import-collection

[REQUIRED] Step 3: Describe the problem

Steps to reproduce:

  1. Clone this repo.
  2. Go to extensions/firestore-bigquery-export/scripts/import and install dependencies (npm install)
  3. Execute npm run import
  4. Pass the ${PROJECT_ID}
  5. Try pass a widecard path as described on docs, like chats/{chatid}/posts
  6. Get an error: >> The collection path must only contain letters or spaces
Expected result

Allow widecard paths to import.

Actual result

Get an error: >> The collection path must only contain letters or spaces

firestore-bigquery-export fs-bq-import-collection import script not found

Step 2: Describe your configuration

  • Extension name: firestore-bigquery-export

Step 3: Describe the problem

In the IMPORT_EXISTING_DOCUMENTS.md guide there is guide to run Run npx @firebaseextensions/fs-bq-import-collection script. This gives an error:

404 @firebaseextensions/fs-bq-import-collection@latest' is not in the npm registry.

Steps to reproduce:

run

npx @firebaseextensions/fs-bq-import-collection@latest

Expected result

runs the script

Actual result

npm ERR! 404 Not Found - GET https://registry.npmjs.org/@firebaseextensions%2ffs-bq-import-collection - Not found

Resize image trigger based on Firestore document

[READ] Step 1: Are you in the right place?

Issues filed here should be about a feature request for a specific extension in this repository. To file a feature request that affects multiple extensions or the Firebase Extensions platform, please reach out to
Firebase support directly.

[REQUIRED] Step 2: Extension name

storage-resize-images

What feature would you like to see?

Image auto resize based on Firestore/Realtime Database document creation/update.

How would you use it?

When a user uploads a profile image, I save the image path on the document of the user in either Firestore or Realtime Database, I would like to run the resize extension, but attach the downloadURL for the new resized image to the document as well, either overwriting the parameter for the original image, or have the option to create a new parameter for the thumbnail.

Ensure that firestore-counter only writes to max 100 documents inside a single transaction

[READ] Step 1: Are you in the right place?

Issues filed here should be about a feature request for a specific extension in this repository. To file a feature request that affects multiple extensions or the Firebase Extensions platform, please reach out to
Firebase support directly.

[REQUIRED] Step 2: Extension name: firestore-counter

Currently, in the worst case, firestore-counter will act on 499 documents at once since that's the shard limit. (https://github.com/firebase/extensions/blob/master/firestore-counter/functions/src/worker.ts#L32). This is not recommended by the Firestore team. A transaction will have decreased performance if it writes/deletes more than 100 documents inside a transaction.

The code needs to be modified to ensure no more than 100 documents are touched inside a single transaction. It might require changing the number of plans: https://github.com/firebase/extensions/blob/master/firestore-counter/functions/src/worker.ts#L186

[BUG] name of resized image is missing original image name if there was no file type extension

[READ] Step 1: Are you in the right place?

Yes

[REQUIRED] Step 2: Describe your configuration

  • Extension name: _ (storage-resize-images)
  • Configuration values (redact info where appropriate):
    -Size:64x64
    -Cloud Storage Path: empty

[REQUIRED] Step 3: Describe the problem

I just added storage-resize-images extension to my firebase project, it is working as expected when i upload an image manually from the firebase console, but the problem is that whenever i use

storageRef.putString()

function to upload base64 url encoded image to the firebase storage cloud, the compressed image will be created but its name is only _64x64 (not original_64x64).

Obviously i am resizing images as 64x64.

Since the created file doesn't contain a unique name it is unaccessible for me dynamically...Is there something am i missing?

Steps to reproduce:

Install storage-resize-images extension to my firebase project.(web)

Expected result

storage-resize-images extension to create an image file using the "original.jpeg" image as "original_64x64.jpeg"

Actual result

The extension generated the image as expected but the naming was wrong, it is _64x64.jpeg instead of original_64x64.jpeg

Fix vulnerability alerts by updating dependencies

[READ] Step 1: Are you in the right place?

Issues filed here should be about a feature request for a specific extension in this repository. To file a feature request that affects multiple extensions or the Firebase Extensions platform, please reach out to
Firebase support directly.

[REQUIRED] Step 2: Extension name

Multiple

What feature would you like to see?

Fix vulnerability alerts by updating some dependencies: https://github.com/firebase/extensions/network/alerts

How would you use it?

Tell us how you'd use this feature in your app.

Resize Image: Extension from contentType

Extension name: Resize-Images

This feature request is for extension: storage-resize-images

What feature would you like to see?

Currently, the file extension is being read from the original file name. If no file extension is provided, the type should be read from the image contentType to generate the new image.

Appending the extension to the resulting resized images should be conditional based on if the original name included the extension.

It is possible that this feature will solve issue 20. I experienced the same issue when I first uploaded files w/o extensions.

How would you use it?

Store images keyed off of a field in a db w/o having the manage the image file type.

ResizeImage fails with valid filenames

[READ] Step 1: Are you in the right place?

Issues filed here should be about bugs for a specific extension in this repository.
If you have a general question, need help debugging, or fall into some
other category use one of these other channels:

  • For general technical questions, post a question on StackOverflow
    with the firebase tag.
  • For general Firebase discussion, use the firebase-talk
    google group.
  • To file a bug against the Firebase Extensions platform, or for an issue affecting multiple extensions, please reach out to
    Firebase support directly.

[REQUIRED] Step 2: Describe your configuration

  • Extension name: _ (storage-resize-images, firestore-send-email, etc)
  • Configuration values (redact info where appropriate):
    • _
    • _

[REQUIRED] Step 3: Describe the problem

Steps to reproduce:

What happened? How can we make the problem occur?

It works for simple filenames like "foo.jpg"
but fails for filenames like " 4D44HulplLt35S6VDbf22:2019-03-18T16:58:41.123-05:00.jpg"

TypeError: Cannot read property 'startsWith' of undefined at Object.exports.isImage (/srv/functions/lib/validators.js:18:48) at Object.<anonymous> (/srv/functions/lib/index.js:46:32) at Generator.next (<anonymous>) at /srv/functions/lib/index.js:22:71 at new Promise (<anonymous>) at __awaiter (/srv/functions/lib/index.js:18:12) at exports.generateResizedImage.functions.storage.object.onFinalize (/srv/functions/lib/index.js:43:82) at cloudFunctionNewSignature (/srv/node_modules/firebase-functions/lib/cloud-functions.js:120:23) at /worker/worker.js:825:24 at <anonymous>

This could be a description, log/console output, etc.

Expected result
Actual result

Delete User Data not deleting data in Cloud Firestore

Describe your configuration

  • Extension name: Delete User Data
  • Configuration values:
    • Cloud Firestore path: users/{UID}
    • Realtime Database and Cloud Storage: unspecified

Cloud Firestore structure: /users/{UID}/

Describe the problem

Regardless of whether I delete a user from the console or the client (Android app), the user's document nor any sub-collections/documents are deleted. This occurs whether the user is created via the console or the client.

Function logs indicate that it finishes with status OK.

Counter SDK for backend services like "node.js"

Extension name

This feature request is for extension: \firestore-counter

What feature would you like to see?

Make the sharded-counter.js work not only for the frontend but for backend services like node.js. This requirement includes not to depend on requiring / importing firebase/app and firebase/firestore in the user code, but on the SDK code instead.

How would you use it?

In our case, we use a backend service to make our web site cleaner and lighter without Firebase SDK, so, all the usage of Firebase occurs in the backend. We would like to use the counter so that's why we need to use it on the backend.

Resize Images - Firebase Storage Bucket Names Invalid

Expected behaviour:
Able to enter the name of firebase storage buckets in the extension configuration as they appear in the firebase console.

Actual behaviour:
'Invalid storage bucket' warning in extension configuration for names of storage buckets created in the firebase console. 'Install extension' button is not in a disabled state but does not respond in this scenario.

Further notes:
The firebase-admin sdk works perfectly well with storage names as they are entered when creating a new bucket in the console / displayed in the firebase console. It seems odd that you would restrict what can be entered in the extension configuration with validation rules different to whatever is used for creating buckets in the first place.

firestore-bigquery-export failing

  • Extension name: firestore-bigquery-export

I have installed the Export Collections to BigQuery extension and it works fine however now I am attempting to import my existing data using firestore-bigquery-export by following the instructions here:
https://github.com/firebase/extensions/blob/master/firestore-bigquery-export/guides/IMPORT_EXISTING_DOCUMENTS.md

However I am getting the error detailed below.
Note: I get exactly the same error even if I enter a firebase projectid or collection that does not exist.

This may be an local environment issue, if so and this is not an appropriate place for this issue please let me know and close it.

$ node -v
v12.13.0

$ npm -v
6.12.0

Steps to reproduce:

Run: npx @firebaseextensions/fs-bq-import-collection
Enter the ${PROJECT_ID}, ${COLLECTION_PATH} and ${DATASET_ID} parameters as follows:
my-fb-project-id, members, qmtbc_dev_export

Expected result

Collection imports successfully into BigQuery

Actual result

Error returned:

Importing data from Cloud Firestore Collection: members, to BigQuery Dataset: qmtbc_dev_export, Table: members_raw_changelog
Error unlinking journal file C:\Users\fullo\AppData\Roaming\npm-cache\_npx\10884\node_modules\@firebaseextensions\fs-bq-import-collection\lib/from-members-to-qmtbc-dev:qmtbc_dev_export:members_raw_changelog
after successful import: Error: ENOENT: no such file or directory, unlink 'C:\Users\fullo\AppData\Roaming\npm-cache\_npx\10884\node_modules\@firebaseextensions\fs-bq-import-collection\lib\from-members-to-qmtbc-dev:qmtbc_dev_export:members_raw_changelog'
---------------------------------------------------------
Finished importing 0 Firestore rows to BigQuery
---------------------------------------------------------
Error importing Collection to BigQuery: Error: EPERM: operation not permitted, unlink 'C:\Users\fullo\AppData\Roaming\npm-cache\_npx\10884\node_modules\@firebaseextensions\fs-bq-import-collection\node_modules\grpc\src\node\extension_binary\node-v64-win32-x64-unknown\grpc_node.node'

Also I looked at the script here:
https://github.com/firebase/extensions/blob/master/firestore-bigquery-export/scripts/import/src/index.ts

And the error is being generated at line 187.
It looks like it may throw this error if no data is found or if can't access the project/collection.

[BUG] resized images not named properly

[READ] Step 1: Are you in the right place?

yes

[REQUIRED] Step 2: Describe your configuration

  • Extension name: storage-resize-images

[REQUIRED] Step 3: Describe the problem

When uploading an image, it is only named _WIDTHxHEIGHT without the name.

Steps to reproduce:

Upload an image to storage bucket.

Expected result

The picture in the thumbnails folder should be named with the id corresponding to a firestore database document.

Actual result

The picture was named _WIDTHxHEIGHT.

Trigger Mail install error in console: "The caller does not have permission"

Hello,

I am trying to install Email Trigger Extension through the Firebase Console. I wan't to send email's based on user actions in my app through Google's SMTP service.

For testing purposes I entered my personal email and password in the form that the extension wanted. Like this,

(except with my actual credentials)

smtps://[email protected]:[email protected]:465
even
smtp://[email protected]:[email protected]:465

(my account allows less secure apps to access it)

After doing it, I got the very vague error of "The caller does not have permission," at the top of the page. I am not sure if it is an issue with using google's smtp with a personal account or simply that Firebase does not permit using it.

Another issue might be that I don't own the project itself, I am an admin. So I don't know who has permission to do so.

Right now, I have reverted to using the pub package "Mailer," but I don't like storing passwords in the Firebase so explicitly or even [locally.](url
Screen Shot 2019-10-28 at 1 41 26 PM
Screen Shot 2019-10-28 at 1 42 20 PM

)

[BUG] Mail not synced to MailChimp after linking email credentials

[READ] Step 1: Are you in the right place?

Yes.

[REQUIRED] Step 2: Describe your configuration

  • Extension name: auth-mailchimp-sync

[REQUIRED] Step 3: Describe the problem

Steps to reproduce:

  1. Create anonymous user
  2. Link email credential to that user
Expected result

An email address from email credential should sync to MailChimp.

Actual result

Did not sync.

Delete User Data not Deleting user data

Firestore structure

test_users -> uid1, uid2 ...

users -> uid3, uid4 ...

Cloud Firestore Paths: users/{UID}, test_users/{UID}

Logs:
Deleted: ' test_users/uid1' from Cloud Firestore
Deleted: ' users/uid1' from Cloud Firestore

What happen: Documents were not deleted

firestore-bigquery-export backfilled document_names differ from exported document_names

Configuration

  • Extension name: firestore-bigquery-export

The problem

Backfilled data rows in BigQuery receive different document_name values than rows inserted into BigQuery by the Firebase extension:

  • Backfilled rows (operation = "IMPORT") have document_name values in this format: <collection_name>/<document_id>
  • Exported rows (operation != "IMPORT") have document_name values in this format:
    <projects/<project_name>/databases/(default)/documents/<collection_name>/<document_id>

The consequence is that updates to imported documents will cause the original document to be duplicated in the *_raw_latest view.

To reproduce:

  1. Create a new Firestore collection test. Add a document to this collection.
  2. Run the importer script. It will create a changelog table (test_raw_changelog ) and a view (test_raw_latest).
  3. Modify the Firestore document.
  4. Query the test_raw_latest view. The single Firestore document now appears twice, with different document_name.

Expected result

Expected document_name values to be the same for backfilled and exported rows.

Running firestore-bigquery-export deposits private key into document data

[READ] Step 1: Are you in the right place?

Issues filed here should be about bugs for a specific extension in this repository.
If you have a general question, need help debugging, or fall into some
other category use one of these other channels:

  • For general technical questions, post a question on StackOverflow
    with the firebase tag.
  • For general Firebase discussion, use the firebase-talk
    google group.
  • To file a bug against the Firebase Extensions platform, or for an issue affecting multiple extensions, please reach out to
    Firebase support directly.

[REQUIRED] Step 2: Describe your configuration

  • Extension name: firestore-bigquery-export

[REQUIRED] Step 3: Describe the problem

My documents were imported successfully, though I found copies of my iam private key in the document data when querying. Is this expected behaviour?

If this is expected could it be clarified somewhere in the instructions or the extension?

It's not obvious sensitive data like private keys will be included in the table data based upon reading the extension information.

Steps to reproduce:

Ran npx @firebaseextensions/fs-bq-import-collection

Documentation Update: Firebase-Counter Deletes Subcollection/Shards Once Aggregated

[READ] Step 1: Are you in the right place?

Issues filed here should be about bugs for a specific extension in this repository.
If you have a general question, need help debugging, or fall into some
other category use one of these other channels:

  • For general technical questions, post a question on StackOverflow
    with the firebase tag.
  • For general Firebase discussion, use the firebase-talk
    google group.
  • To file a bug against the Firebase Extensions platform, or for an issue affecting multiple extensions, please reach out to
    Firebase support directly.

[REQUIRED] Step 2: Describe your configuration

  • Extension name: _ (storage-resize-images, firestore-send-email, etc)
  • Configuration values (redact info where appropriate):
    • _
    • _

[REQUIRED] Step 3: Describe the problem

The documentation would lead you to believe that you will have a persistent subcollection in your documents that have a counter containing count shards. However, this isn't necessarily the case because once the shards are aggregated they get deleted. I thought I was going crazy because I could not find any subcollection with shards but yet somehow the function was accurately counting. It left me scratching my head wondering what was getting counted if they aren't in the DB.

Steps to reproduce:

What happened? How can we make the problem occur?
This could be a description, log/console output, etc.

Expected result

I think it would be helpful to make it more clear that if you are running a few simple tests, you will not see any of these subcollections.

Actual result

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.