[ 9 posts ]

joecomotion

  • Joined: Mon Jul 12, 2010 5:06 pm
  • Posts: 2
  • Offline
  • Profile

getting 400s

Post Posted: Mon Jul 12, 2010 5:07 pm
+0-
I tried the sample code and am getting 400 HTTP status for:

http://yui.yahooapis.com/combo?gallery- ... md5-min.js :(

Anthony Pipkin

YUI Developer

  • Username: apipkin
  • Joined: Tue Nov 10, 2009 9:34 am
  • Posts: 68
  • Location: Atlanta, GA
  • Twitter: apipkin
  • GitHub: apipkin
  • Gists: apipkin
  • IRC: apipkin
  • YUI Developer
  • Offline
  • Profile

Re: getting 400s

Post Posted: Mon Jul 12, 2010 5:30 pm
+0-
It appears that loader is looking for a directory named "gallery-crypto-md5" not "gallery-crypto"

Jeff Craig

YUI Contributor

  • Username: foxxtrot
  • Joined: Thu Dec 04, 2008 9:20 am
  • Posts: 135
  • Location: Pullman, WA
  • Twitter: foxxtrot
  • GitHub: foxxtrot
  • Gists: foxxtrot
  • IRC: foxxtrot
  • YUI Developer
  • Offline
  • Profile

Re: getting 400s

Post Posted: Mon Jul 12, 2010 7:29 pm
+0-
No, Anthony, the gallery-crypto module is meant to include multiple encryption algorithms, each one as a submodule, so he should be trying to request crypto-md5.

Joe, for some reason, the gallery-2009.11.19-20 buildtag, which was the last time gallery-crypto was updated, doesn't seem to be on the server anymore. I'm going to escalate that to the YUI Team to be looked at. However, I have verified that later buildtags, like 'gallery-2010.03.02-18' are working fine.

Anthony Pipkin

YUI Developer

  • Username: apipkin
  • Joined: Tue Nov 10, 2009 9:34 am
  • Posts: 68
  • Location: Atlanta, GA
  • Twitter: apipkin
  • GitHub: apipkin
  • Gists: apipkin
  • IRC: apipkin
  • YUI Developer
  • Offline
  • Profile

Re: getting 400s

Post Posted: Mon Jul 12, 2010 7:38 pm
+0-
Yeah that wasn't that clear from the example in the gallery. Says use('gallery-crypto-md5', ...
Running that requests seems "gallery-crypto-md5" even with the new buildtag.

That is strange that it's missing from the old buildtag though.

Jeff Craig

YUI Contributor

  • Username: foxxtrot
  • Joined: Thu Dec 04, 2008 9:20 am
  • Posts: 135
  • Location: Pullman, WA
  • Twitter: foxxtrot
  • GitHub: foxxtrot
  • Gists: foxxtrot
  • IRC: foxxtrot
  • YUI Developer
  • Offline
  • Profile

Re: getting 400s

Post Posted: Mon Jul 12, 2010 9:04 pm
+0-
Actually, it looks like that entire buildtag might be missing.

joecomotion

  • Joined: Mon Jul 12, 2010 5:06 pm
  • Posts: 2
  • Offline
  • Profile

Re: getting 400s

Post Posted: Tue Jul 13, 2010 10:43 am
+0-
Could someone please update the crypto sample or reply with HTML/script that shows how to use the md5. Sorry if I'm pea-headed, but I can't quite figure out how to get access to the md5 function. I've tried:

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<html>
<head>

<Script src="http://yui.yahooapis.com/3.1.0/build/yui/yui-min.js"></script>
</head>
<body>
<script>
alert('foo');
YUI({
//Last Gallery Build of this module
gallery: 'gallery-2010.03.02-18'
}).use('gallery-crypto-md5', function(Y) {
alert(Y.Crypto.MD5("Test Value"));
});

</script>
</body>

</html>

I get 404s for this:
http://yui.yahooapis.com/combo?gallery- ... md5-min.js

I can't figure out how to get it to load this, which exists:
http://yui.yahooapis.com/combo?gallery- ... md5-min.js

Jeff Craig

YUI Contributor

  • Username: foxxtrot
  • Joined: Thu Dec 04, 2008 9:20 am
  • Posts: 135
  • Location: Pullman, WA
  • Twitter: foxxtrot
  • GitHub: foxxtrot
  • Gists: foxxtrot
  • IRC: foxxtrot
  • YUI Developer
  • Offline
  • Profile
Tags:

Re: getting 400s

Post Posted: Tue Jul 13, 2010 11:01 am
+0-
Ah, YUI Loader apparently doesn't handle submodules correctly.

As a workaround, load the file statically by pointing a script tag pointing at: http://yui.yahooapis.com/gallery-2010.0 ... md5-min.js

This will bypass the loader. I'm going to file a bug about this.

Jeff Craig

YUI Contributor

  • Username: foxxtrot
  • Joined: Thu Dec 04, 2008 9:20 am
  • Posts: 135
  • Location: Pullman, WA
  • Twitter: foxxtrot
  • GitHub: foxxtrot
  • Gists: foxxtrot
  • IRC: foxxtrot
  • YUI Developer
  • Offline
  • Profile

Re: getting 400s

Post Posted: Tue Jul 13, 2010 11:06 am
+0-
Or, actually, your YUI Config object can look like this:

Example

Click here to see the revision history on this Gist.

This will work, and still use loader.

Caridy Patino

YUI Contributor

  • Username: caridy
  • Joined: Mon Dec 08, 2008 5:40 pm
  • Posts: 493
  • Location: Miami, FL
  • Twitter: caridy
  • GitHub: caridy
  • Gists: caridy
  • IRC: caridy
  • YUI Developer
  • Offline
  • Profile

Re: getting 400s

Post Posted: Tue Jul 13, 2010 2:52 pm
+0-
Hey guys,

This is weird. It should work. More info about this problem:

Code:
YUI({
   gallery: 'gallery-2010.03.02-18'
  }).use('gallery-crypto-md5', function(Y)......


It tries to load this url:

http://yui.yahooapis.com/combo?gallery- ... md5-min.js

when, in reality, it should try to load this url:

http://yui.yahooapis.com/combo?gallery- ... md5-min.js

For some reason, loader is trying to load gallery-crypto-md5 from this folder: build/gallery-crypto

From my point of view, there are two point of failures here:

1. the build script is not working as expected, creating an incorrect metadata for submodules.
2. md5 module configuration is incorrect.

Let's try to find out which one is failing.

Best Regards,
Caridy
  [ 9 posts ]
Display posts from previous:  Sort by  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum