Skip to main content

Search

Items tagged with: programming


#Programming Leftovers • 𝕿𝖚𝖝 𝕸𝖆𝖈𝖍𝖎𝖓𝖊𝖘 ⇨


#Programming Leftovers • 𝗧𝘂𝘅 𝗠𝗮𝗰𝗵𝗶𝗻𝗲𝘀 ⇨


good mechanical keyboards with opensource firmware



Hey everyone, I’m #newhere. I’m interested in #anime, #doctorwho, #eff, #foss, #freesoftware, #gnu, #gpl, #haskell, #linux, #makerspaces, #nethack, #privacy, #programming, #security, and #startrek.

Been meaning to check diaspora out for a while now. Feel free do say hello.


Hey everyone, I’m #newhere. I’m interested in #anime, #doctorwho, #eff, #foss, #freesoftware, #gnu, #gpl, #haskell, #linux, #makerspaces, #nethack, #privacy, #programming, #security, and #startrek.

Been meaning to check diaspora out for a while now. Feel free do say hello.


Help wanted: Website testing inside Python code

Background


I'm trying to use Pyhton's webbrowser module for testing a website with various pages, and one of the pages is index.html

I can open this page using this code:

webbrowser.open(file:///[...]/public/index.html)

But if i instead use this code

webbrowser.open(file:///[...]/public/)

then i will get a list of the contents of that directory

Question


What do you suggest that i do if i want to test my website?

A few options that i can see:
* Changing a setting in the browser
* Setting up a local http server
* Asking Python's webbrowser to look for an index.html file (this would work the first time but not when navigating between pages)

I use Firefox and Chromium as browers and Python 3.8

#python #programming #web #question


Help wanted: Website testing inside Python code

Background


I'm trying to use Pyhton's webbrowser module for testing a website with various pages, and one of the pages is index.html

I can open this page using this code:

webbrowser.open(file:///[...]/public/index.html)

But if i instead use this code

webbrowser.open(file:///[...]/public/)

then i will get a list of the contents of that directory

Question


What do you suggest that i do if i want to test my website?

A few options that i can see:
* Changing a setting in the browser
* Setting up a local http server
* Asking Python's webbrowser to look for an index.html file (this would work the first time but not when navigating between pages)

I use Firefox and Chromium as browers and Python 3.8

#python #programming #web #question



This website uses cookies to recognize revisiting and logged in users. You accept the usage of these cookies by continue browsing this website.