Guided by the principles of dislocation theory, we use the first-principles calculations to determine the structure and properties of dislocations and grain boundaries (GB) in single-layer transition metal disulfides MS(2) (M = Mo or W). In sharp contrast to other two-dimensional materials (truly planar graphene and h-BN), here the edge dislocations extend in third dimension, forming concave dreidel-shaped polyhedra. They include different number of homoelemental bonds and, by reacting with vacancies, interstitials, and atom substitutions, yield families of the derivative cores for each Burgers vector. The overall structures of GB are controlled by both local-chemical and far-field mechanical energies and display different combinations of dislocation cores. Further, we find two distinct electronic behaviors of GB. Typically, their localized deep-level states act as sinks for carriers but at large 60°-tilt the GB become metallic. The analysis shows how the versatile GB in MS(2) (if carefully engineered) should enable new developments for electronic and opto-electronic applications.