Git Product home page Git Product logo

obs-transcript's People

Contributors

akabe avatar

Stargazers

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

Watchers

 avatar  avatar

Forkers

ogmkp

obs-transcript's Issues

Uncaught TypeError in FormatModel.js

Firstly disclaimer, as I am not very familiar with js I have used chatGPT to try to make sure I have all the information you may need. Hope it worked ok haha!

Description:
I encountered an Uncaught TypeError in the FormatModel.js file while using the library in a specific context. The error occurs within the onresult callback of the SpeechRecognitionModel.js file. Here are the details:

Error Message:

Uncaught TypeError: Cannot read properties of undefined (reading 'length')
    at _default.splitlines (FormatModel.js:37:18)
    at FormatModel.js:7:38
    at Array.map (<anonymous>)
    at _default.format (FormatModel.js:7:24)
    at HomeModel.js:59:45
    at _this.engine.onresult (SpeechRecognitionModel.js:38:11)

Reproduction Steps:
Use the following code to reproduce the issue in the console:

// Example usage to reproduce the issue
const formatter = new FormatModel();
const formattedText = formatter.format([" nothing nothing's working here"], 5, 80);
console.log(formattedText);

Additional Information:
The strs parameter in the format method is expected to be an array.
The error seems to be related to the input data or the context in which the FormatModel is being used.
The issue is not reproduced with the provided example code, but it occurs within the onresult callback of the SpeechRecognitionModel.js file.

Possible Suggestions:
Add additional logging in the splitlines method to identify the values causing the issue.
Check the input array strs in the format method to ensure it contains valid strings.

Environment Information:
Chrome Version 120.0.6099.71 (Official Build) (64-bit)

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.