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

Enhancement Request: Easy way to override default BASE_URL #36

Open
tmsmith001 opened this issue Apr 16, 2024 · 2 comments
Open

Enhancement Request: Easy way to override default BASE_URL #36

tmsmith001 opened this issue Apr 16, 2024 · 2 comments
Assignees
Labels
enhancement New feature or request

Comments

@tmsmith001
Copy link

Thank you for your library. It is proving useful.

The initial difficult thing had to figure out was that the settings.py was setting BASE_URL to wrong value for our environment. Once I figured this out and overwrote the BASE_URL value in the file, the library worked for me. Would be nice to have parameter when creating the PowerBI client to override the BASE_URL instead.

Thanks.

@andrewvillazon andrewvillazon self-assigned this Apr 17, 2024
@andrewvillazon andrewvillazon added the enhancement New feature or request label Apr 17, 2024
@andrewvillazon
Copy link
Owner

Glad it’s helping. As a work around you can modify BASE_URL of the client after you’ve initialized it. Something like pbi.BASE_URL = “new_url”

Wasn’t aware that it’s possible to have a different URL but this seems like a reasonable thing to have. Will implement. Am taking a break from this project for a couple weeks and can take a look then.

@tmsmith001
Copy link
Author

tmsmith001 commented Apr 17, 2024

pbi.BASE_URL = “new_url”

Thank you for the work around to modify BASE_URL. That is much cleaner and easier than what I was doing to overwrite settings.py. UPDATE - This initially appeared to work but did not on some subsequent calls like when requesting datasources on a dataset, it reverted back to original BASE URL.

But yes, there are different URLs depending on customer type. Thanks again.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants