Commit a1c39ee
fix: enhance error message formatting for strict DAG-building mode (snakemake#3376)
### Description
This PR adds three CLI parameters to enhance debugging capabilities
through strict evaluation modes:
* strict-functions-evaluation
* strict-cyclic-graph-evaluation
* strict-periodic-wildcards-evaluation
These flags are stored in types.DAGSettings and when enabled, enforce
strict checking of exceptions that would otherwise be ignored if the
rules producing them are not strictly required. The affected exceptions
are:
* InputFunctionException
* CyclicGraphException
* PeriodicWildcardError
When these flags are not set, appropriate warning messages are now
displayed for these exceptions.
Additionally, small refactor to exceptions.py: the code to stringify
exceptions is moved from print_exception into a new function named
format_exception_to_string, which is now used to build consistent
strings for both error reporting and logging purposes.
Closes snakemake#3331
<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit
- **New Features**
- Enabled execution of Xonsh scripts in workflows.
- Consolidated strict evaluation options into a single parameter for
improved flexibility.
- **Documentation**
- Updated help text and user guides for report generation, highlighting
options for self-contained HTML and ZIP reports.
- Refined deployment instructions for using conda and container
integrations with workflow directives.
- Added guidance on integrating Xonsh scripts within rules.
- **Tests**
- Expanded test coverage for conda deployments and script executions,
including support for Python 3.7 and Xonsh workflows.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
---------
Co-authored-by: Johannes Köster <[email protected]>1 parent 7755861 commit a1c39ee
File tree
5 files changed
+129
-51
lines changed- snakemake
- settings
5 files changed
+129
-51
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
10 | 10 | | |
11 | 11 | | |
12 | 12 | | |
13 | | - | |
14 | 13 | | |
15 | 14 | | |
16 | 15 | | |
| |||
65 | 64 | | |
66 | 65 | | |
67 | 66 | | |
| 67 | + | |
68 | 68 | | |
69 | 69 | | |
70 | 70 | | |
| |||
860 | 860 | | |
861 | 861 | | |
862 | 862 | | |
| 863 | + | |
| 864 | + | |
| 865 | + | |
| 866 | + | |
| 867 | + | |
| 868 | + | |
| 869 | + | |
| 870 | + | |
| 871 | + | |
863 | 872 | | |
864 | 873 | | |
865 | 874 | | |
| |||
2095 | 2104 | | |
2096 | 2105 | | |
2097 | 2106 | | |
| 2107 | + | |
2098 | 2108 | | |
2099 | 2109 | | |
2100 | 2110 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
35 | 35 | | |
36 | 36 | | |
37 | 37 | | |
38 | | - | |
| 38 | + | |
39 | 39 | | |
40 | 40 | | |
41 | 41 | | |
| |||
51 | 51 | | |
52 | 52 | | |
53 | 53 | | |
| 54 | + | |
54 | 55 | | |
55 | 56 | | |
56 | 57 | | |
| |||
1045 | 1046 | | |
1046 | 1047 | | |
1047 | 1048 | | |
1048 | | - | |
1049 | | - | |
1050 | 1049 | | |
1051 | 1050 | | |
1052 | 1051 | | |
1053 | 1052 | | |
| 1053 | + | |
| 1054 | + | |
| 1055 | + | |
| 1056 | + | |
| 1057 | + | |
| 1058 | + | |
| 1059 | + | |
| 1060 | + | |
| 1061 | + | |
| 1062 | + | |
| 1063 | + | |
| 1064 | + | |
| 1065 | + | |
| 1066 | + | |
| 1067 | + | |
| 1068 | + | |
1054 | 1069 | | |
1055 | 1070 | | |
1056 | 1071 | | |
| |||
1075 | 1090 | | |
1076 | 1091 | | |
1077 | 1092 | | |
| 1093 | + | |
| 1094 | + | |
| 1095 | + | |
| 1096 | + | |
| 1097 | + | |
| 1098 | + | |
1078 | 1099 | | |
1079 | 1100 | | |
1080 | 1101 | | |
| |||
1180 | 1201 | | |
1181 | 1202 | | |
1182 | 1203 | | |
| 1204 | + | |
| 1205 | + | |
| 1206 | + | |
| 1207 | + | |
1183 | 1208 | | |
1184 | 1209 | | |
1185 | 1210 | | |
| |||
2263 | 2288 | | |
2264 | 2289 | | |
2265 | 2290 | | |
| 2291 | + | |
| 2292 | + | |
| 2293 | + | |
| 2294 | + | |
| 2295 | + | |
2266 | 2296 | | |
2267 | 2297 | | |
2268 | 2298 | | |
2269 | 2299 | | |
| 2300 | + | |
| 2301 | + | |
| 2302 | + | |
| 2303 | + | |
| 2304 | + | |
| 2305 | + | |
| 2306 | + | |
| 2307 | + | |
2270 | 2308 | | |
2271 | 2309 | | |
2272 | 2310 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
79 | 79 | | |
80 | 80 | | |
81 | 81 | | |
82 | | - | |
| 82 | + | |
83 | 83 | | |
84 | | - | |
| 84 | + | |
85 | 85 | | |
86 | 86 | | |
87 | 87 | | |
88 | 88 | | |
89 | 89 | | |
90 | 90 | | |
91 | | - | |
92 | | - | |
93 | | - | |
94 | 91 | | |
95 | | - | |
96 | | - | |
97 | | - | |
98 | | - | |
99 | | - | |
100 | | - | |
101 | | - | |
102 | | - | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
103 | 98 | | |
104 | | - | |
| 99 | + | |
105 | 100 | | |
106 | 101 | | |
107 | 102 | | |
108 | | - | |
109 | | - | |
110 | | - | |
111 | | - | |
| 103 | + | |
| 104 | + | |
112 | 105 | | |
113 | | - | |
114 | 106 | | |
115 | | - | |
| 107 | + | |
116 | 108 | | |
117 | | - | |
118 | | - | |
119 | | - | |
120 | | - | |
| 109 | + | |
| 110 | + | |
121 | 111 | | |
122 | 112 | | |
| 113 | + | |
123 | 114 | | |
124 | 115 | | |
125 | | - | |
| 116 | + | |
126 | 117 | | |
127 | 118 | | |
128 | 119 | | |
129 | 120 | | |
130 | 121 | | |
131 | 122 | | |
132 | 123 | | |
| 124 | + | |
133 | 125 | | |
134 | | - | |
135 | | - | |
136 | | - | |
137 | | - | |
138 | | - | |
139 | | - | |
140 | | - | |
141 | | - | |
142 | | - | |
| 126 | + | |
| 127 | + | |
| 128 | + | |
| 129 | + | |
| 130 | + | |
| 131 | + | |
| 132 | + | |
143 | 133 | | |
| 134 | + | |
144 | 135 | | |
145 | | - | |
146 | | - | |
147 | | - | |
148 | | - | |
149 | | - | |
150 | | - | |
151 | | - | |
152 | | - | |
153 | | - | |
| 136 | + | |
| 137 | + | |
| 138 | + | |
| 139 | + | |
| 140 | + | |
| 141 | + | |
| 142 | + | |
154 | 143 | | |
155 | 144 | | |
156 | | - | |
| 145 | + | |
157 | 146 | | |
158 | | - | |
| 147 | + | |
159 | 148 | | |
160 | | - | |
| 149 | + | |
161 | 150 | | |
162 | | - | |
| 151 | + | |
| 152 | + | |
| 153 | + | |
| 154 | + | |
| 155 | + | |
| 156 | + | |
| 157 | + | |
| 158 | + | |
| 159 | + | |
| 160 | + | |
| 161 | + | |
| 162 | + | |
| 163 | + | |
| 164 | + | |
| 165 | + | |
| 166 | + | |
| 167 | + | |
| 168 | + | |
| 169 | + | |
| 170 | + | |
| 171 | + | |
| 172 | + | |
| 173 | + | |
| 174 | + | |
| 175 | + | |
| 176 | + | |
| 177 | + | |
| 178 | + | |
| 179 | + | |
| 180 | + | |
| 181 | + | |
163 | 182 | | |
164 | 183 | | |
165 | 184 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
26 | 26 | | |
27 | 27 | | |
28 | 28 | | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
34 | 34 | | |
35 | 35 | | |
36 | 36 | | |
| 37 | + | |
37 | 38 | | |
38 | 39 | | |
39 | 40 | | |
| |||
202 | 203 | | |
203 | 204 | | |
204 | 205 | | |
| 206 | + | |
| 207 | + | |
| 208 | + | |
| 209 | + | |
205 | 210 | | |
206 | 211 | | |
207 | 212 | | |
| |||
0 commit comments