Error-on-enable seems to be the consensus, but if configurable (see issue #2066061: Permit other path than "/data" and "/data.json"), should also be error-on-(mis-)configure.

Comments

bhosmer’s picture

Assigned: Unassigned » bhosmer

hook_install to verify if the path exists already.

bhosmer’s picture

Status: Active » Needs review

Completed with 1786cf99f516

Barrett’s picture

Version: » 7.x-1.x-dev
Status: Needs review » Needs work

This doesn't seem to be working. On a clean install, I created a view with path /data, then enabled the opendata_view and opendata module and got no error reported.

Barrett’s picture

I also think this should move from opendata to opendata_view. Unless a user enables our view, we don't care if they have anything at /data

bhosmer’s picture

Let me check this out with the latest and see where the problem is.

bhosmer’s picture

Can someone give me commit access? I had it for the sandbox, but I don't seem to have it here.

I've made the changes, and I just need to push them up for testing.

Barrett’s picture

Sorry for the hold up, @bhosmer. You should have commit access now.

Thanks for sticking with the project.

bhosmer’s picture

Status: Needs work » Needs review

Thanks Barrett. I've pushed this 72099d1b up.

Barrett’s picture

Sorry, bhosmer. I feel like I keep running you in circles.

The update does what's expected of it. The problem is that the code for data.json moved from the views submodule to the main module. I'm ambivalent as to where it should be, but either the data.json code needs to move back to the views submodule or the install hook that checks for it needs to move back to the main module.

bhosmer’s picture

Sure thing.

I've put it back in opendata.install with b4faa69431f.

Barrett’s picture

Status: Needs review » Fixed

Looks good, @bhosmer. Thanks for your continuing work on this project.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.