Strip large output; add README
This commit is contained in:
@ -14,12 +14,8 @@ def tricubridge(input: str) -> str:
|
||||
text=True,
|
||||
check=True,
|
||||
)
|
||||
|
||||
if len(result.stdout) > 2000:
|
||||
return "Output too large; limited to 2000 chars."
|
||||
else:
|
||||
return result.stdout.strip()
|
||||
|
||||
output = result.stdout.strip()
|
||||
return output[:500] + ('...' if len(output) > 500 else '')
|
||||
except subprocess.CalledProcessError as e:
|
||||
return f"Error executing Tricu code: {e.stderr or str(e)}"
|
||||
except Exception as e:
|
||||
|
Reference in New Issue
Block a user