Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Don't miss out! 2025 Microsoft Fabric Community Conference, March 31 - April 2, Las Vegas, Nevada. Use code MSCUST for a $150 discount. Prices go up February 11th. Register now.

Reply
ludovicLaurent
Frequent Visitor

scrapping notebook python

HI  

    i have created a python program on my computer to scrap an url , i works 

 

    but if i put in a pyspark notebook , i have a 403 error .

    I tried to add header   in the request.get command  , but same result : error 403 

 

    Have you some idea to solve this problem 


   my code is 

import requests

print(response)
print(response.content)

thanks
2 REPLIES 2
v-shex-msft
Community Support
Community Support

Hi @ludovicLaurent,

Any update on this? Did the above suggestions help with your scenario? if that is the case, you can consider Kudo or Accept the helpful suggestions to help others who faced similar requirements.

If these also don't help, please share more detailed information and description to help us clarify your scenario to test.

Regards,

Xiaoxin Sheng

Community Support Team _ Xiaoxin
If this post helps, please consider accept as solution to help other members find it more quickly.
v-shex-msft
Community Support
Community Support

Hi @ludovicLaurent ,

The 403 error code meaning access to the requested resource is forbidden. (the server understood the request, but will not fulfill it, if it was correct)

HTTP 403 - Wikipedia

AFAIK, the notebook is works on the cloud-based sandbox with required environment and libraries. Did these operations require any additional authrisons or need to write data to the current local folder/file? (the pyspark notebook sandbox not allowed to operate with its physical path)

Regards,

Xiaoxin Sheng

Community Support Team _ Xiaoxin
If this post helps, please consider accept as solution to help other members find it more quickly.

Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Prices go up Feb. 11th.

JanFabricDE_carousel

Fabric Monthly Update - January 2025

Explore the power of Python Notebooks in Fabric!

JanFabricDW_carousel

Fabric Monthly Update - January 2025

Unlock the latest Fabric Data Warehouse upgrades!

JanFabricDF_carousel

Fabric Monthly Update - January 2025

Take your data replication to the next level with Fabric's latest updates!