Python Forum
Search Results
Post Author Forum Replies Views Posted [asc]
    Thread: Web Form to Python Script to Text File to zip file to web
Post: Web Form to Python Script to Text File to zip file...

Greetings folks, I might be over thinking my question but let me ask it and get feedback from experts. I want to have a web form that has multiple fields (devicename, redundant, sharedIP, indaIP, i...
wfsteadman General Coding Help 1 682 Aug-09-2020, 11:24 AM
    Thread: Breakdown CIDR with netaddr
Post: RE: Breakdown CIDR with netaddr

I got it working using this: from netaddr import * import sys network_list = [] subnet_list = [] def define_prefixlens(subnet_input, max): max_cidr_val = int(max) + 1 ip = IPNetwork(subnet_...
wfsteadman General Coding Help 1 665 Oct-06-2019, 06:22 PM
    Thread: Breakdown CIDR with netaddr
Post: Breakdown CIDR with netaddr

Was wondering if anyone out here has created an IP based subnet script that will take a CIDR address and then break it down into all the subnets between the CIDR mask and say a /24 Like this: 100.11...
wfsteadman General Coding Help 1 665 Oct-05-2019, 04:26 PM
    Thread: Recursive Search and Find
Post: RE: Recursive Search and Find

OK so here is what I have so far: import re import shlex services = [] groups = [] service_dictionary = {} svc_grp_dictionary = {} svc_grp = open("service-group-output.txt", 'w') with open("service...
wfsteadman General Coding Help 2 1,110 Jan-03-2019, 02:22 PM
    Thread: Recursive Search and Find
Post: Recursive Search and Find

Folks, I am not even sure how to ask the question so I don't really have code to post for what I have tried. I am trying to do some comparisons on some Firewall Services and Firewall Service groups...
wfsteadman General Coding Help 2 1,110 Dec-30-2018, 09:43 PM
    Thread: Lists in Dictionaries Assistance
Post: RE: Lists in Dictionaries Assistance

Thank You SO MUCH. That worked. And I understood the code as well. (May-05-2018, 04:44 PM)buran Wrote: here is more general example that will create a dict with devices for each department note t...
wfsteadman General Coding Help 2 1,165 May-05-2018, 06:22 PM
    Thread: Lists in Dictionaries Assistance
Post: Lists in Dictionaries Assistance

greetings all, I have a file given to me that is in YAML format Quote:--- device_list: location1: department: [FIN] description: location1 devices: [router1, router2] location2: dep...
wfsteadman General Coding Help 2 1,165 May-05-2018, 03:06 PM
    Thread: Finding nested delimiters
Post: RE: Finding nested delimiters

I am not sure how this code would work to parse through a large file and find the nested configs
wfsteadman General Coding Help 4 1,692 Jan-22-2018, 04:01 AM
    Thread: Finding nested delimiters
Post: Finding nested delimiters

Greetings all, I have a configuration file and after much reviewing I found there is some structure to it, but not sure how to reach in and get the elements out of it. So the file can be quite larg...
wfsteadman General Coding Help 4 1,692 Jan-21-2018, 07:24 PM
    Thread: check if value of passed variable has uppercase characters in it.
Post: RE: check if value of passed variable has uppercas...

I think I figured it out since writing this: import re pattern = re.compile("([A-Z])") listname = ['ONE', 'two', 'Thr33', 'four', 'FiVe368'] for test in listname: if pattern.match(test): ...
wfsteadman General Coding Help 3 1,589 Sep-01-2017, 03:44 PM
    Thread: check if value of passed variable has uppercase characters in it.
Post: check if value of passed variable has uppercase ch...

Greetings all, I am parsing through lines in a file and what i am trying to do is look for any objects in position 5 (The line is getting split so it would be line[5]) and if line[5]contains an uppe...
wfsteadman General Coding Help 3 1,589 Sep-01-2017, 03:22 PM
    Thread: dynamically create a list
Post: dynamically create a list

greetings all, I think my question is a simple one. At the base of it, I am trying to get python to generate an empty list based on the value in a specific point of a line of text (config vdom root...
wfsteadman General Coding Help 0 1,200 Aug-30-2017, 05:34 PM
    Thread: Very New to Python
Post: Very New to Python

Greetings all, I am very new to python. I have a project I am working on and figured Python might be a good tool. I have a directory with a large number of configuration files in them and I need t...
wfsteadman General Coding Help 1 1,709 Jul-01-2017, 02:11 PM

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020