opencommit
                                
                                
                                
                                    opencommit copied to clipboard
                            
                            
                            
                        [Bug]: 70 seconds delay before proceeding if using `ollama` option with no internet
Opencommit Version
3.0.15
Node Version
20.9.0
NPM Version
10.1.0
What OS are you seeing the problem on?
Other Linux Distro
What happened?
This bug happens every time.
Expected Behavior
Generate a commit message instantly if disconnected from internet.
Current Behavior
opencommit waits 70 seconds before generating a commit message if disconnected from internet and using ollama option.
Possible Solution
I think there's an internet connection timeout set. And we need to place ollama execution before this timeout.
Steps to Reproduce
- Disable your internet connection
 - Use my config:
 
OCO_OPENAI_API_KEY=undefined
OCO_ANTHROPIC_API_KEY=undefined
OCO_TOKENS_MAX_INPUT=undefined
OCO_TOKENS_MAX_OUTPUT=undefined
OCO_OPENAI_BASE_PATH=undefined
OCO_DESCRIPTION=false
OCO_EMOJI=false
OCO_MODEL=undefined
OCO_LANGUAGE=en
OCO_MESSAGE_TEMPLATE_PLACEHOLDER=$msg
OCO_PROMPT_MODULE=conventional-commit
OCO_AI_PROVIDER=ollama
OCO_GITPUSH=false
OCO_ONE_LINE_COMMIT=false
- Install 
ollamaand pullmistralmodel from the library - try to use 
ococommand to make a commit 
Relevant log output
No response
@hacker-hackman do you want to investigate why and open a PR?