Python Forum
method float.as_integer_ratio() always ...
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
method float.as_integer_ratio() always ...
#11
(Jul-04-2019, 10:18 AM)Gribouillis Wrote: The links are broken, I get a 404...
The links works for me,it's http and not https which in some cases can make browser not so happy.
Try copy links in a proxy site.
Reply
#12
(Jul-04-2019, 10:18 AM)Gribouillis Wrote: The links are broken, I get a 404...
hmmmm. this is on AWS S3, which is replicated to a number of other sites. can you see what IP address you are getting 404 from?
Tradition is peer pressure from dead people

What do you call someone who speaks three languages? Trilingual. Two languages? Bilingual. One language? American.
Reply
#13
It works with Snippsat's proxy, but not with my browser. I get this result.

Sorry, if I write explicitly the http:// in the address bar it works, but it doesn't work by clicking on your links.

Well in fact it depends on the browser. I could perhaps change some configs.
Reply
#14
looks like a browser bug. the a-tag has the correct URL with http:

can you view source on the forum page with the link?
Tradition is peer pressure from dead people

What do you call someone who speaks three languages? Trilingual. Two languages? Bilingual. One language? American.
Reply
#15
Skaperen Wrote:can you view source on the forum page with the link?
Yes in the source it says
Output:
right now. the 1864 ratios in that list were calculated in around 87 milliseconds of CPU on an i7 at 2.5 GHz under Pike 8.0. the Python version is slower because Python ints are slower than Pike ints. i'll look for that code so i can time it and put it online.<br /> <br /> <a rel="nofollow" href="http://ipal.net/pi.ratios" target="_blank">http://ipal.net/pi.ratios</a><br /> <a rel="nofollow" href="http://ipal.net/intfrac.pike" target="_blank">http://ipal.net/intfrac.pike</a><br /> <hr class="mycode_hr" /> calculating both ratios in the 54 bit mantissa of type double on x86, results in exactly the same value. doing it in the 65 bit mantissa of type long double on x86 may well have different results. have not tested that but a somewhat larger ratio can produce the maximum precision possible in long double.
Reply
#16
you are getting good HTML with good a-tags for the links. so the browser is either parsing them wrong or parsing the URLs wrong or applying some strange logic. but it isn't doing that to user input URLs. or, can it be (mis-)configured to do this? which browser is it? you know the work around.
Tradition is peer pressure from dead people

What do you call someone who speaks three languages? Trilingual. Two languages? Bilingual. One language? American.
Reply
#17
Skaperen Wrote:which browser is it?
Now I'm using Mozilla Firefox 67.0.4 and it doesn't work. The strange thing is that it worked once yesterday. I don't know what to do.
Reply
#18
maybe your DNS server is messing this up? does it happen when you type in the whole URL? can you do a traceroute to ipal.net on a command line? did it go to 52.216.110.42? try putting "52.216.110.42 ipal.net" in your /etc/hosts file and start a fresh new process of firefox (to force it to do another resolver lookup) to see if it's a bad IP issue. try text browsers such as curl and lynx to see if they have the same issue. what's in your /etc/resolv.conf file? that ibb.co link you gave showed an Apache server. but the real ipal.net is not running on Apache.
Tradition is peer pressure from dead people

What do you call someone who speaks three languages? Trilingual. Two languages? Bilingual. One language? American.
Reply
#19
I don't understand all these networking issues. I have the same problem with the lynx browser. I reinstalled resolvconf on the computer but the result is still the same. Lynx also displays the error as coming from the Apache server at ipal.net port 80.
Reply
#20
it's going to the wrong IP address, or being intercepted. what would be good is to find out what that IP address is. for starters let's see some important info about your system. please post the contents of file /etc/resolv.conf and the output of the 3 commands "ls -dl /etc/resolv.conf" (to see where it might be referenced), "which tcpdump" (to see if you have that program), and "inxi -Fxz" (some day it would be nice to rewrite this into Python).

the plan is to run "sudo tcpdump -lni any port 53 or port 80" in a 2nd window/workspace and hit the site again while watching for traffic from tcpdump. this should show the DNS query and where the HTTP connection is going. this can output too much info so you may have to pick out lines showing interesting packets or just note what is going where.

there are many possibilities. among them is your ISP is intercepting port 80 traffic and running it through a caching proxy with bad DNS. if that is the case then it raises the cause for me to get my web site on HTTPS which can't be proxied by interception.

since i was too cheap to get a certificate for HTTPS you can use these URLs to access the files via HTTPS on an Amazon S3 host name:

https://s3.amazonaws.com/ipal.net/pi.ratios
https://s3.amazonaws.com/ipal.net/intfrac.pike
Tradition is peer pressure from dead people

What do you call someone who speaks three languages? Trilingual. Two languages? Bilingual. One language? American.
Reply


Forum Jump:

User Panel Messages

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