Skip to content

Can enhance the Example or Change the example to avoid potential Syntax Warning.  #159

Closed

Description

In one of the example where is is used instead of == we are getting a potential Syntax Warning. This might be confusing sometimes. So we can enhance the example of why it happens or we can simply change that to use == instead.

Exact location : Generator & Comprehensions Section -> Reading Comprehension Exercise Solution -> Translating a For-Loop (Below screenshot from website):

Screen Shot 2020-08-12 at 3 44 42 PM

So the above code mentioned produces below Warning (screenshot from my system):

Screen Shot 2020-08-12 at 3 46 49 PM

Instead we can use == instead of is operator to have more cleaner interpretation (screenshot from my system):

Screen Shot 2020-08-12 at 3 47 06 PM

Please let me know if this makes sense and also if there is an opportunity I would like to submit a PR for this and in future few more additions.

Thanks in Advance.

Activity

  1. rsokl commented on Aug 13, 2020

    @rsokl
    Owner

    Thanks for pointing this out! I would be happy to have this PR :)

  2. rsokl commented on Aug 13, 2020

    @rsokl
    Owner

    Oh, and I should be more specific - the example should be using == instead of is

  3. ravichandraveeramachaneni commented on Aug 13, 2020

    @ravichandraveeramachaneni
    ContributorAuthor
  4. rsokl commented on Aug 14, 2020

    @rsokl
    Owner

    Hi @ravichandraveeramachaneni - I need to update those guidelines. The preferred method is for you to fork the repo and make a PR from your fork.

    I apologize for the confusion / inconvenience

  5. ravichandraveeramachaneni commented on Aug 14, 2020

    @ravichandraveeramachaneni
    ContributorAuthor
  6. rsokl commented on Aug 14, 2020

    @rsokl
    Owner

    Thanks for the PR @ravichandraveeramachaneni

    I don't have formal guidelines - if you make several contributions to PLYMI, I would happily add you as a contributor :)

  7. rsokl commented on Aug 14, 2020

    @rsokl
    Owner

    closed by #160

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions