Skip to content

Commit 3d436e6

Browse files
authored
πŸ› Avoid recording sensitive information.
2 parents 4b1f33b + e603bbe commit 3d436e6

File tree

5 files changed

+65
-3
lines changed

5 files changed

+65
-3
lines changed
Lines changed: 53 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,53 @@
1+
name: Run Automated Selenium Tests
2+
3+
on:
4+
workflow_dispatch:
5+
6+
jobs:
7+
test:
8+
runs-on: ubuntu-latest
9+
steps:
10+
- name: Checkout code
11+
uses: actions/checkout@v4
12+
13+
- name: Set up Python
14+
uses: actions/setup-python@v4
15+
with:
16+
python-version: '3.10'
17+
18+
- name: Install dependencies
19+
run: |
20+
pip install pytest selenium -i https://pypi.mirrors.ustc.edu.cn/simple/
21+
22+
- name: Install Firefox and GeckoDriver
23+
run: |
24+
sudo install -d -m 0755 /etc/apt/keyrings
25+
wget -q https://packages.mozilla.org/apt/repo-signing-key.gpg -O- | sudo tee /etc/apt/keyrings/packages.mozilla.org.asc > /dev/null
26+
gpg -n -q --import --import-options import-show /etc/apt/keyrings/packages.mozilla.org.asc | awk '/pub/{getline; gsub(/^ +| +$/,""); if($0 == "35BAA0B33E9EB396F59CA838C0BA5CE6DC6315A3") print "βœ… Key fingerprint verified"; else print "❌ Key verification failed"}'
27+
echo "deb [signed-by=/etc/apt/keyrings/packages.mozilla.org.asc] https://packages.mozilla.org/apt mozilla main" | sudo tee /etc/apt/sources.list.d/mozilla.list > /dev/null
28+
echo 'Package: *
29+
Pin: origin packages.mozilla.org
30+
Pin-Priority: 1000' | sudo tee /etc/apt/preferences.d/mozilla
31+
echo 'Package: firefox*
32+
Pin: release o=Ubuntu*
33+
Pin-Priority: -1' | sudo tee -a /etc/apt/preferences.d/mozilla
34+
sudo apt-get update
35+
sudo apt-get install -y firefox
36+
firefox --version
37+
which firefox
38+
39+
GECKODRIVER_VERSION=$(curl -s https://api.github.com/repos/mozilla/geckodriver/releases/latest | jq -r .tag_name)
40+
wget https://github.com/mozilla/geckodriver/releases/download/$GECKODRIVER_VERSION/geckodriver-$GECKODRIVER_VERSION-linux64.tar.gz
41+
tar -xvzf geckodriver-$GECKODRIVER_VERSION-linux64.tar.gz
42+
sudo mv geckodriver /usr/local/bin/
43+
geckodriver --version
44+
45+
- name: Run Selenium tests with pytest
46+
run: |
47+
python -m pytest test/web_test/web_test.py --disable-warnings -v --junitxml=test-results/pytest-report.xml
48+
49+
- name: Publish Test Report
50+
if: always()
51+
uses: mikepenz/action-junit-report@v4
52+
with:
53+
report_paths: 'test-results/pytest-report.xml'

β€Žbackend/services/model_health_service.pyβ€Ž

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -292,5 +292,5 @@ async def embedding_dimension_check(model_config: dict):
292292
return dimension
293293
except Exception as e:
294294
logger.warning(
295-
f"UNCONNECTED: {model_name}; Base URL: {model_base_url}; API Key: {model_api_key}; Error: {str(e)}")
295+
f"UNCONNECTED: {model_name}; Base URL: {model_base_url}; Error: {str(e)}")
296296
return 0

β€Ždocker/.env.betaβ€Ž

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
NEXENT_IMAGE=nexent/nexent:beta
2+
NEXENT_WEB_IMAGE=nexent/nexent-web:beta
3+
NEXENT_DATA_PROCESS_IMAGE=nexent/nexent-data-process:beta
4+
5+
ELASTICSEARCH_IMAGE=docker.elastic.co/elasticsearch/elasticsearch:8.17.4
6+
POSTGRESQL_IMAGE=postgres:15-alpine
7+
REDIS_IMAGE=redis:alpine
8+
MINIO_IMAGE=quay.io/minio/minio:RELEASE.2023-12-20T01-00-02Z
9+
OPENSSH_SERVER_IMAGE=nexent/nexent-ubuntu-terminal:latest

β€Ždocker/.env.generalβ€Ž

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,4 +10,4 @@ OPENSSH_SERVER_IMAGE=nexent/nexent-ubuntu-terminal:latest
1010

1111
SUPABASE_KONG=kong:2.8.1
1212
SUPABASE_GOTRUE=supabase/gotrue:v2.170.0
13-
SUPABASE_DB=supabase/postgres:15.8.1.060
13+
SUPABASE_DB=supabase/postgres:15.8.1.060

β€Žsdk/nexent/core/models/embedding_model.pyβ€Ž

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -259,7 +259,7 @@ def get_embeddings(self, inputs: Union[str, List[str]], with_metadata: bool = Fa
259259
embeddings = [item["embedding"] for item in response["data"]]
260260
return embeddings
261261

262-
async def dimension_check(self, timeout: float = 5.0) -> List[List[float]]:
262+
async def dimension_check(self, timeout: float = 30.0) -> List[List[float]]:
263263
try:
264264
# Create a simple test input
265265
test_input = "Hello, nexent!"

0 commit comments

Comments
Β (0)