Welcome to the Onshape forum! Ask questions and join in the discussions about everything Onshape.
First time visiting? Here are some places to start:- Looking for a certain topic? Check out the categories filter or use Search (upper right).
- Need support? Ask a question to our Community Support category.
- Please submit support tickets for bugs but you can request improvements in the Product Feedback category.
- Be respectful, on topic and if you see a problem, Flag it.
If you would like to contact our Community Manager personally, feel free to send a private message or an email.
Weird error table is still working perfectly
I'm getting this error when I use a Custom Table I made in anywhere that isn't the origonal document. Table is still showing up and everything seems to be working.
I have no idea what it is but it's kind of annoying having the yellow excelamation mark whenever I open up the table.
Typecheck canBeTableRow failed (isTableValue(entry.value) || entry.value is TableCellError)
183:9
onshape/std/table.fs (canBeTableRow)
192:12
onshape/std/table.fs (tableRow)
102:33
c8eef2271809c4293325c9b1/4227b687e7c4b5093ac931f5/5807a7fe9c52c03aea23880a (const nameAndMaterial)
53:16
onshape/std/table.fs (defineTable)
Comments
Please see
We can't figure out what's wrong if we can't see your table code.
Sorry I'm aware of that but the whole document is company propery unfortunitally, so here is the code in question:
annotation { "Table Type Name" : "Alphacam CSV Table" }
export const nameAndMaterial = defineTable(function(context is Context, definition is map) returns Table
precondition
{
annotation { "Name" : "Exported File Name" }
definition.fileName is string;
So, looking at the code for 5 seconds, my suspicion falls on edgeDisc being possibly undefined — that would cause that error. You can use the new undefined-coalescing operator to give it a default string value — see if that makes the issue go away:
OOOOOOOO I can use that! that's exciting there's a lot of places where I have:
var myVariable;
if(someValueToTryToFetch != undefined)
{
myVariable = someValueToTryToFetch;
}
now I can just type:
var myVarialbe = someValueToTryToFetch ?? "value undefined looser";
is that right?
Alas that didn't do the trick, my table still looks perfect like but the warning is still there. Edge Disc is usually an empty string. that doesn't cause the issue though as I can't recreate the error in other part studios by leaing edgeDisc blank.
That is crazy I just duplicated and moved the part studio into the document where the table was written and the warning is gone, despite the table being the same version in both documents. I've got a feeling this warning is only showing up because all the features that I've been writting were in develpment while this part studio was being made and may have messed up the metadat to mutch for the parts maybe?
I'll drop it for now and see if the issue comes back later
Yes, we added ?? recently: https://forum.onshape.com/discussion/comment/106372/#Comment_106372
Regarding the latent error, again, we can't help without a shared doc, but it sounds like you're over the problem.
Have I gone crazy or is there no way to mark this as answered now?
If you made the topic as a discussion instead of a question topic you won't have that option.
@Oliver_Couch
Ugh crap, I'll make sure to do that next time