Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

QgsMapLayerRegistry not defined in current master? #24099

Closed
qgib opened this issue Feb 13, 2017 · 1 comment
Closed

QgsMapLayerRegistry not defined in current master? #24099

qgib opened this issue Feb 13, 2017 · 1 comment
Labels
Bug Either a bug report, or a bug fix. Let's hope for the latter! Plugins
Milestone

Comments

@qgib
Copy link
Contributor

qgib commented Feb 13, 2017

Author Name: Richard Duivenvoorde (@rduivenvoorde)
Original Redmine Issue: 16189
Affected QGIS version: master
Redmine category:python_plugins


I wrote a small python script to load a bunch of WMTS layers:

http://www.qgis.nl/2017/02/01/topotijdreis-kaartlagen-in-qgis/

This is working in 2.x but in 3.x it fails with:

QgsMapLayerRegistry.instance()
Traceback (most recent call last):
File "C:\OSGEO4~1\apps\Python36\lib\code.py", line 91, in runcode
exec(code, self.locals)
File "", line 1, in
NameError: name 'QgsMapLayerRegistry' is not defined

But it should still be there isn't it?

https://qgis.org/api/classQgsMapLayerRegistry.html

@qgib
Copy link
Contributor Author

qgib commented Feb 14, 2017

Author Name: Jürgen Fischer (@jef-n)


No, not anymore (that page was a leftover from when QgsMapLayerRegistry still existed - pages were only replaced, not removed on qgis.org).

QgsMapLayerRegistry was integrated in "QgsProject":https://qgis.org/api/classQgsProject.html


  • resolution was changed from to invalid
  • status_id was changed from Open to Closed

@qgib qgib added Bug Either a bug report, or a bug fix. Let's hope for the latter! Plugins labels May 25, 2019
@qgib qgib added this to the Version 3.0 milestone May 25, 2019
@qgib qgib closed this as completed May 25, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Either a bug report, or a bug fix. Let's hope for the latter! Plugins
Projects
None yet
Development

No branches or pull requests

1 participant