We perform numerical simulations of the TRAPPIST-1 system of seven exoplanets orbiting a nearby M dwarf, starting with a previously suggested stable configuration. The long-term stability of this configuration is confirmed, but the motion of planets is found to be chaotic. The eccentricity values are found to vary within finite ranges. The rates of tidal dissipation and tidal evolution of orbits are estimated, assuming an Earth-like rheology for the planets. We find that under this assumption the planets b, d, e were captured in the 3:2 or higher spin-orbit resonances during the initial spin-down but slipped further down into the 1:1 resonance. Dependent on its rheology, the innermost planet b may be captured in a stable pseudosynchronous rotation. Non-synchronous rotation ensures higher levels of tidal dissipation and internal heating. The positive feedback between the viscosity and the dissipation rate -- and the ensuing runaway heating -- are terminated by a few self-regulation processes. When the temperature is high and the viscosity is low enough, the planet spontaneously leaves the 3:2 resonance. Further heating is stopped either by passing the peak dissipation or by the emergence of partial melt in the mantle. In the post-solidus state, the tidal dissipation is limited to the levels supported by the heat transfer efficiency. The tides on the host star are unlikely to have had a significant dynamical impact. The tides on the synchronized inner planets tend to reduce these planets orbital eccentricity, possibly contributing thereby to the systems stability.