You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardexpand all lines: docs/README.md
+37
Original file line number
Diff line number
Diff line change
@@ -203,6 +203,43 @@ Check out this flocking macro from fellow _Italo-Amsterdammer_ @carlopi @ DuckDB
203
203
204
204
<br>
205
205
206
+
## Development
207
+
208
+
### Cloning the Repository
209
+
210
+
Clone the repository and all its submodules
211
+
212
+
```bash
213
+
git clone <your-fork-url>
214
+
git submodule update --init --recursive
215
+
```
216
+
217
+
### Setting up CLion
218
+
**Opening project:**
219
+
Configuring CLion with the extension template requires a little work. Firstly, make sure that the DuckDB submodule is available.
220
+
Then make sure to open `./duckdb/CMakeLists.txt` (so not the top level `CMakeLists.txt` file from this repo) as a project in CLion.
221
+
Now to fix your project path go to `tools->CMake->Change Project Root`([docs](https://www.jetbrains.com/help/clion/change-project-root-directory.html)) to set the project root to the root dir of this repo.
222
+
223
+
**Debugging:**
224
+
To set up debugging in CLion, there are two simple steps required. Firstly, in`CLion -> Settings / Preferences -> Build, Execution, Deploy -> CMake` you will need to add the desired builds (e.g. Debug, Release, RelDebug, etc). There's different ways to configure this, but the easiest is to leave all empty, except the `build path`, which needs to be set to `../build/{build type}`. Now on a clean repository you will first need to run `make {build type}` to initialize the CMake build directory. After running make, you will be able to (re)build from CLion by using the build target we just created. If you use the CLion editor, you can create a CLion CMake profiles matching the CMake variables that are described in the makefile, and then you don't need to invoke the Makefile.
225
+
226
+
The second step is to configure the unittest runner as a run/debug configuration. To do this, go to `Run -> Edit Configurations` and click `+ -> Cmake Application`. The target and executable should be `unittest`. This will run all the DuckDB tests. To specify only running the extension specific tests, add `--test-dir ../../.. [sql]` to the `Program Arguments`. Note that it is recommended to use the `unittest` executable fortesting/development within CLion. The actual DuckDB CLI currently does not reliably work as a run targetin CLion.
227
+
228
+
229
+
### Testing
230
+
231
+
To run the E2E test install all packages necessary:
232
+
233
+
```bash
234
+
pip install -r requirements.txt
235
+
```
236
+
237
+
Then run the test suite:
238
+
239
+
```bash
240
+
pytest pytest test_http_api
241
+
```
242
+
206
243
##### :black_joker: Disclaimers
207
244
208
245
[^1]: DuckDB ® is a trademark of DuckDB Foundation. All rights reserved by their respective owners. [^1]
0 commit comments