[{"data":1,"prerenderedAt":246},["ShallowReactive",2],{"project-38249730":3},{"id":4,"name":5,"line":6,"line_source":7,"title":8,"url":9,"domain":10,"maker":11,"posted_at":12,"year":13,"points":14,"comments":15,"rank_in_year":16,"shown_in_year":17,"top":18,"tier":19,"category":20,"subcategory":21,"format":22,"keywords":23,"reception":29,"sentiment":30,"stance_mix":31,"scored_comments":36,"aspects":37,"strip":41,"post_text":43,"what":44,"said":81,"maker_in_thread":154,"shape":164,"grid":167,"attempts":205,"same_week":210,"maker_shows":237,"maker_hidden":238,"reader_version":239,"card":240},"38249730","sqlalchemy_data_model_visualizer","Easily Visualize Your SQLAlchemy Data Models in a Nice SVG Diagram","title","Show HN: Easily Visualize Your SQLAlchemy Data Models in a Nice SVG Diagram","https:\u002F\u002Fgithub.com\u002FDicklesworthstone\u002Fsqlalchemy_data_model_visualizer","github.com","eigenvalue",1699881198,2023,79,18,799,3109,26,"notable","dev_tools","diagram generator","library",[24,25,26,27,28],"sqlalchemy","erd diagram","graphviz","data model visualization","svg","mixed",0.183,{"positive":32,"neutral":33,"mixed":34,"critical":35},4,3,0,2,9,{"idea":38,"execution":40},{"positive":32,"critical":39},1,{"positive":34,"critical":39},[34,33,34,42,34,34,34,42,34,39,33,42,34,42,34,33,39,34],5,null,{"problem":45,"audience":52,"pricing":43,"motivation":56,"time_to_build":43,"stack":60,"openness":79,"stage":80,"team_size":80},{"value":46,"source":47,"evidence":48},"Hard to see how many SQLAlchemy models connect in a complicated application","maker",[49],{"id":50,"by":11,"text":51},"38249743","I made this last week for fun, but I think it could be useful for people. If your application has pretty complicated SQLalchemy data models (and the app I'm working on now has…",{"value":53,"source":47,"evidence":54},"Developers using SQLAlchemy with complex models",[55],{"id":50,"by":11,"text":51},{"value":57,"source":47,"evidence":58},"Made for fun, and the maker's own app had grown complicated",[59],{"id":50,"by":11,"text":51},[61,69,73],{"value":62,"source":63,"evidence":64},"Python","inferred",[65],{"id":66,"by":67,"text":68},"38264399","throwaw33333434",">>> from sqlalchemy_data_model_visualizer import generate_data_model_diagram python3.11\u002Fsite-packages\u002Fsqlalchemy_data_model_visualizer.py\", line 5, in \u003Cmodule> from…",{"value":70,"source":47,"evidence":71},"SQLAlchemy",[72],{"id":50,"by":11,"text":51},{"value":74,"source":47,"evidence":75},"Graphviz",[76],{"id":77,"by":11,"text":78},"38264330","Yes, Graphviz is doing all the actual hard work here. It's an awesome library.","open_source","unknown",{"praise":82,"objections":99,"requests":107,"questions":119,"alternatives":124},[83,95],{"value":84,"source":85,"evidence":86},"Useful for onboarding new devs and CI schema diagrams","commenter",[87,91],{"id":88,"by":89,"text":90},"38264378","arsalanb","This is great, especially to introduce new devs to models. I use (and love) TablePlus (https:\u002F\u002Ftableplus.com\u002F) which has a diagram generator plugin that does the same!",{"id":92,"by":93,"text":94},"38262880","ants_a","Nice, I hacked together something similar many moons ago, it looks like some fine folks have kept on maintaining and improving it:…",{"value":96,"source":47,"evidence":97},"Graphviz does the heavy lifting well",[98],{"id":77,"by":11,"text":78},[100],{"value":101,"source":85,"evidence":102},"Fails with older SQLAlchemy versions due to declarative_base import",[103,104],{"id":66,"by":67,"text":68},{"id":105,"by":67,"text":106},"38264458","from sqlalchemy.orm import sessionmaker, relationship from sqlalchemy.ext.declarative import declarative_base",[108,112],{"value":109,"source":47,"evidence":110},"Interactive hover highlighting of tables and connections",[111],{"id":50,"by":11,"text":51},{"value":113,"source":85,"evidence":114},"Support for SQLAlchemy Core schemas, not only ORM models",[115],{"id":116,"by":117,"text":118},"38263702","NoboruWataya","Looks good. I guess this only works for models defined using ORM and not schemas defined using the tools in SQLAlchemy Core?",[120],{"value":121,"source":85,"evidence":122},"Does it work with SQLAlchemy Core-defined schemas?",[123],{"id":116,"by":117,"text":118},[125,129,136,140,147],{"value":126,"source":85,"evidence":127},"sqlalchemy_schemadisplay",[128],{"id":92,"by":93,"text":94},{"value":130,"source":85,"evidence":131},"Django-schema-viewer",[132],{"id":133,"by":134,"text":135},"38255204","adr1an","Nice. I've been using Django-schema-viewer and it's been great. This makes me wonder if its UI could be decoupled from Django...",{"value":137,"source":85,"evidence":138},"TablePlus diagram generator",[139],{"id":88,"by":89,"text":90},{"value":141,"source":85,"evidence":142},"DataGrip and DBeaver ER diagrams",[143],{"id":144,"by":145,"text":146},"38262303","michaelteter","Your tool looks great. In regards to difficulty finding alternatives, many database management tools (like DataGrip and Dbeaver) have ER diagram generators that work for all the…",{"value":148,"source":85,"evidence":149},"D2",[150],{"id":151,"by":152,"text":153},"38262177","jhoechtl","Would rather use D2 https:\u002F\u002Fd2lang.com\u002Ftour\u002Fsql-tables for this task",{"comments":155,"answered":34,"key":156},7,[157,158,161],{"id":50,"text":51},{"id":159,"text":160},"38264043","Cool, I'm surprised I couldn't find this when I was looking for something like this originally. Probably because I was using different terminology-- \"data model\" instead of…",{"id":162,"text":163},"38255947","Cool. Yeah it would seem to limit the audience a lot that it's for Django only and also has to be integrated into an existing Django project for it to work. I wanted a very small…",{"commenters":165,"max_depth":32,"maker_replies":155,"first_comment_mins":39,"lifespan_hours":166},11,27,[168,170,172,174,175,176,180,182,183,186,188,190,193,195,196,199,201,203],[50,34,34,169,11,39],"project\u002Fpositive\u002Fidea",[92,34,33,171,93,34],"project\u002Fneutral\u002Fidea",[159,34,34,173,11,39],"maker\u002Fneutral\u002Fnone",[133,39,42,169,134,34],[162,39,34,171,11,39],[177,35,34,178,179,34],"38264287","other\u002Fneutral\u002Fnone","jjice",[77,35,34,181,11,39],"maker\u002Fpositive\u002Fnone",[88,33,42,169,89,34],[184,33,34,178,185,34],"38264856","riffic",[66,32,39,187,67,34],"project\u002Fcritical\u002Fexecution",[105,32,33,189,67,34],"project\u002Fneutral\u002Fexecution",[191,42,42,169,192,34],"38251625","talboren",[194,42,34,171,11,39],"38251699",[144,42,42,169,145,34],[197,42,34,198,11,39],"38262667","commenter\u002Fneutral\u002Fnone",[116,200,33,171,117,34],6,[151,155,39,202,152,34],"project\u002Fcritical\u002Fidea",[204,155,34,198,11,39],"38262681",[206,209],{"id":207,"t":208,"points":33,"comments":35},"38068614",1698668875,{"id":4,"t":12,"points":14,"comments":15},[211,216,220,225,229,233],{"id":212,"name":213,"points":214,"category":215},"38243949","dpoint",583,"hardware",{"id":217,"name":218,"points":219,"category":20},"38230325","Spray",393,{"id":221,"name":222,"points":223,"category":224},"38228788","DataSheetGrid",342,"languages",{"id":226,"name":227,"points":228,"category":224},"38202703","BabaBASIC",234,{"id":230,"name":231,"points":232,"category":20},"38230476","Flyscrape",208,{"id":234,"name":235,"points":236,"category":224},"38276430","Numbat",146,15,false,"v2",{"id":241,"name":5,"line":6,"ai":238,"cat":20,"year":13,"points":14,"comments":15,"rec":29,"s":242,"top":18,"kw":243,"maker":11,"domain":10,"tier":19,"attempts":35,"strip":244,"url":9,"mix":245,"praise":84,"objection":101,"sub":21},38249730,0.18,[24,25,26,27,28],"030500050135050310",[32,33,34,35],1794036644622]