Warning Database, problems with list.map?

Hello,

Where is this database warning file (.csv)?
final step regarding list.map does not work,why?
the last map creates “Null”
GetAndManageWarnings.dyn (72.3 KB)

KR

Andreas

Hey Andreas,

So, for the first, I suspect this is as discussed by Konrad here… https://archi-lab.net/digging-through-revit-warnings-to-find-meaning/
It is possible to extract all the (900?) warnings from revit, but most don’t have a rating and it’s not necessarily the rating you want it to have…
So I think you want to have your own .csv file, here’s mine (I can’t upload .csv so I renamed to .txt) it doesn’t catch all of them, but most that you’ll regularly come across.
CurrentWarningRatingLibrary.txt (11.8 KB)

For the second, I think this might be better?

Hope that helps,

Mark

1 Like


You know actually i don`t know the final result. it is Script from a book.
But the result is confusing.
And .CSV export does not work.

I think under headers are the imputs listet. But it does not work

Excel export does not work :frowning:

You’ve got way too many list levels in your data input. I don’t know what structure that node expects but I would assume it’s similar to excel with a list of lines with sublists of separated values.

Right, but as you can see in the CSV output, it’s expecting a @L3 list structure. You’re providing @L5. The data structure should be

@L3 = full dataset
@L2 = line/row
@L1 = value

hmmm… just flatten?

Probably not, based on your previous image. It should look just like the example structure you wrote above the AddItemToFront node.


that looks better, but the headers are missing

That’s the part that was throwing me off in your other image. I don’t know where you’re adding the headers. It should look like the Flatten output (looks like you were right there) but with the headers added to the front.

i think the aim is like this:


red text

the problem is it takes the headers as a list and not as headers.

They would be a list in the input. It should look like this:

1 Like

the “headers” are not headers :frowning:
it is still cero? what could be the error?

…it looks likes in your pic the dynamo output

it is not sorting it well when i link the .csv

Look at my list structure again. You don’t want to transpose the data. The data should have the same index as its respective header. If you have 5 headers then you should have 5 items in each sublist to match those headers.

1 Like

You have right something is to much here. Transpose and map and listdepth.
it is made for excel. I got confused.
this List.AddItemtoFront looks correct @L3 is full data @L2 is Lists that contain → @L1 is the data (category, warnings,…)

Just get rid of the Transpose after the Flatten.

1 Like

It works a lot better! the csv export is not clean:


for any reason it divides text, split values into diverent colums :confused:
Can i clean the .csv in an editor?

That could be from your original list structure. You did a lot of transposing there which is what initially worried me. Can you confirm that everything looks right in Dynamo?

1 Like

Dynamo looks ok:

But CSV seems to be destroyed

you mean just save a clean .csv/.xls ?

Make sure you check specifically for x==5 but it looks good otherwise. Do you have any commas in those strings? The node will write the data to a comma delimited file but Excel will still parse for commas on its own when reading the csv. That’s a tricky part of handling these kinds of files. Manual cleanup may be the only option at that point.