opencommit icon indicating copy to clipboard operation
opencommit copied to clipboard

[Bug]: Local Ollama with OpenCommit not working when internet is blocked

Open recrack opened this issue 1 year ago • 5 comments

Opencommit Version

v1.0.2

Node Version

v20.5.1

NPM Version

9.8.0

What OS are you seeing the problem on?

Other Linux Distro

What happened?

I am trying to use local Ollama for my project, but I have encountered an issue where OpenCommit does not work when the internet is disconnected.

Expected Behavior

When using local Ollama, OpenCommit should continue to function properly even if the internet is disconnected.

Current Behavior

OpenCommit does not work when the internet is disconnected while using local Ollama. This causes issues with committing changes to the local repository and can lead to lost or untracked changes.

Possible Solution

No response

Steps to Reproduce

No response

Relevant log output

No response

recrack avatar Mar 14 '24 08:03 recrack

@jaroslaw-weber hello again :) any idea why this happens with ollama?

di-sukharev avatar Mar 15 '24 07:03 di-sukharev

Not sure, probably something related to running ollama in local server? We basically do a API call to localhost so maybe related.

jaroslaw-weber avatar Mar 15 '24 12:03 jaroslaw-weber

look like a request can not be made with no internet, lets see if this happens again, keeping the issue opened

di-sukharev avatar Mar 18 '24 04:03 di-sukharev

@di-sukharev @jaroslaw-weber

my .opencommit

OCO_OPENAI_API_KEY=undefined
OCO_TOKENS_MAX_INPUT=undefined
OCO_TOKENS_MAX_OUTPUT=undefined
OCO_OPENAI_BASE_PATH=undefined
OCO_DESCRIPTION=undefined
OCO_EMOJI=undefined
OCO_MODEL=undefined
OCO_LANGUAGE=en
OCO_MESSAGE_TEMPLATE_PLACEHOLDER=$msg
OCO_PROMPT_MODULE=conventional-commit
OCO_AI_PROVIDER=ollama

recrack avatar Mar 19 '24 04:03 recrack

@di-sukharev actually opencommit is working but with a delay I described in #347

hacker-hackman avatar May 23 '24 07:05 hacker-hackman