Skip to content

Commit

Permalink
Disable wdpa_licensed_protected_area query permission check
Browse files Browse the repository at this point in the history
This doesn't seem to be working anymore - it is causing a permission
error, even for admins with the gfw-pro app.

So, I'm disabling this check temporarily until we figure out to how to
make it work.
  • Loading branch information
danscales committed Dec 4, 2023
1 parent 84e44ca commit 92799de
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
4 changes: 2 additions & 2 deletions app/routes/datasets/queries.py
Original file line number Diff line number Diff line change
Expand Up @@ -160,8 +160,8 @@ async def query_dataset_json(
"""

dataset, version = dataset_version
if dataset in PROTECTED_QUERY_DATASETS:
await is_gfwpro_admin(error_str="Unauthorized query on a restricted dataset")
#if dataset in PROTECTED_QUERY_DATASETS:
# await is_gfwpro_admin(error_str="Unauthorized query on a restricted dataset")

if geostore_id:
geostore: Optional[GeostoreCommon] = await get_geostore(
Expand Down
1 change: 1 addition & 0 deletions tests_v2/unit/app/routes/datasets/test_query.py
Original file line number Diff line number Diff line change
Expand Up @@ -434,6 +434,7 @@ async def test_query_vector_asset_disallowed_10(
)

@pytest.mark.asyncio()
@pytest.mark.skip("Skip while figuring out permissions")
async def test_query_licensed_disallowed_11(
licensed_version, async_client: AsyncClient
):
Expand Down

0 comments on commit 92799de

Please sign in to comment.