Python Forum
Search Results
Post Author Forum Replies Views Posted [asc]
    Thread: AttributeError: 'Connection' object has no attribute 'send_line'
Post: AttributeError: 'Connection' object has no attribu...

Hi, I'm currently working on this ssh tunnel script but having issue related to AttributeError: 'Connection' object has no attribute 'send_line'. - Tried running python -tt script and the output stil...
searching1 Networking 1 3,025 Apr-29-2020, 12:10 AM
    Thread: Building SSH tunnel?
Post: Building SSH tunnel?

Hi Everyone, Would like to know if anyone here has a sample of code related to ssh tunnel using pexpect and default libraries only? Currently I'm not allowed to add or install and module/libraries ...
searching1 Networking 0 1,606 Apr-17-2020, 08:39 PM
    Thread: Basic python print script output on CGI?
Post: RE: Basic python print script output on CGI?

(Jul-28-2019, 02:12 AM)metulburr Wrote: Did you make hello.py executable? https://python-forum.io/Thread-Run-Pytho...rom-Apache chmod a+x hello.py lab@ubuntu:~/Desktop/cgi-bin$ ls -l | grep he...
searching1 Web Scraping & Web Development 4 3,503 Jul-28-2019, 02:51 AM
    Thread: Basic python print script output on CGI?
Post: Basic python print script output on CGI?

Hi, I'm currently doing some testing if possible to build like a webserver that print outs the result from a script that was based from CLI? I have run this command, but when I click the script it ju...
searching1 Web Scraping & Web Development 4 3,503 Jul-28-2019, 01:30 AM
    Thread: Telnetlib reading output
Post: RE: Telnetlib reading output

Are you able to see any logs from the device just to make sure that the script can login to your device? From your command verify the ff. tn.read_until(b"username: ") <- Make sure script read th...
searching1 Networking 1 11,257 Jul-06-2019, 12:08 PM
    Thread: Highlight/Underline a string | ValueError: zero length field name in format
Post: Highlight/Underline a string | ValueError: zero le...

Hi, I'm building a python script which put an underline on a matched string on my regex pattern. Issue is when migrated to 2.6 I'm getting the below traceback. What would be the correct way to build t...
searching1 General Coding Help 1 3,016 Jul-01-2019, 02:40 AM
    Thread: Python start from a specific string line and write?
Post: Python start from a specific string line and write...

I want to match a specific string and once match start writing the next line after after the matched string. from output save in x variable I want to match "Current configuration" then write then sta...
searching1 General Coding Help 1 2,211 Jun-27-2019, 01:04 PM
    Thread: Threading with python in sending multiple commands?
Post: Threading with python in sending multiple commands...

Hi, Anyone here tried threading method in sending command to cisco device? Currently having issues moving from main to beg_rm function using the below code for threading. My functions: def ping_ip(...
searching1 Networking 0 3,992 Jun-12-2019, 09:13 PM
    Thread: Any suggestion on python library to use for both ssh and telnet?
Post: RE: Any suggestion on python library to use for bo...

pexpect for SSH and telnet
searching1 Networking 4 3,731 Jun-12-2019, 08:41 PM
    Thread: Issue: Script from jumpserver to another server to target device?
Post: Issue: Script from jumpserver to another server to...

Hi, Question 1: I'm having issue pulling out data from server01 which where the script is located, script content need to move to another server in order to remote to the targeted device then get d...
searching1 Networking 0 2,080 May-29-2019, 03:43 AM
    Thread: learning to setup a simple web server
Post: RE: learning to setup a simple web server

Hi Lavacreeperking, Im developing/creating script too and want to put in a simple web page.. Tho my primary target is not to use any framework( not sure if possoble according to above recommendations)...
searching1 Web Scraping & Web Development 6 4,051 May-26-2019, 07:14 AM
    Thread: Retrieve output from telnet command
Post: RE: Retrieve output from telnet command

you can use something like this to find only the ip address from the output. re.findall(r'(?:[\d]{1,3})\.(?:[\d]{1,3})\.(?:[\d]{1,3})\.(?:[\d]{1,3})/\d+',showint)
searching1 Networking 1 4,099 Mar-12-2019, 01:36 PM
    Thread: Need to build a ping test for work network
Post: RE: Need to build a ping test for work network

@austina2 Hi, You can use similar with this method, instead of using os.system. you can try doing a print if there's an output from os.system + command.... though used that long time ago and I forgo...
searching1 Networking 2 3,535 Mar-08-2019, 09:03 PM
    Thread: Write list of list to CSV?
Post: RE: Write list of list to CSV?

@buran, its now working... hooooo :) problem is with the current location of my directory wherein the script pullout/move to different directory.. so I have to put the absolute path when saving on CSV...
searching1 General Coding Help 16 6,823 Feb-25-2019, 03:26 AM
    Thread: Write list of list to CSV?
Post: RE: Write list of list to CSV?

(Feb-24-2019, 09:37 AM)buran Wrote: (Feb-24-2019, 09:33 AM)searching1 Wrote: Not sure now wheather theres a code preventing to write properly.. ThanksI don't see anything like this Yes, a little b...
searching1 General Coding Help 16 6,823 Feb-24-2019, 06:41 PM
    Thread: Write list of list to CSV?
Post: RE: Write list of list to CSV?

Hi, yes I have removed the list of list convertion for dlist a while ago. Yes im getting the correct output when I isolate(recreate onlt to twst the output). Not sure now wheather theres a code pr...
searching1 General Coding Help 16 6,823 Feb-24-2019, 09:33 AM
    Thread: Write list of list to CSV?
Post: RE: Write list of list to CSV?

(Feb-24-2019, 08:43 AM)buran Wrote: what's the output from print ("\nRTR List: ",rtrlist) print ("\nINT List: ",ilist) print ("\nDESC List: ",dlist) print ("\nBUN List: ",blist)and there is no need ...
searching1 General Coding Help 16 6,823 Feb-24-2019, 09:03 AM
    Thread: Write list of list to CSV?
Post: RE: Write list of list to CSV?

(Feb-24-2019, 08:17 AM)buran Wrote: (Feb-24-2019, 07:58 AM)searching1 Wrote: After running this from my original file which Im working, It's not writing any data on the CSV, maybe u have encounter...
searching1 General Coding Help 16 6,823 Feb-24-2019, 08:28 AM
    Thread: Write list of list to CSV?
Post: RE: Write list of list to CSV?

@buran Awesome, Thank you very much. But, Seems like I have unlocked a new problem lol... After running this from my original file which Im working, It's not writing any data on the CSV, maybe u have...
searching1 General Coding Help 16 6,823 Feb-24-2019, 07:58 AM
    Thread: Write list of list to CSV?
Post: RE: Write list of list to CSV?

(Feb-24-2019, 01:28 AM)Larz60+ Wrote: I really don't know how the code in listing 2 has anything to do with the output Yep, not that much. but seen that there a method that they compile those list. ...
searching1 General Coding Help 16 6,823 Feb-24-2019, 01:50 AM

User Panel Messages

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