[GH-ISSUE #192] Error: more than one device/emulator #618

Closed
opened 2026-03-13 22:10:14 +03:00 by kerem · 5 comments
Owner

Originally created by @rusellned on GitHub (Nov 21, 2020).
Original GitHub issue: https://github.com/alexal1/Insomniac/issues/192

I have a problem, it does not work on multiple devices, when connecting two devices, I get the following error (screenshot attached). Version 3.3.0.

But in version 3.0 everything works fine.

In version 3.3.0, I get an error that more than one device is connected. How can this be solved?

Captura de pantalla 2020-11-21 a las 1 46 11
Originally created by @rusellned on GitHub (Nov 21, 2020). Original GitHub issue: https://github.com/alexal1/Insomniac/issues/192 I have a problem, it does not work on multiple devices, when connecting two devices, I get the following error (screenshot attached). Version 3.3.0. But in version 3.0 everything works fine. In version 3.3.0, I get an error that more than one device is connected. How can this be solved? <img width="640" alt="Captura de pantalla 2020-11-21 a las 1 46 11" src="https://user-images.githubusercontent.com/48245734/99862888-dfd2ee00-2b9b-11eb-858b-0efa20349fb7.png">
kerem closed this issue 2026-03-13 22:10:20 +03:00
Author
Owner

@rusellned commented on GitHub (Nov 21, 2020):

Solved: the problem was here -> session.py -> Line 86 -> open_instagram(args.device)

<!-- gh-comment-id:731486434 --> @rusellned commented on GitHub (Nov 21, 2020): Solved: the problem was here -> session.py -> Line 86 -> open_instagram(args.device)
Author
Owner

@alexal1 commented on GitHub (Nov 21, 2020):

@rusellned could you explain the problem so we could make a fix for further versions?
Or even create a pull request?

<!-- gh-comment-id:731572122 --> @alexal1 commented on GitHub (Nov 21, 2020): @rusellned could you explain the problem so we could make a fix for further versions? Or even create a pull request?
Author
Owner

@rusellned commented on GitHub (Nov 22, 2020):

@alexal1 Previously, I ran the script on two phones, but after updating, the following error "Error: more than one device/emulator" started to appear.

I started looking for what the problem might be and saw that the "device" was not passed to the open_instagram function. I changed the name of the argument "self.device" in the session file to "args.device" and it worked right away.

    // session.py
    def start_session(self, args, device_wrapper):
        self.session_state = SessionState()
        self.session_state.args = args.__dict__
        self.sessions.append(self.session_state)

        print_timeless(COLOR_REPORT + "\n-------- START: " + str(self.session_state.startTime) + " --------" + COLOR_ENDC)
        open_instagram(args.device) // --self.device
        self.session_state.my_username, \
            self.session_state.my_followers_count, \
            self.session_state.my_following_count = get_my_profile_info(device_wrapper.get())

        return self.session_state

So if you can, just replace this line in the next update with this one and everything will.

<!-- gh-comment-id:731743778 --> @rusellned commented on GitHub (Nov 22, 2020): @alexal1 Previously, I ran the script on two phones, but after updating, the following error "Error: more than one device/emulator" started to appear. I started looking for what the problem might be and saw that the "device" was not passed to the open_instagram function. I changed the name of the argument "self.device" in the session file to "args.device" and it worked right away. ``` // session.py def start_session(self, args, device_wrapper): self.session_state = SessionState() self.session_state.args = args.__dict__ self.sessions.append(self.session_state) print_timeless(COLOR_REPORT + "\n-------- START: " + str(self.session_state.startTime) + " --------" + COLOR_ENDC) open_instagram(args.device) // --self.device self.session_state.my_username, \ self.session_state.my_followers_count, \ self.session_state.my_following_count = get_my_profile_info(device_wrapper.get()) return self.session_state ``` So if you can, just replace this line in the next update with this one and everything will.
Author
Owner

@Fadude commented on GitHub (Nov 22, 2020):

Will be added as a bugfix on 3.3.2 release

<!-- gh-comment-id:731759424 --> @Fadude commented on GitHub (Nov 22, 2020): Will be added as a bugfix on 3.3.2 release
Author
Owner

@Fadude commented on GitHub (Nov 23, 2020):

Fixed on v.3.3.2, closing.

<!-- gh-comment-id:731977145 --> @Fadude commented on GitHub (Nov 23, 2020): Fixed on v.3.3.2, closing.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/Insomniac#618
No description provided.