"Building safety is a provincial jurisdiction"

True.
But public safety is a matter for all levels of government and the feds may have a duty (they certainly have the right) to get involved when it's clear that lower-tier governments are not doing what is required.

In the case of unsafe development next to interprovincial pipelines and railways, the feds clearly have a role in keeping people safe. There should be a federally-mandated minimum setback from pipelines and freight railways for 'high-consequence' sites like schools, seniors' facilities, hospitals, transit hubs, arenas, high-rises, etc.

At this point there is no national standard in either Canada or USA. South of the border several states and municipalities have enacted sensible set-back requirements. In most cases these were implemented in the aftermath of a major incident. 

Canada has never had a catastrophic pipeline incident. The possibility of one seems to be the furthest thing from the minds of city planners.