cBioPortal / cbioportal

cBioPortal for Cancer Genomics
https://cbioportal.org
GNU Affero General Public License v3.0
658 stars 519 forks source link

Bitly "Shorten URL" feature doesn't work #1452

Closed shrumit closed 6 years ago

shrumit commented 8 years ago

Just noticed this little bug:

screenshot from 2016-07-05 14-30-49

ecerami commented 8 years ago

I just tried to verify this via URL: http://www.cbioportal.org/index.do?cancer_study_list=luad_tcga&cancer_study_id=luad_tcga&genetic_profile_ids_PROFILE_MUTATION_EXTENDED=luad_tcga_mutations&genetic_profile_ids_PROFILE_COPY_NUMBER_ALTERATION=luad_tcga_gistic&Z_SCORE_THRESHOLD=2.0&data_priority=0&case_set_id=luad_tcga_cnaseq&case_ids=&patient_case_select=sample&gene_set_choice=user-defined-list&gene_list=EGFR&clinical_param_selection=null&tab_index=tab_visualize&Action=Submit&show_samples=false&

and, the bit.ly link works, e.g. I get: http://bit.ly/29ntwL1

Can you please check again? May have been a small service interruption.

shrumit commented 8 years ago

It still doesn't work for me when I query "BRCA1" and select all studies:

http://www.cbioportal.org/cross_cancer.do?cancer_study_list=&cancer_study_id=all&genetic_profile_ids_PROFILE_MUTATION_EXTENDED=chol_jhu_2013_mutations&data_priority=0&case_set_id=chol_jhu_2013_sequenced&case_ids=&patient_case_select=sample&gene_set_choice=user-defined-list&gene_list=BRCA1&clinical_param_selection=null&tab_index=tab_visualize&Action=Submit&Action=Submit#crosscancer/overview/0/BRCA1/sarc_mskcc%2Csarc_tcga%2Cthyroid_mskcc_2016%2Cacc_tcga%2Cchol_jhu_2013%2Cchol_nccs_2013%2Cchol_nus_2012%2Cchol_tcga%2Cgbc_shanghai_2014%2Cblca_bgi%2Cblca_dfarber_mskcc_2014%2Cblca_mskcc_solit_2012%2Cblca_mskcc_solit_2014%2Cblca_plasmacytoid_mskcc_2016%2Cblca_tcga%2Cblca_tcga_pub%2Cmm_broad%2Ces_dfarber_broad_2014%2Ces_iocurie_2014%2Ccoadread_genentech%2Ccoadread_mskcc%2Ccoadread_tcga%2Ccoadread_tcga_pub%2Cbrca_bccrc%2Cbrca_bccrc_xenograft_2014%2Cbrca_broad%2Cbrca_metabric%2Cbrca_sanger%2Cbrca_tcga%2Cbrca_tcga_pub%2Cbrca_tcga_pub2015%2Ccesc_tcga%2Clgg_tcga%2Clgg_ucsf_2014%2Clgggbm_tcga_pub%2Cpcpg_tcga%2Cescc_icgc%2Cescc_ucla_2014%2Cegc_tmucih_2015%2Chnsc_broad%2Chnsc_jhu%2Chnsc_tcga%2Chnsc_tcga_pub%2Cnpc_nusingapore%2Clihc_amc_prv%2Clihc_riken%2Clihc_tcga%2Cpaac_jhu_2014%2Cpaad_icgc%2Cpaad_tcga%2Cpaad_utsw_2015%2Cpanet_jhu_2011%2Cmeso_tcga%2Cnepc_wcm%2Cprad_broad%2Cprad_broad_2013%2Cprad_fhcrc%2Cprad_mich%2Cprad_mskcc%2Cprad_mskcc_2014%2Cprad_mskcc_cheny1_organoids_2014%2Cprad_su2c_2015%2Cprad_tcga%2Cprad_tcga_pub%2Ccscc_dfarber_2015%2Crms_nih_2014%2Ctgct_tcga%2Ctet_nci_2014%2Cucec_tcga%2Cucec_tcga_pub%2Call_stjude_2015%2Claml_tcga%2Claml_tcga_pub%2Cnbl_amc_2012%2Cmbl_broad_2012%2Cmbl_icgc%2Cmbl_pcgp%2Cesca_broad%2Cesca_tcga%2Cstad_pfizer_uhongkong%2Cstad_tcga%2Cstad_tcga_pub%2Cstad_uhongkong%2Cstad_utokyo%2Cuvm_tcga%2Cacyc_mskcc%2Cccrcc_irc_2014%2Cccrcc_utokyo_2013%2Ckirc_bgi%2Ckirc_tcga%2Ckirc_tcga_pub%2Cnccrcc_genentech_2014%2Csclc_clcgp%2Csclc_jhu%2Csclc_ucologne_2015%2Cluad_broad%2Cluad_mskcc_2015%2Cluad_tcga%2Cluad_tcga_pub%2Cluad_tsp%2Clusc_tcga%2Clusc_tcga_pub%2Ccellline_ccle_broad%2Ccellline_nci60%2Cscco_mskcc%2Cmpnst_mskcc%2Cskcm_broad%2Cskcm_broad_dfarber%2Cskcm_tcga%2Cskcm_yale%2Cdesm_broad_2015%2Cthym_tcga%2Cthca_tcga%2Cthca_tcga_pub%2Cucs_jhu_2014%2Cucs_tcga%2Cgbm_tcga%2Cgbm_tcga_pub%2Cgbm_tcga_pub2013%2Ckich_tcga%2Ckich_tcga_pub%2Ckirp_tcga%2Cdlbc_tcga%2Cpcnsl_mayo_2015%2Cov_tcga%2Cov_tcga_pub

Perhaps the problem is that the URL is so large.

gideonite commented 8 years ago

It's broken for me too.

FWIW the error is not unknown and is in fact 500 "INVALID_URI."

For some reason I can't seem to find the source script (cgx_query.js) in my chrome dev tools on @ecerami 's working example to see what a correct URL looks like.

I also haven't found anything on the web discussing maximum URL length for bitly links.

Finally, https://github.com/cBioPortal/cbioportal/blob/39afb082f0f6ff5e09c3e3bb4945b2db4d2cd182/portal/src/main/webapp/js/src/cgx_jquery.js#L173

should not call .append but rather .val or .html, whatever the function is that overwrites the value instead of appending to it.

I'd make a PR but it seems like the team prefers more substantial fixes?