INNER CODE UNIT · Python

set_params

alexal1/Insomniac · insomniac/action_runners/interact/__init__.py:85

    def set_params(self, args):
        if args.likes_count is not None:
            self.likes_count = args.likes_count

        if args.stories_count is not None:
            self.stories_count = args.stories_count

        if args.interact is not None:
            self.interact = args.interact.copy()

            def is_source_hashtag(source):
                return source[0] != '@' and not source.startswith("P-")

            self.interact = [source if not is_source_hashtag(source) else ('#' + source) for source in self.interact]

        if args.follow_percentage is not None:
            self.follow_percentage = int(args.follow_percentage)

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…