Update DevChat version and force reinstall packages

- Updated expected DevChat version to 0.2.3 in checkDevChatDependency function.
- Modified package installation command to force reinstall packages.
This commit is contained in:
bobo.yang 2023-08-30 22:48:31 +08:00
parent 9261a07589
commit 9178710534
2 changed files with 2 additions and 2 deletions

View File

@ -14,7 +14,7 @@ export function checkDevChatDependency(showError: boolean = true): boolean {
try {
// Check if DevChat is installed
const expectVersion = 'DevChat 0.2.0';
const expectVersion = 'DevChat 0.2.3';
const devchatVersion = runCommand(`"${devChat}" --version`).toString().trim();
if (devchatVersion < expectVersion) {
logger.channel()?.info(`devchat version: ${devchatVersion}, but expect version: ${expectVersion}`);

View File

@ -15,7 +15,7 @@ export async function installPackage(pythonCommand: string, pkgName: string, oth
let errorOut = '';
const cmd = pythonCommand;
let args = ['-m', 'pip', 'install', pkgName];
let args = ['-m', 'pip', 'install', pkgName, '--force-reinstall'];
if (otherSource) {
args.push("-i");
args.push(otherSource);