Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
CODE PROJECT For Those Who Code
  • Home
  • Articles
  • FAQ
Community
  1. Home
  2. The Lounge
  3. That programmer's high...

That programmer's high...

Scheduled Pinned Locked Moved The Lounge
csharpjavascripthelphtmldatabase
14 Posts 10 Posters 1 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • B Brisingr Aerowing

    DOM == Destruction of Sanity

    What do you get when you cross a joke with a rhetorical question? The metaphorical solid rear-end expulsions have impacted the metaphorical motorized bladed rotating air movement mechanism. Do questions with multiple question marks annoy you???

    Sander RosselS Offline
    Sander RosselS Offline
    Sander Rossel
    wrote on last edited by
    #5

    Coincidentally, "Dom" is also the Dutch word for "Dumb" :D

    Best, Sander arrgh.js - Bringing LINQ to JavaScript SQL Server for C# Developers Succinctly Object-Oriented Programming in C# Succinctly

    1 Reply Last reply
    0
    • M Mark_Wallace

      With a glass of DOM perignon, no doubt.

      I wanna be a eunuchs developer! Pass me a bread knife!

      G Offline
      G Offline
      Gary Wheeler
      wrote on last edited by
      #6

      Hold still Mark. We're going to have to hurt you now. :rolleyes:

      Software Zen: delete this;

      1 Reply Last reply
      0
      • Sander RosselS Sander Rossel

        I've spent hours, spread over days, on some #$&#$!*@!^#!* issue with Selenium and Protractor. I had a test that sometimes worked fine (mostly the first two or three times) and most of the times didn't. Searching, rewriting, waiting, logging, nothing seemed to help... I already found the server looped infinitely trying to get an element on my page. And just now, I noticed the server always started looping at the same spot (which was pretty hard to see and remember sometimes it didn't loop at all and everything just worked). So I fetch an element, click a button which removes the element from the DOM and then wait for the element to be removed from the DOM. I guess sometimes the element removing would be a bit slower and the waiting occurred before the removal (it's all JavaScript multithreading/callbacks/promises, yuk...). However, when the element would be gone before the waiting commenced the waiting would try to fetch the element to get it's status, couldn't find it, tried to find it again, couldn't find it, tried to find it again... Fixed by just waiting a second. So glad I've FINALLY found that issue! Time to celebrate :D

        Best, Sander arrgh.js - Bringing LINQ to JavaScript SQL Server for C# Developers Succinctly Object-Oriented Programming in C# Succinctly

        M Offline
        M Offline
        Marc Clifton
        wrote on last edited by
        #7

        So your "wait to see if the element is removed" would loop forever because it couldn't find the element if the element was already removed? That is just too weird. But congrats on finding the problem! Marc

        Latest Article - Merkle Trees Learning to code with python is like learning to swim with those little arm floaties. It gives you undeserved confidence and will eventually drown you. - DangerBunny Artificial intelligence is the only remedy for natural stupidity. - CDP1802

        Sander RosselS 1 Reply Last reply
        0
        • M Marc Clifton

          So your "wait to see if the element is removed" would loop forever because it couldn't find the element if the element was already removed? That is just too weird. But congrats on finding the problem! Marc

          Latest Article - Merkle Trees Learning to code with python is like learning to swim with those little arm floaties. It gives you undeserved confidence and will eventually drown you. - DangerBunny Artificial intelligence is the only remedy for natural stupidity. - CDP1802

          Sander RosselS Offline
          Sander RosselS Offline
          Sander Rossel
          wrote on last edited by
          #8

          Marc Clifton wrote:

          So your "wait to see if the element is removed" would loop forever because it couldn't find the element if the element was already removed?

          Exactly.

          Marc Clifton wrote:

          That is just too weird.

          That's why it took me so long to find :laugh:

          Marc Clifton wrote:

          But congrats on finding the problem!

          Thanks! :D

          Best, Sander arrgh.js - Bringing LINQ to JavaScript SQL Server for C# Developers Succinctly Object-Oriented Programming in C# Succinctly

          1 Reply Last reply
          0
          • Sander RosselS Sander Rossel

            I've spent hours, spread over days, on some #$&#$!*@!^#!* issue with Selenium and Protractor. I had a test that sometimes worked fine (mostly the first two or three times) and most of the times didn't. Searching, rewriting, waiting, logging, nothing seemed to help... I already found the server looped infinitely trying to get an element on my page. And just now, I noticed the server always started looping at the same spot (which was pretty hard to see and remember sometimes it didn't loop at all and everything just worked). So I fetch an element, click a button which removes the element from the DOM and then wait for the element to be removed from the DOM. I guess sometimes the element removing would be a bit slower and the waiting occurred before the removal (it's all JavaScript multithreading/callbacks/promises, yuk...). However, when the element would be gone before the waiting commenced the waiting would try to fetch the element to get it's status, couldn't find it, tried to find it again, couldn't find it, tried to find it again... Fixed by just waiting a second. So glad I've FINALLY found that issue! Time to celebrate :D

            Best, Sander arrgh.js - Bringing LINQ to JavaScript SQL Server for C# Developers Succinctly Object-Oriented Programming in C# Succinctly

            P Offline
            P Offline
            patbob
            wrote on last edited by
            #9

            Sander Rossel wrote:

            Fixed by just waiting a second.

            Do I understand this right -- you "fixed" the bug by waiting a second instead of polling the element's status?

            We can program with only 1's, but if all you've got are zeros, you've got nothing.

            Sander RosselS 1 Reply Last reply
            0
            • Sander RosselS Sander Rossel

              I've spent hours, spread over days, on some #$&#$!*@!^#!* issue with Selenium and Protractor. I had a test that sometimes worked fine (mostly the first two or three times) and most of the times didn't. Searching, rewriting, waiting, logging, nothing seemed to help... I already found the server looped infinitely trying to get an element on my page. And just now, I noticed the server always started looping at the same spot (which was pretty hard to see and remember sometimes it didn't loop at all and everything just worked). So I fetch an element, click a button which removes the element from the DOM and then wait for the element to be removed from the DOM. I guess sometimes the element removing would be a bit slower and the waiting occurred before the removal (it's all JavaScript multithreading/callbacks/promises, yuk...). However, when the element would be gone before the waiting commenced the waiting would try to fetch the element to get it's status, couldn't find it, tried to find it again, couldn't find it, tried to find it again... Fixed by just waiting a second. So glad I've FINALLY found that issue! Time to celebrate :D

              Best, Sander arrgh.js - Bringing LINQ to JavaScript SQL Server for C# Developers Succinctly Object-Oriented Programming in C# Succinctly

              L Offline
              L Offline
              lesNZ
              wrote on last edited by
              #10

              Had similar problem reading paper tape input where the next read executed before the last read's physical movement had ceased. Wait of 1/10th second fixed it. In 1965 I think.

              1 Reply Last reply
              0
              • Sander RosselS Sander Rossel

                I've spent hours, spread over days, on some #$&#$!*@!^#!* issue with Selenium and Protractor. I had a test that sometimes worked fine (mostly the first two or three times) and most of the times didn't. Searching, rewriting, waiting, logging, nothing seemed to help... I already found the server looped infinitely trying to get an element on my page. And just now, I noticed the server always started looping at the same spot (which was pretty hard to see and remember sometimes it didn't loop at all and everything just worked). So I fetch an element, click a button which removes the element from the DOM and then wait for the element to be removed from the DOM. I guess sometimes the element removing would be a bit slower and the waiting occurred before the removal (it's all JavaScript multithreading/callbacks/promises, yuk...). However, when the element would be gone before the waiting commenced the waiting would try to fetch the element to get it's status, couldn't find it, tried to find it again, couldn't find it, tried to find it again... Fixed by just waiting a second. So glad I've FINALLY found that issue! Time to celebrate :D

                Best, Sander arrgh.js - Bringing LINQ to JavaScript SQL Server for C# Developers Succinctly Object-Oriented Programming in C# Succinctly

                C Offline
                C Offline
                Charles Programmer
                wrote on last edited by
                #11

                Glad to hear it. So everyone's invited to the bar Friday night? Sander's buying! :laugh:

                1 Reply Last reply
                0
                • P patbob

                  Sander Rossel wrote:

                  Fixed by just waiting a second.

                  Do I understand this right -- you "fixed" the bug by waiting a second instead of polling the element's status?

                  We can program with only 1's, but if all you've got are zeros, you've got nothing.

                  Sander RosselS Offline
                  Sander RosselS Offline
                  Sander Rossel
                  wrote on last edited by
                  #12

                  Yeah, because polling the element's status wasn't going to work. Mind you, this is third-party software behavior. If it were my own I'd fix the infinite loop instead. Anyway, if this task takes longer than a second that's probably a bug too.

                  Best, Sander arrgh.js - Bringing LINQ to JavaScript SQL Server for C# Developers Succinctly Object-Oriented Programming in C# Succinctly

                  P 1 Reply Last reply
                  0
                  • Sander RosselS Sander Rossel

                    Yeah, because polling the element's status wasn't going to work. Mind you, this is third-party software behavior. If it were my own I'd fix the infinite loop instead. Anyway, if this task takes longer than a second that's probably a bug too.

                    Best, Sander arrgh.js - Bringing LINQ to JavaScript SQL Server for C# Developers Succinctly Object-Oriented Programming in C# Succinctly

                    P Offline
                    P Offline
                    patbob
                    wrote on last edited by
                    #13

                    Sander Rossel wrote:

                    Anyway, if this task takes longer than a second that's probably a bug too.

                    Or its running on someone else's machine :) Poorly written third party software is the worst. Glad you found a way around them.

                    We can program with only 1's, but if all you've got are zeros, you've got nothing.

                    1 Reply Last reply
                    0
                    • Sander RosselS Sander Rossel

                      I've spent hours, spread over days, on some #$&#$!*@!^#!* issue with Selenium and Protractor. I had a test that sometimes worked fine (mostly the first two or three times) and most of the times didn't. Searching, rewriting, waiting, logging, nothing seemed to help... I already found the server looped infinitely trying to get an element on my page. And just now, I noticed the server always started looping at the same spot (which was pretty hard to see and remember sometimes it didn't loop at all and everything just worked). So I fetch an element, click a button which removes the element from the DOM and then wait for the element to be removed from the DOM. I guess sometimes the element removing would be a bit slower and the waiting occurred before the removal (it's all JavaScript multithreading/callbacks/promises, yuk...). However, when the element would be gone before the waiting commenced the waiting would try to fetch the element to get it's status, couldn't find it, tried to find it again, couldn't find it, tried to find it again... Fixed by just waiting a second. So glad I've FINALLY found that issue! Time to celebrate :D

                      Best, Sander arrgh.js - Bringing LINQ to JavaScript SQL Server for C# Developers Succinctly Object-Oriented Programming in C# Succinctly

                      S Offline
                      S Offline
                      sreelu1
                      wrote on last edited by
                      #14

                      Selenium is an open source automated testing suite for web applications across different browsers and platforms. Selenium is one of the widely used automation testing tools because of its various advantages. Testers prefer Selenium over any other tool due to its ease of use, availability and simplicity. Testers lives have been made easier with the Learning of selenium for automated testing. It has attracted many eyeballs and become a favorite tool among automation testers.

                      1 Reply Last reply
                      0
                      Reply
                      • Reply as topic
                      Log in to reply
                      • Oldest to Newest
                      • Newest to Oldest
                      • Most Votes


                      • Login

                      • Don't have an account? Register

                      • Login or register to search.
                      • First post
                        Last post
                      0
                      • Categories
                      • Recent
                      • Tags
                      • Popular
                      • World
                      • Users
                      • Groups