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
Note that code coverage builds the C sources with debug symbols. For this
170
-
reason, the coverage flag is only available with the`develop` mode of
169
+
reason, the coverage script builds the package in`develop` mode of
171
170
`setup.py`.
172
171
173
172
The coverage results for the C and Python sources will be printed to the
@@ -194,14 +193,14 @@ these steps:
194
193
195
194
## Error Reporting and Logging
196
195
197
-
Use the `DPCTL_VERBOSITY` environment variable to print errors of different severity levels from the libsyclinterface library to the console.
198
-
You can specify one of the following severity levels (in increasing order of severity): `warning` and `error`.
196
+
The SyclInterface library responds to `DPCTL_VERBOSITY` environment variable that controls the severity level of errors printed to console.
197
+
One can specify one of the following severity levels (in increasing order of severity): `warning` and `error`.
199
198
200
199
```bash
201
-
export DPCTL_VERBOSITY=error
200
+
export DPCTL_VERBOSITY=warning
202
201
```
203
202
204
-
Messages of a given severity are shown not only in the console for that severity, but also fora lower severity. For example, the severity level `error` will output severity errors for`error` and `warning` to the console.
203
+
Messages of a given severity are shown not only in the console for that severity, but also forthe higher severity. For example, the severity level `warning` will output severity errors for`error` and `warning` to the console.
205
204
206
205
### Optional use of the Google logging library (glog)
207
206
@@ -218,15 +217,24 @@ conda install glog
218
217
python scripts/build_locally.py --oneapi --glog
219
218
```
220
219
221
-
3. Use `DPCTLService_InitLogger` and `DPCTLService_ShutdownLogger` functions during development to initialize the Google's logging library and de-initialize accordingly
220
+
3. Use `dpctl._diagnostics.syclinterface_diagnostics(verbosity="warning", log_dir=None)` context manager to switch library diagnostics on for a block of Python code.
221
+
Use `DPCTLService_InitLogger` and `DPCTLService_ShutdownLogger` library C functions during library development to initialize the Google's logging library and de-initialize accordingly
222
222
223
-
```bash
223
+
```python
224
+
from dpctl._diagnostics import syclinterface_diagnostics
0 commit comments