{"id":20196675,"url":"https://github.com/polyipseity/hkust-comp-4321","last_synced_at":"2026-06-11T14:31:54.699Z","repository":{"id":250638394,"uuid":"756201740","full_name":"polyipseity/hkust-comp-4321","owner":"polyipseity","description":null,"archived":false,"fork":false,"pushed_at":"2026-05-23T10:52:20.000Z","size":3687,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2026-05-23T12:29:18.320Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/polyipseity.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":".github/FUNDING.yml","license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null},"funding":{"community_bridge":null,"github":null,"issuehunt":null,"ko_fi":null,"liberapay":null,"open_collective":null,"otechie":null,"patreon":null,"tidelift":null,"custom":null}},"created_at":"2024-02-12T07:18:27.000Z","updated_at":"2026-05-23T10:52:23.000Z","dependencies_parsed_at":"2024-07-29T03:47:47.215Z","dependency_job_id":"ce4fc650-5b38-4589-b620-f4b5dd174e52","html_url":"https://github.com/polyipseity/hkust-comp-4321","commit_stats":null,"previous_names":["polyipseity/comp-4321","polyipseity/hkust-comp-4321"],"tags_count":2,"template":false,"template_full_name":null,"purl":"pkg:github/polyipseity/hkust-comp-4321","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/polyipseity%2Fhkust-comp-4321","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/polyipseity%2Fhkust-comp-4321/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/polyipseity%2Fhkust-comp-4321/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/polyipseity%2Fhkust-comp-4321/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/polyipseity","download_url":"https://codeload.github.com/polyipseity/hkust-comp-4321/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/polyipseity%2Fhkust-comp-4321/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":34204178,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-06-11T02:00:06.485Z","response_time":57,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-14T04:25:21.657Z","updated_at":"2026-06-11T14:31:54.679Z","avatar_url":"https://github.com/polyipseity.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Installation instructions\r\n\r\n## Step 1\r\n\r\nSet up a Python environment: Ensure that you have at least Python \u003e= 3.11 installed on your system. You can download the latest version of Python from the official Python website (\u003chttps://www.python.org\u003e) and follow the installation instructions for your operating system.\r\n\r\n_Note: For Windows, you may want to install the Python launcher, enabling you to use `py` in place of `python` for consistently running the latest version of Python, avoiding any conflicts with third-party software and outdated Python versions._\r\n\r\n_**After doing so, replace all instances of `python` with `py` in the following commands.**_\r\n\r\n## Step 2\r\n\r\nUnzip the submission file and navigate to the extracted folder.\r\n\r\nThen, open a terminal at the folder.\r\n\r\n## Step 3\r\n\r\n**Create a virtual environment (highly recommended): Given how other teams may also use Python, and the dependencies used between projects may have conflicts, it is highly recommended to create a virtual environment for running our project.** To create a virtual environment, run the following command:\r\n\r\n```shell\r\npython -m venv venv\r\n```\r\n\r\nThis command creates a new virtual environment named \"venv\" in the \"comp-4321\" directory.\r\n\r\nThe virtual environment can effectively avoid issues such as:\r\n_ERROR: pip's dependency resolver does not currently take into account all the packages that are installed. This behaviour is the source of the following dependency conflicts.\r\nfastapi 0.104.1 requires anyio\u003c4.0.0,\u003e=3.7.1, but you have anyio 4.3.0 which is incompatible._\r\n\r\n## Step 4\r\n\r\nActivate the virtual environment: Activate the virtual environment using the appropriate command based on your operating system:\r\n\r\nOn Windows:\r\n\r\n```shell\r\nvenv\\Scripts\\activate\r\n```\r\n\r\nOn Linux or macOS:\r\n\r\n```shell\r\nsource venv/bin/activate\r\n```\r\n\r\n## Step 5\r\n\r\nInstall the required packages: In the root directory of the project (i.e., the \"comp-4321\" directory), there should be a file named \"requirements.txt\". To install the required packages, run the following command:\r\n\r\n_Note: Check again to see if `(venv)` appears in the command prompt for using the virtual environment._\r\n\r\n```shell\r\npip install -r requirements.txt\r\n```\r\n\r\nThis command will install all the necessary packages specified in the \"requirements.txt\" file.\r\n\r\n## Step 6\r\n\r\nRun the crawler using the command for Phase 1.\r\n\r\n_Note: Check again to see if `(venv)` appears in the command prompt for using the virtual environment._\r\n\r\n```shell\r\npython -m egod_search.crawl -n 30 -d database.db -s spider_result.txt https://www.cse.ust.hk/~kwtleung/COMP4321/testpage.htm\r\n```\r\n\r\nIn case of re-run, and the database needs to be cleared, use the appropriate command based on your operating system:\r\n\r\nOn Windows:\r\n\r\n```shell\r\ndel database.db\r\n```\r\n\r\nOn Linux or macOS:\r\n\r\n```shell\r\nrm database.db\r\n```\r\n\r\n## Important notices\r\n\r\nThe program says it is `Finished` but does not end, just gets stuck:\r\nOn Windows, after the program has finished, the CLI may freeze if the program finishes too quickly. This is a [CPython bug](https://github.com/python/cpython/issues/111604) and is out of our control. Just Ctrl+C to get out of it and ignore the errors as they are harmless.  \r\n\r\nIf there is an error mentioning `requires a different Python`, for example `ERROR: Package 'egod-search' requires a different Python: 3.10.11 not in '\u003e=3.11.0'`:\r\nYour Python version is outdated and does not support [features the code relies on](https://stackoverflow.com/a/77247460). Please go to \u003chttps://www.python.org/downloads/\u003e and download the newest version of Python.\r\n\r\n## FAQ\r\n\r\nQ: Install does not work\r\n\r\nA1: Check again that `(venv)` appears in the command prompt for using the virtual environment. The virtual environment is not entered by default.\r\n\r\nQ: `venv\\Scripts\\activate` does not work for my Windows machine\r\n\r\nA: For Windows machines with MinGW-w64, `python.exe` may refer to the MinGW-w64 executable. It does not work because it generates Linux version of virtual environment script, and likely does not come with Python \u003e= 3.11. Use `py` which can guarantee running the Windows Python executable.\r\n\r\n## Tested working platforms\r\n\r\nLinux: Debian 12 on Python 3.11.2 (older Linux distros do not have \u003e= Python 3.11, either install yourself or switch machines)\r\nWindows: Windows 10 and 11, Python 3.11.2 and 3.12.2\r\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpolyipseity%2Fhkust-comp-4321","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fpolyipseity%2Fhkust-comp-4321","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpolyipseity%2Fhkust-comp-4321/lists"}